roundcubemail/program/lib/Roundcube/rcube_result_thread.php
public function count_messages()
    {
        if ($this->meta['messages'] !== null)
            return $this->meta['messages'];

        if (empty($this->raw_data)) {
            $this->meta['messages'] = 0;
        }
        else {
            $this->meta['messages'] = 1
                + substr_count($this->raw_data, self::SEPARATOR_ELEMENT)
                + substr_count($this->raw_data, self::SEPARATOR_ITEM);
        }

        if ($this->meta['messages'] == 0 || $this->meta['messages'] == 1)
            $this->meta['count'] = $this->meta['messages'];

        return $this->meta['messages'];
    }
public function count_messages()
    {
        if ($this->meta['messages'] !== null)
            return $this->meta['messages'];

        if (empty($this->raw_data)) {
            $this->meta['messages'] = 0;
        }
        else {
            $this->meta['messages'] = 1
                + substr_count($this->raw_data, self::SEPARATOR_ELEMENT)
                + substr_count($this->raw_data, self::SEPARATOR_ITEM);
        }

        if ($this->meta['messages'] == 0 || $this->meta['messages'] == 1)
            $this->meta['count'] = $this->meta['messages'];

        return $this->meta['messages'];
    }
public function count_messages ( ) { if ( $ this -> meta [ 'messages' ] !== null ) return $ this -> meta [ 'messages' ] ; if ( empty ( $ this -> raw_data ) ) { $ this -> meta [ 'messages' ] = 0 ; } else { $ this -> meta [ 'messages' ] = 1 + substr_count ( $ this -> raw_data , self :: SEPARATOR_ELEMENT ) + substr_count ( $ this -> raw_data , self :: SEPARATOR_ITEM ) ; } if ( $ this -> meta [ 'messages' ] == 0 || $ this -> meta [ 'messages' ] == 1 ) $ this -> meta [ 'count' ] = $ this -> meta [ 'messages' ] ; return $ this -> meta [ 'messages' ] ; }
Returns number of all messages in the result

@return int Number of elements
Returns number of all messages in the result