Changeset 5c461ba in github


Ignore:
Timestamp:
Sep 29, 2010 12:47:05 PM (3 years ago)
Author:
alecpl <alec@…>
Branches:
master, HEAD, courier-fix, dev-browser-capabilities, pdo, release-0.6, release-0.7, release-0.8
Children:
33da0b4
Parents:
c609784
Message:
Location:
program/include
Files:
14 edited

Legend:

Unmodified
Added
Removed
  • program/include/html.php

    re019f2d r5c461ba  
    4040     * Constructor 
    4141     * 
    42      * @param array Hash array with tag attributes 
     42     * @param array $attrib Hash array with tag attributes 
    4343     */ 
    4444    public function __construct($attrib = array()) 
     
    6464     * Generic method to create a HTML tag 
    6565     * 
    66      * @param string Tag name 
    67      * @param array  Tag attributes as key/value pairs 
    68      * @param string Optinal Tag content (creates a container tag) 
    69      * @param array  List with allowed attributes, omit to allow all 
     66     * @param string $tagname Tag name 
     67     * @param array  $attrib  Tag attributes as key/value pairs 
     68     * @param string $content Optinal Tag content (creates a container tag) 
     69     * @param array  $allowed_attrib List with allowed attributes, omit to allow all 
    7070     * @return string The XHTML tag 
    7171     */ 
     
    8989     * Derrived method for <div> containers 
    9090     * 
    91      * @param mixed  Hash array with tag attributes or string with class name 
    92      * @param string Div content 
     91     * @param mixed  $attr Hash array with tag attributes or string with class name 
     92     * @param string $cont Div content 
    9393     * @return string HTML code 
    9494     * @see html::tag() 
     
    105105     * Derrived method for <p> blocks 
    106106     * 
    107      * @param mixed  Hash array with tag attributes or string with class name 
    108      * @param string Paragraph content 
     107     * @param mixed  $attr Hash array with tag attributes or string with class name 
     108     * @param string $cont Paragraph content 
    109109     * @return string HTML code 
    110110     * @see html::tag() 
     
    121121     * Derrived method to create <img /> 
    122122     * 
    123      * @param mixed Hash array with tag attributes or string with image source (src) 
     123     * @param mixed $attr Hash array with tag attributes or string with image source (src) 
    124124     * @return string HTML code 
    125125     * @see html::tag() 
     
    137137     * Derrived method for link tags 
    138138     * 
    139      * @param mixed  Hash array with tag attributes or string with link location (href) 
    140      * @param string Link content 
     139     * @param mixed  $attr Hash array with tag attributes or string with link location (href) 
     140     * @param string $cont Link content 
    141141     * @return string HTML code 
    142142     * @see html::tag() 
     
    154154     * Derrived method for inline span tags 
    155155     * 
    156      * @param mixed  Hash array with tag attributes or string with class name 
    157      * @param string Tag content 
     156     * @param mixed  $attr Hash array with tag attributes or string with class name 
     157     * @param string $cont Tag content 
    158158     * @return string HTML code 
    159159     * @see html::tag() 
     
    170170     * Derrived method for form element labels 
    171171     * 
    172      * @param mixed  Hash array with tag attributes or string with 'for' attrib 
    173      * @param string Tag content 
     172     * @param mixed  $attr Hash array with tag attributes or string with 'for' attrib 
     173     * @param string $cont Tag content 
    174174     * @return string HTML code 
    175175     * @see html::tag() 
     
    186186     * Derrived method to create <iframe></iframe> 
    187187     * 
    188      * @param mixed Hash array with tag attributes or string with frame source (src) 
     188     * @param mixed $attr Hash array with tag attributes or string with frame source (src) 
    189189     * @return string HTML code 
    190190     * @see html::tag() 
     
    213213     * Create string with attributes 
    214214     * 
    215      * @param array Associative arry with tag attributes 
    216      * @param array List of allowed attributes 
     215     * @param array $attrib Associative arry with tag attributes 
     216     * @param array $allowed List of allowed attributes 
    217217     * @return string Valid attribute string 
    218218     */ 
     
    271271        'spellcheck','results','maxlength','src'); 
    272272 
     273    /** 
     274     * Object constructor 
     275     * 
     276     * @param array $attrib Associative array with tag attributes 
     277     */ 
    273278    public function __construct($attrib = array()) 
    274279    { 
     
    289294     * Compose input tag 
    290295     * 
    291      * @param string Field value 
    292      * @param array Additional attributes to override 
     296     * @param string $value Field value 
     297     * @param array  $attrib Additional attributes to override 
    293298     * @return string HTML output 
    294299     */ 
     
    335340     * Constructor 
    336341     * 
    337      * @param array Named tag attributes 
     342     * @param array $attrib Named tag attributes 
    338343     */ 
    339344    public function __construct($attrib = null) 
     
    347352     * Add a hidden field to this instance 
    348353     * 
    349      * @param array Named tag attributes 
     354     * @param array $attrib Named tag attributes 
    350355     */ 
    351356    public function add($attrib) 
     
    381386     * Get HTML code for this object 
    382387     * 
    383      * @param string Value of the checked field 
    384      * @param array Additional attributes to override 
     388     * @param string $value  Value of the checked field 
     389     * @param array  $attrib Additional attributes to override 
    385390     * @return string HTML output 
    386391     */ 
     
    411416     * Get HTML code for this object 
    412417     * 
    413      * @param string Value of the checked field 
    414      * @param array Additional attributes to override 
     418     * @param string $value  Value of the checked field 
     419     * @param array  $attrib Additional attributes to override 
    415420     * @return string HTML output 
    416421     */ 
     
    443448     * Get HTML code for this object 
    444449     * 
    445      * @param string Textbox value 
    446      * @param array Additional attributes to override 
     450     * @param string $value  Textbox value 
     451     * @param array  $attrib Additional attributes to override 
    447452     * @return string HTML output 
    448453     */ 
     
    502507     * Add a new option to this drop-down 
    503508     * 
    504      * @param mixed Option name or array with option names 
    505      * @param mixed Option value or array with option values 
     509     * @param mixed $names  Option name or array with option names 
     510     * @param mixed $values Option value or array with option values 
    506511     */ 
    507512    public function add($names, $values = null) 
     
    521526     * Get HTML code for this object 
    522527     * 
    523      * @param string Value of the selection option 
    524      * @param array Additional attributes to override 
     528     * @param string $select Value of the selection option 
     529     * @param array  $attrib Additional attributes to override 
    525530     * @return string HTML output 
    526531     */ 
     
    563568    private $colindex = 0; 
    564569 
    565  
     570    /** 
     571     * Constructor 
     572     * 
     573     * @param array $attrib Named tag attributes 
     574     */ 
    566575    public function __construct($attrib = array()) 
    567576    { 
     
    572581     * Add a table cell 
    573582     * 
    574      * @param array Cell attributes 
    575      * @param string Cell content 
     583     * @param array  $attr Cell attributes 
     584     * @param string $cont Cell content 
    576585     */ 
    577586    public function add($attr, $cont) 
     
    596605     * Add a table header cell 
    597606     * 
    598      * @param array Cell attributes 
    599      * @param string Cell content 
     607     * @param array  $attr Cell attributes 
     608     * @param string $cont Cell content 
    600609     */ 
    601610    public function add_header($attr, $cont) 
     
    641650     * Jump to next row 
    642651     * 
    643      * @param array Row attributes 
     652     * @param array $attr Row attributes 
    644653     */ 
    645654    public function add_row($attr = array()) 
     
    655664     * Set current row attrib 
    656665     * 
    657      * @param array Row attributes 
     666     * @param array $attr Row attributes 
    658667     */ 
    659668    public function set_row_attribs($attr = array()) 
     
    668677     * Build HTML output of the table data 
    669678     * 
    670      * @param array Table attributes 
     679     * @param array $attrib Table attributes 
    671680     * @return string The final table HTML code 
    672681     */ 
  • program/include/main.inc

    re999919 r5c461ba  
    152152 * Garbage collector for cache entries. 
    153153 * Remove all expired message cache records 
     154 * @return void 
    154155 */ 
    155156function rcmail_cache_gc() 
     
    188189 * @param  string Suspected charset of the input string 
    189190 * @param  string Target charset to convert to; defaults to RCMAIL_CHARSET 
    190  * @return Converted string 
     191 * @return string Converted string 
    191192 */ 
    192193function rcube_charset_convert($str, $from, $to=NULL) 
     
    323324 * but we need strict names for charset conversion (specially utf8 class) 
    324325 * 
    325  * @param  string  Input charset name 
    326  * @return The validated charset name 
     326 * @param  string Input charset name 
     327 * @return string The validated charset name 
    327328 */ 
    328329function rcube_parse_charset($input) 
     
    428429 * 
    429430 * @param  string  Input string 
    430  * @return The converted string 
     431 * @return string  The converted string 
    431432 */ 
    432433function rcube_utf7_to_utf8($str) 
     
    487488 * 
    488489 * @param  string  Input string 
    489  * @return The converted string 
     490 * @return string  The converted string 
    490491 */ 
    491492function rcube_utf16_to_utf8($str) 
     
    518519 * @param  string  Replace mode for tags: show|replace|remove 
    519520 * @param  boolean Convert newlines 
    520  * @return The quoted string 
     521 * @return string  The quoted string 
    521522 */ 
    522523function rep_specialchars_output($str, $enctype='', $mode='', $newlines=TRUE) 
     
    10881089 * 
    10891090 * @param mixed Debug message or data 
     1091 * @return void 
    10901092 */ 
    10911093function console() 
     
    11221124 * @param $name name of log file 
    11231125 * @param line Line to append 
     1126 * @return void 
    11241127 */ 
    11251128function write_log($name, $line) 
     
    11741177/** 
    11751178 * Write login data (name, ID, IP address) to the 'userlogins' log file. 
     1179 * 
     1180 * @return void 
    11761181 */ 
    11771182function rcmail_log_login() 
     
    12021207/** 
    12031208 * @access private 
     1209 * @return mixed 
    12041210 */ 
    12051211function rcube_timer() 
     
    12111217/** 
    12121218 * @access private 
     1219 * @return void 
    12131220 */ 
    12141221function rcube_print_time($timer, $label='Timer', $dest='console') 
     
    12931300 * 
    12941301 * @param array Named parameters 
    1295  * @return object html_select HTML drop-down object 
     1302 * @return html_select HTML drop-down object 
    12961303 */ 
    12971304function rcmail_mailbox_select($p = array()) 
     
    13201327 * Create a hierarchical array of the mailbox list 
    13211328 * @access private 
     1329 * @return void 
    13221330 */ 
    13231331function rcmail_build_folder_tree(&$arrFolders, $folder, $delm='/', $path='') 
     
    13551363 * Return html for a structured list &lt;ul&gt; for the mailbox tree 
    13561364 * @access private 
     1365 * @return string 
    13571366 */ 
    13581367function rcmail_render_folder_tree_html(&$arrFolders, &$mbox_name, &$jslist, $attrib, $nestLevel=0) 
     
    14531462 * Return html for a flat list <select> for the mailbox tree 
    14541463 * @access private 
     1464 * @return string 
    14551465 */ 
    14561466function rcmail_render_folder_tree_select(&$arrFolders, &$mbox_name, $maxlength, &$select, $realnames=false, $nestLevel=0) 
     
    14861496 * Return internal name for the given folder if it matches the configured special folders 
    14871497 * @access private 
     1498 * @return string 
    14881499 */ 
    14891500function rcmail_folder_classname($folder_id) 
     
    15231534 * 
    15241535 * @param string Editor mode 
     1536 * @return void 
    15251537 */ 
    15261538function rcube_html_editor($mode='') 
     
    15531565 * @param integer HTTPS port number 
    15541566 * @param boolean Enables 'use_https' option checking 
     1567 * @return boolean 
    15551568 */ 
    15561569function rcube_https_check($port=null, $use_https=true) 
     
    15711584 
    15721585 
    1573 // for backward compatibility 
     1586/** 
     1587 * For backward compatibility. 
     1588 * 
     1589 * @global rcmail $RCMAIL 
     1590 * @param string $var_name Variable name. 
     1591 * @return void 
     1592 */ 
    15741593function rcube_sess_unset($var_name=null) 
    15751594{ 
     
    15801599 
    15811600 
    1582 // Replaces hostname variables 
     1601 
     1602/** 
     1603 * Replaces hostname variables 
     1604 * 
     1605 * @param string $name Hostname 
     1606 * @return string 
     1607 */ 
    15831608function rcube_parse_host($name) 
    15841609{ 
     
    15991624/** 
    16001625 * E-mail address validation 
     1626 * 
     1627 * @param string $email Email address 
     1628 * @param boolean $dns_check True to check dns 
     1629 * @return boolean 
    16011630 */ 
    16021631function check_email($email, $dns_check=true) 
     
    17241753 * 
    17251754 * @param array Named parameters 
     1755 * @return void 
    17261756 * @see raise_error() 
    17271757 */ 
  • program/include/rcmail.php

    re999919 r5c461ba  
    2929class rcmail 
    3030{ 
     31  /** 
     32   * Main tasks. 
     33   * 
     34   * @var array 
     35   */ 
    3136  static public $main_tasks = array('mail','settings','addressbook','login','logout','utils','dummy'); 
    3237 
     38  /** 
     39   * Singleton instace of rcmail 
     40   * 
     41   * @var rcmail 
     42   */ 
    3343  static private $instance; 
    3444 
     45  /** 
     46   * Stores instance of rcube_config. 
     47   * 
     48   * @var rcube_config 
     49   */ 
    3550  public $config; 
     51 
     52  /** 
     53   * Stores rcube_user instance. 
     54   * 
     55   * @var rcube_user 
     56   */ 
    3657  public $user; 
     58 
     59  /** 
     60   * Instace of database class. 
     61   * 
     62   * @var rcube_mdb2 
     63   */ 
    3764  public $db; 
     65 
     66  /** 
     67   * Instace of rcube_session class. 
     68   * 
     69   * @var rcube_session 
     70   */ 
    3871  public $session; 
     72 
     73  /** 
     74   * Instance of rcube_smtp class. 
     75   * 
     76   * @var rcube_smtp 
     77   */ 
    3978  public $smtp; 
     79 
     80  /** 
     81   * Instance of rcube_imap class. 
     82   * 
     83   * @var rcube_imap 
     84   */ 
    4085  public $imap; 
     86 
     87  /** 
     88   * Instance of rcube_template class. 
     89   * 
     90   * @var rcube_template 
     91   */ 
    4192  public $output; 
     93 
     94  /** 
     95   * Instance of rcube_plugin_api. 
     96   * 
     97   * @var rcube_plugin_api 
     98   */ 
    4299  public $plugins; 
     100 
     101  /** 
     102   * Current task. 
     103   * 
     104   * @var string 
     105   */ 
    43106  public $task; 
     107 
     108  /** 
     109   * Current action. 
     110   * 
     111   * @var string 
     112   */ 
    44113  public $action = ''; 
    45114  public $comm_path = './'; 
     
    52121   * This implements the 'singleton' design pattern 
    53122   * 
    54    * @return object rcmail The one and only instance 
     123   * @return rcmail The one and only instance 
    55124   */ 
    56125  static function get_instance() 
     
    155224   * Setter for system user object 
    156225   * 
    157    * @param object rcube_user Current user instance 
     226   * @param rcube_user Current user instance 
    158227   */ 
    159228  public function set_user($user) 
     
    227296   * Get the current database connection 
    228297   * 
    229    * @return object rcube_mdb2  Database connection object 
     298   * @return rcube_mdb2  Database connection object 
    230299   */ 
    231300  public function get_dbh() 
     
    248317   * @param string  Address book identifier 
    249318   * @param boolean True if the address book needs to be writeable 
    250    * @return object rcube_contacts Address book object 
     319   * @return rcube_contacts Address book object 
    251320   */ 
    252321  public function get_address_book($id, $writeable = false) 
     
    347416   * 
    348417   * @param boolean True if this request is loaded in a (i)frame 
    349    * @return object rcube_template Reference to HTML output object 
     418   * @return rcube_template Reference to HTML output object 
    350419   */ 
    351420  public function load_gui($framed = false) 
     
    380449   * Create an output object for JSON responses 
    381450   * 
    382    * @return object rcube_json_output Reference to JSON output object 
     451   * @return rcube_json_output Reference to JSON output object 
    383452   */ 
    384453  public function json_init() 
  • program/include/rcube_addressbook.php

    re019f2d r5c461ba  
    8484     * Count number of available contacts in database 
    8585     * 
    86      * @return object rcube_result_set Result set with values for 'count' and 'first' 
     86     * @return rcube_result_set Result set with values for 'count' and 'first' 
    8787     */ 
    8888    abstract function count(); 
     
    9191     * Return the last result set 
    9292     * 
    93      * @return object rcube_result_set Current result set or NULL if nothing selected yet 
     93     * @return rcube_result_set Current result set or NULL if nothing selected yet 
    9494     */ 
    9595    abstract function get_result(); 
     
    143143     * @param array Assoziative array with save data 
    144144     * @param boolean True to check for duplicates first 
    145      * @return The created record ID on success, False on error 
     145     * @return mixed The created record ID on success, False on error 
    146146     */ 
    147147    function insert($save_data, $check=false) 
     
    155155     * @param mixed Record identifier 
    156156     * @param array Assoziative array with save data 
    157      * @return True on success, False on error 
     157     * @return boolean True on success, False on error 
    158158     */ 
    159159    function update($id, $save_cols) 
     
    184184     * 
    185185     * @param string The group name 
    186      * @return False on error, array with record props in success 
     186     * @return mixed False on error, array with record props in success 
    187187     */ 
    188188    function create_group($name) 
  • program/include/rcube_config.php

    re999919 r5c461ba  
    131131     * and merge with the already stored config values 
    132132     * 
    133      * @param string Full path to the config file to be loaded 
     133     * @param string $fpath Full path to the config file to be loaded 
    134134     * @return booelan True on success, false on failure 
    135135     */ 
     
    151151     * Getter for a specific config parameter 
    152152     * 
    153      * @param  string Parameter name 
    154      * @param  mixed  Default value if not set 
     153     * @param  string $name Parameter name 
     154     * @param  mixed  $def  Default value if not set 
    155155     * @return mixed  The requested config value 
    156156     */ 
     
    164164     * Setter for a config parameter 
    165165     * 
    166      * @param string Parameter name 
    167      * @param mixed  Parameter value 
     166     * @param string $name  Parameter name 
     167     * @param mixed  $value Parameter value 
    168168     */ 
    169169    public function set($name, $value) 
     
    176176     * Override config options with the given values (eg. user prefs) 
    177177     * 
    178      * @param array Hash array with config props to merge over 
     178     * @param array $prefs Hash array with config props to merge over 
    179179     */ 
    180180    public function merge($prefs) 
     
    188188     * and make sure that they survive further merging. 
    189189     * 
    190      * @param array Hash array with user prefs 
     190     * @param array $prefs Hash array with user prefs 
    191191     */ 
    192192    public function set_user_prefs($prefs) 
     
    211211     * Return requested DES crypto key. 
    212212     * 
    213      * @param string Crypto key name 
     213     * @param string $key Crypto key name 
    214214     * @return string Crypto key 
    215215     */ 
     
    275275     * Return the mail domain configured for the given host 
    276276     * 
    277      * @param string  IMAP host 
    278      * @param boolean If true, domain name will be converted to IDN ASCII 
     277     * @param string  $host   IMAP host 
     278     * @param boolean $encode If true, domain name will be converted to IDN ASCII 
    279279     * @return string Resolved SMTP host 
    280280     */ 
  • program/include/rcube_contacts.php

    re019f2d r5c461ba  
    3333    protected $db_groupmembers = 'contactgroupmembers'; 
    3434 
     35    /** 
     36     * Store database connection. 
     37     * 
     38     * @var rcube_mdb2 
     39     */ 
    3540    private $db = null; 
    3641    private $user_id = 0; 
     
    311316     * Return the last result set 
    312317     * 
    313      * @return Result array or NULL if nothing selected yet 
     318     * @return mixed Result array or NULL if nothing selected yet 
    314319     */ 
    315320    function get_result() 
     
    323328     * 
    324329     * @param mixed record identifier(s) 
    325      * @return Result object with all record fields or False if not found 
     330     * @return mixed Result object with all record fields or False if not found 
    326331     */ 
    327332    function get_record($id, $assoc=false) 
     
    354359     * 
    355360     * @param array Assoziative array with save data 
    356      * @return The created record ID on success, False on error 
     361     * @return integer|boolean The created record ID on success, False on error 
    357362     */ 
    358363    function insert($save_data, $check=false) 
     
    413418     * @param mixed Record identifier 
    414419     * @param array Assoziative array with save data 
    415      * @return True on success, False on error 
     420     * @return boolean True on success, False on error 
    416421     */ 
    417422    function update($id, $save_cols) 
     
    485490     * 
    486491     * @param string The group name 
    487      * @return False on error, array with record props in success 
     492     * @return mixed False on error, array with record props in success 
    488493     */ 
    489494    function create_group($name) 
  • program/include/rcube_html_page.php

    re019f2d r5c461ba  
    8585    /** 
    8686     * Add HTML code to the page header 
     87     * 
     88     * @param string $str HTML code 
    8789     */ 
    8890    public function add_header($str) 
     
    9496     * Add HTML code to the page footer 
    9597     * To be added right befor </body> 
     98     * 
     99     * @param string $str HTML code 
    96100     */ 
    97101    public function add_footer($str) 
     
    102106    /** 
    103107     * Setter for page title 
     108     * 
     109     * @param string $t Page title 
    104110     */ 
    105111    public function set_title($t) 
     
    111117     * Setter for output charset. 
    112118     * To be specified in a meta tag and sent as http-header 
     119     * 
     120     * @param string $charset Charset 
    113121     */ 
    114122    public function set_charset($charset) 
     
    119127    /** 
    120128     * Getter for output charset 
     129     * 
     130     * @return string Output charset 
    121131     */ 
    122132    public function get_charset() 
     
    264274    /** 
    265275     * Callback function for preg_replace_callback in write() 
     276     * 
     277     * @return string Parsed string 
    266278     */ 
    267279    private function file_callback($matches) 
  • program/include/rcube_imap.php

    rc609784 r5c461ba  
    4141    public $threading = false; 
    4242    public $fetch_add_headers = ''; 
    43     public $conn; // rcube_imap_generic object 
    44  
     43 
     44    /** 
     45     * Instance of rcube_imap_generic 
     46     * 
     47     * @var rcube_imap_generic 
     48     */ 
     49    public $conn; 
     50 
     51    /** 
     52     * Instance of rcube_mdb2 
     53     * 
     54     * @var rcube_mdb2 
     55     */ 
    4556    private $db; 
    4657    private $root_ns = ''; 
     
    8495     * Connect to an IMAP server 
    8596     * 
    86      * @param  string   Host to connect 
    87      * @param  string   Username for IMAP account 
    88      * @param  string   Password for IMAP account 
    89      * @param  number   Port to connect to 
    90      * @param  string   SSL schema (either ssl or tls) or null if plain connection 
     97     * @param  string   $host    Host to connect 
     98     * @param  string   $user    Username for IMAP account 
     99     * @param  string   $pass    Password for IMAP account 
     100     * @param  integer  $port    Port to connect to 
     101     * @param  string   $use_ssl SSL schema (either ssl or tls) or null if plain connection 
    91102     * @return boolean  TRUE on success, FALSE on failure 
    92103     * @access public 
     
    181192    /** 
    182193     * Set options to be used in rcube_imap_generic::connect() 
     194     * 
     195     * @param array $opt Options array 
    183196     */ 
    184197    function set_options($opt) 
     
    193206     * and all folder paths will be translated using this folder name 
    194207     * 
    195      * @param  string   Root folder 
     208     * @param  string   $root Root folder 
    196209     * @access public 
    197210     */ 
     
    214227     * This will be used for message decoding if a charset specification is not available 
    215228     * 
    216      * @param  string   Charset string 
     229     * @param  string $cs Charset string 
    217230     * @access public 
    218231     */ 
     
    226239     * This list of folders will be listed above all other folders 
    227240     * 
    228      * @param  array Indexed list of folder names 
     241     * @param  array $arr Indexed list of folder names 
    229242     * @access public 
    230243     */ 
     
    246259     * All operations will be perfomed on this mailbox/folder 
    247260     * 
    248      * @param  string Mailbox/Folder name 
     261     * @param  string $new_mbox Mailbox/Folder name 
    249262     * @access public 
    250263     */ 
     
    266279     * Set internal list page 
    267280     * 
    268      * @param  number Page number to list 
     281     * @param  number $page Page number to list 
    269282     * @access public 
    270283     */ 
     
    278291     * Set internal page size 
    279292     * 
    280      * @param  number Number of messages to display on one page 
     293     * @param  number $size Number of messages to display on one page 
    281294     * @access public 
    282295     */ 
     
    345358     * Returns the IMAP server's capability 
    346359     * 
    347      * @param   string  Capability name 
     360     * @param   string  $cap Capability name 
    348361     * @return  mixed   Capability value or TRUE if supported, FALSE if not 
    349362     * @access  public 
     
    358371     * Sets threading flag to the best supported THREAD algorithm 
    359372     * 
    360      * @param  boolean  TRUE to enable and FALSE 
     373     * @param  boolean  $enable TRUE to enable and FALSE 
    361374     * @return string   Algorithm or false if THREAD is not supported 
    362375     * @access public 
     
    383396     * and returns true if the given flag is supported by the IMAP server 
    384397     * 
    385      * @param   string  Permanentflag name 
     398     * @param   string  $flag Permanentflag name 
    386399     * @return  mixed   True if this flag is supported 
    387400     * @access  public 
     
    416429     * Get message count for a specific mailbox 
    417430     * 
    418      * @param  string  Mailbox/folder name 
    419      * @param  string  Mode for count [ALL|THREADS|UNSEEN|RECENT] 
    420      * @param  boolean Force reading from server and update cache 
    421      * @param  boolean Enables storing folder status info (max UID/count), 
    422      *                 required for mailbox_status() 
     431     * @param  string  $mbox_name Mailbox/folder name 
     432     * @param  string  $mode      Mode for count [ALL|THREADS|UNSEEN|RECENT] 
     433     * @param  boolean $force     Force reading from server and update cache 
     434     * @param  boolean $status    Enables storing folder status info (max UID/count), 
     435     *                            required for mailbox_status() 
    423436     * @return int     Number of messages 
    424437     * @access public 
     
    434447     * Private method for getting nr of messages 
    435448     * 
     449     * @param string  $mailbox Mailbox name 
     450     * @param string  $mode    Mode for count [ALL|THREADS|UNSEEN|RECENT] 
     451     * @param boolean $force   Force reading from server and update cache 
     452     * @param boolean $status  Enables storing folder status info (max UID/count), 
     453     *                         required for mailbox_status() 
     454     * @return int Number of messages 
    436455     * @access  private 
    437456     * @see     rcube_imap::messagecount() 
     
    514533     * Private method for getting nr of threads 
    515534     * 
     535     * @param string $mailbox 
     536     * @param int    $msg_count 
    516537     * @access  private 
    517538     * @see     rcube_imap::messagecount() 
     
    535556     * convert mailbox name with root dir first 
    536557     * 
    537      * @param   string   Mailbox/folder name 
    538      * @param   int      Current page to list 
    539      * @param   string   Header field to sort by 
    540      * @param   string   Sort order [ASC|DESC] 
    541      * @param   boolean  Number of slice items to extract from result array 
     558     * @param   string   $mbox_name  Mailbox/folder name 
     559     * @param   int      $page       Current page to list 
     560     * @param   string   $sort_field Header field to sort by 
     561     * @param   string   $sort_order Sort order [ASC|DESC] 
     562     * @param   int      $slice      Number of slice items to extract from result array 
    542563     * @return  array    Indexed array with message header objects 
    543564     * @access  public 
     
    553574     * Private method for listing message headers 
    554575     * 
     576     * @param   string   $mailbox    Mailbox name 
     577     * @param   int      $page       Current page to list 
     578     * @param   string   $sort_field Header field to sort by 
     579     * @param   string   $sort_order Sort order [ASC|DESC] 
     580     * @param   int      $slice      Number of slice items to extract from result array 
     581     * @return  array    Indexed array with message header objects 
    555582     * @access  private 
    556583     * @see     rcube_imap::list_headers 
     
    677704     * Private method for listing message headers using threads 
    678705     * 
     706     * @param   string   $mailbox    Mailbox/folder name 
     707     * @param   int      $page       Current page to list 
     708     * @param   string   $sort_field Header field to sort by 
     709     * @param   string   $sort_order Sort order [ASC|DESC] 
     710     * @param   boolean  $recursive   
     711     * @param   int      $slice      Number of slice items to extract from result array 
     712     * @return  array    Indexed array with message header objects 
    679713     * @access  private 
    680714     * @see     rcube_imap::list_headers 
     
    704738     * Private method for fetching threads data 
    705739     * 
    706      * @param   string   Mailbox/folder name 
     740     * @param   string   $mailbox Mailbox/folder name 
    707741     * @return  array    Array with thread data 
    708742     * @access  private 
     
    733767     * Private method for fetching threaded messages headers 
    734768     * 
     769     * @param string  $mailbox Mailbox name 
     770     * @param string  $thread_tree 
     771     * @param int     $msg_depth 
     772     * @param boolean $has_children 
     773     * @param int     $msg_index 
     774     * @param int     $page 
     775     * @param int     $slice 
    735776     * @access  private 
    736777     */ 
     
    780821     * depth, has_children and unread_children 
    781822     * 
    782      * @param  array  Reference to headers array indexed by message ID 
    783      * @param  array  Array of messages depth indexed by message ID 
    784      * @param  array  Array of messages children flags indexed by message ID 
     823     * @param  array  $headers      Reference to headers array indexed by message ID 
     824     * @param  array  $msg_depth    Array of messages depth indexed by message ID 
     825     * @param  array  $msg_children Array of messages children flags indexed by message ID 
    785826     * @return array   Message headers array indexed by message ID 
    786827     * @access private 
     
    811852     * Private method for listing a set of message headers (search results) 
    812853     * 
    813      * @param   string   Mailbox/folder name 
    814      * @param   int      Current page to list 
    815      * @param   string   Header field to sort by 
    816      * @param   string   Sort order [ASC|DESC] 
    817      * @param   boolean  Number of slice items to extract from result array 
     854     * @param   string   $mailbox    Mailbox/folder name 
     855     * @param   int      $page       Current page to list 
     856     * @param   string   $sort_field Header field to sort by 
     857     * @param   string   $sort_order Sort order [ASC|DESC] 
     858     * @param   int  $slice      Number of slice items to extract from result array 
    818859     * @return  array    Indexed array with message header objects 
    819860     * @access  private 
     
    944985     * Private method for listing a set of threaded message headers (search results) 
    945986     * 
    946      * @param   string   Mailbox/folder name 
    947      * @param   int      Current page to list 
    948      * @param   string   Header field to sort by 
    949      * @param   string   Sort order [ASC|DESC] 
    950      * @param   boolean  Number of slice items to extract from result array 
     987     * @param   string   $mailbox    Mailbox/folder name 
     988     * @param   int      $page       Current page to list 
     989     * @param   string   $sort_field Header field to sort by 
     990     * @param   string   $sort_order Sort order [ASC|DESC] 
     991     * @param   int      $slice      Number of slice items to extract from result array 
    951992     * @return  array    Indexed array with message header objects 
    952993     * @access  private 
     
    9861027     * Helper function to get first and last index of the requested set 
    9871028     * 
    988      * @param  int     message count 
    989      * @param  mixed   page number to show, or string 'all' 
     1029     * @param  int     $max  message count 
     1030     * @param  mixed   $page page number to show, or string 'all' 
    9901031     * @return array   array with two values: first index, last index 
    9911032     * @access private 
     
    10851126     * new messages because the RECENT flag is not reliable. 
    10861127     * 
    1087      * @param string Mailbox/folder name 
     1128     * @param string $mbox_name Mailbox/folder name 
    10881129     * @return int   Folder status 
    10891130     */ 
     
    11171158     * @TODO: move to separate DB table (cache?) 
    11181159     * 
    1119      * @param string Mailbox name 
    1120      * @param string Data name 
    1121      * @param mixed  Data value 
     1160     * @param string $mbox_name Mailbox name 
     1161     * @param string $name      Data name 
     1162     * @param mixed  $data      Data value 
    11221163     */ 
    11231164    private function set_folder_stats($mbox_name, $name, $data) 
     
    11301171     * Gets folder statistic data 
    11311172     * 
    1132      * @param string Mailbox name 
     1173     * @param string $mbox_name Mailbox name 
    11331174     * @return array Stats data 
    11341175     */ 
     
    11451186     * Return sorted array of message IDs (not UIDs) 
    11461187     * 
    1147      * @param string Mailbox to get index from 
    1148      * @param string Sort column 
    1149      * @param string Sort order [ASC, DESC] 
     1188     * @param string $mbox_name  Mailbox to get index from 
     1189     * @param string $sort_field Sort column 
     1190     * @param string $sort_order Sort order [ASC, DESC] 
    11501191     * @return array Indexed array with message ids 
    11511192     */ 
     
    12581299     * Return sorted array of threaded message IDs (not UIDs) 
    12591300     * 
    1260      * @param string Mailbox to get index from 
    1261      * @param string Sort column 
    1262      * @param string Sort order [ASC, DESC] 
     1301     * @param string $mbox_name  Mailbox to get index from 
     1302     * @param string $sort_field Sort column 
     1303     * @param string $sort_order Sort order [ASC, DESC] 
    12631304     * @return array Indexed array with message IDs 
    12641305     */ 
     
    13041345     * Return array of threaded messages (all, not only roots) 
    13051346     * 
    1306      * @param string Mailbox to get index from 
    1307      * @param array  Threaded messages array (see _fetch_threads()) 
    1308      * @param array  Message IDs if we know what we need (e.g. search result) 
    1309      *               for better performance 
     1347     * @param string $mailbox     Mailbox to get index from 
     1348     * @param array  $thread_tree Threaded messages array (see _fetch_threads()) 
     1349     * @param array  $ids         Message IDs if we know what we need (e.g. search result) 
     1350     *                            for better performance 
    13101351     * @return array Indexed array with message IDs 
    13111352     * 
     
    13371378 
    13381379    /** 
     1380     * @param string $mailbox Mailbox name 
    13391381     * @access private 
    13401382     */ 
     
    14311473     * Invoke search request to IMAP server 
    14321474     * 
    1433      * @param  string  mailbox name to search in 
    1434      * @param  string  search string 
    1435      * @param  string  search string charset 
    1436      * @param  string  header field to sort by 
     1475     * @param  string  $mbox_name  mailbox name to search in 
     1476     * @param  string  $str        search string 
     1477     * @param  string  $charset    search string charset 
     1478     * @param  string  $sort_field header field to sort by 
    14371479     * @return array   search results as list of message ids 
    14381480     * @access public 
     
    14571499     * Private search method 
    14581500     * 
     1501     * @param string $mailbox    Mailbox name 
     1502     * @param string $criteria   Search criteria 
     1503     * @param string $charset    Charset 
     1504     * @param string $sort_field Sorting field 
    14591505     * @return array   search results as list of message ids 
    14601506     * @access private 
     
    15331579     * without result sorting and caching 
    15341580     * 
    1535      * @param  string  Mailbox name to search in 
    1536      * @param  string  Search string 
    1537      * @param  boolean True if UIDs should be returned 
     1581     * @param  string  $mbox_name Mailbox name to search in 
     1582     * @param  string  $str       Search string 
     1583     * @param  boolean $ret_uid   True if UIDs should be returned 
    15381584     * @return array   Search results as list of message IDs or UIDs 
    15391585     * @access public 
     
    15531599     * Converts charset of search criteria string 
    15541600     * 
    1555      * @param  string  Search string 
    1556      * @param  string  Original charset 
    1557      * @param  string  Destination charset (default US-ASCII) 
     1601     * @param  string  $str          Search string 
     1602     * @param  string  $charset      Original charset 
     1603     * @param  string  $dest_charset Destination charset (default US-ASCII) 
    15581604     * @return string  Search string 
    15591605     * @access private 
     
    15861632     * Sort thread 
    15871633     * 
    1588      * @param string Mailbox name 
    1589      * @param  array Unsorted thread tree (rcube_imap_generic::thread() result) 
    1590      * @param  array Message IDs if we know what we need (e.g. search result) 
     1634     * @param string $mailbox     Mailbox name 
     1635     * @param  array $thread_tree Unsorted thread tree (rcube_imap_generic::thread() result) 
     1636     * @param  array $ids         Message IDs if we know what we need (e.g. search result) 
    15911637     * @return array Sorted roots IDs 
    15921638     * @access private 
     
    16331679     * THREAD=REFS sorting implementation 
    16341680     * 
    1635      * @param  array   Thread tree array (message identifiers as keys) 
    1636      * @param  array   Array of sorted message identifiers 
     1681     * @param  array $tree  Thread tree array (message identifiers as keys) 
     1682     * @param  array $index Array of sorted message identifiers 
    16371683     * @return array   Array of sorted roots messages 
    16381684     * @access private 
     
    16941740     * Check if the given message ID is part of the current search set 
    16951741     * 
     1742     * @param string $msgid Message id 
    16961743     * @return boolean True on match or if no search request is stored 
    16971744     */ 
     
    17121759     * Return message headers object of a specific message 
    17131760     * 
    1714      * @param int     Message ID 
    1715      * @param string  Mailbox to read from 
    1716      * @param boolean True if $id is the message UID 
    1717      * @param boolean True if we need also BODYSTRUCTURE in headers 
     1761     * @param int     $id        Message ID 
     1762     * @param string  $mbox_name Mailbox to read from 
     1763     * @param boolean $is_uid    True if $id is the message UID 
     1764     * @param boolean $bodystr   True if we need also BODYSTRUCTURE in headers 
    17181765     * @return object Message headers representation 
    17191766     */ 
     
    17461793     * an object structure similar to the one generated by PEAR::Mail_mimeDecode 
    17471794     * 
    1748      * @param int Message UID to fetch 
    1749      * @param string Message BODYSTRUCTURE string (optional) 
     1795     * @param int    $uid           Message UID to fetch 
     1796     * @param string $structure_str Message BODYSTRUCTURE string (optional) 
    17501797     * @return object rcube_message_part Message part tree or False on failure 
    17511798     */ 
     
    18181865     * Build message part object 
    18191866     * 
     1867     * @param array  $part 
     1868     * @param int    $count 
     1869     * @param string $parent 
    18201870     * @access private 
    18211871     */ 
     
    20052055     * 
    20062056     * @access private 
    2007      * @param  object rcube_message_part Part object 
    2008      * @param  string Part's raw headers 
     2057     * @param  rcube_message_part $part    Part object 
     2058     * @param  string             $headers Part's raw headers 
    20092059     */ 
    20102060    private function _set_part_filename(&$part, $headers=null) 
     
    21262176     * 
    21272177     * @access private 
    2128      * @param  array Message structure 
     2178     * @param  array $structure Message structure 
    21292179     * @return string Charset name 
    21302180     */ 
     
    21422192     * Fetch message body of a specific message from the server 
    21432193     * 
    2144      * @param  int    Message UID 
    2145      * @param  string Part number 
    2146      * @param  object rcube_message_part Part object created by get_structure() 
    2147      * @param  mixed  True to print part, ressource to write part contents in 
    2148      * @param  resource File pointer to save the message part 
     2194     * @param  int                $uid    Message UID 
     2195     * @param  string             $part   Part number 
     2196     * @param  rcube_message_part $o_part Part object created by get_structure() 
     2197     * @param  mixed              $print  True to print part, ressource to write part contents in 
     2198     * @param  resource           $fp     File pointer to save the message part 
    21492199     * @return string Message/part body if not printed 
    21502200     */ 
     
    21922242     * Fetch message body of a specific message from the server 
    21932243     * 
    2194      * @param  int    Message UID 
    2195      * @return string Message/part body 
     2244     * @param  int    $uid  Message UID 
     2245     * @return string $part Message/part body 
    21962246     * @see    rcube_imap::get_message_part() 
    21972247     */ 
     
    22072257     * Returns the whole message source as string 
    22082258     * 
    2209      * @param int Message UID 
     2259     * @param int $uid Message UID 
    22102260     * @return string Message source string 
    22112261     */ 
     
    22192269     * Returns the message headers as string 
    22202270     * 
    2221      * @param int Message UID 
     2271     * @param int $uid Message UID 
    22222272     * @return string Message headers string 
    22232273     */ 
     
    22312281     * Sends the whole message source to stdout 
    22322282     * 
    2233      * @param int Message UID 
     2283     * @param int $uid Message UID 
    22342284     */ 
    22352285    function print_raw_body($uid) 
     
    22422292     * Set message flag to one or several messages 
    22432293     * 
    2244      * @param mixed   Message UIDs as array or comma-separated string, or '*' 
    2245      * @param string  Flag to set: SEEN, UNDELETED, DELETED, RECENT, ANSWERED, DRAFT, MDNSENT 
    2246      * @param string  Folder name 
    2247      * @param boolean True to skip message cache clean up 
     2294     * @param mixed   $uids       Message UIDs as array or comma-separated string, or '*' 
     2295     * @param string  $flag       Flag to set: SEEN, UNDELETED, DELETED, RECENT, ANSWERED, DRAFT, MDNSENT 
     2296     * @param string  $mbox_name  Folder name 
     2297     * @param boolean $skip_cache True to skip message cache clean up 
    22482298     * @return int    Number of flagged messages, -1 on failure 
    22492299     */ 
     
    22852335     * Remove message flag for one or several messages 
    22862336     * 
    2287      * @param mixed  Message UIDs as array or comma-separated string, or '*' 
    2288      * @param string Flag to unset: SEEN, DELETED, RECENT, ANSWERED, DRAFT, MDNSENT 
    2289      * @param string Folder name 
     2337     * @param mixed  $uids      Message UIDs as array or comma-separated string, or '*' 
     2338     * @param string $flag      Flag to unset: SEEN, DELETED, RECENT, ANSWERED, DRAFT, MDNSENT 
     2339     * @param string $mbox_name Folder name 
    22902340     * @return int   Number of flagged messages, -1 on failure 
    22912341     * @see set_flag 
     
    23002350     * Append a mail message (source) to a specific mailbox 
    23012351     * 
    2302      * @param string  Target mailbox 
    2303      * @param string  The message source string or filename 
    2304      * @param string  Headers string if $message contains only the body 
    2305      * @param boolean True if $message is a filename 
     2352     * @param string  $mbox_name Target mailbox 
     2353     * @param string  $message  The message source string or filename 
     2354     * @param string  $headers  Headers string if $message contains only the body 
     2355     * @param boolean $is_file  True if $message is a filename 
    23062356     * 
    23072357     * @return boolean True on success, False on error 
     
    23312381     * Move a message from one mailbox to another 
    23322382     * 
    2333      * @param mixed  Message UIDs as array or comma-separated string, or '*' 
    2334      * @param string Target mailbox 
    2335      * @param string Source mailbox 
     2383     * @param mixed  $uids      Message UIDs as array or comma-separated string, or '*' 
     2384     * @param string $to_mbox   Target mailbox 
     2385     * @param string $from_mbox Source mailbox 
    23362386     * @return boolean True on success, False on error 
    23372387     */ 
     
    24122462     * Copy a message from one mailbox to another 
    24132463     * 
    2414      * @param mixed  Message UIDs as array or comma-separated string, or '*' 
    2415      * @param string Target mailbox 
    2416      * @param string Source mailbox 
     2464     * @param mixed  $uids      Message UIDs as array or comma-separated string, or '*' 
     2465     * @param string $to_mbox   Target mailbox 
     2466     * @param string $from_mbox Source mailbox 
    24172467     * @return boolean True on success, False on error 
    24182468     */ 
     
    24532503     * Mark messages as deleted and expunge mailbox 
    24542504     * 
    2455      * @param mixed  Message UIDs as array or comma-separated string, or '*' 
    2456      * @param string Source mailbox 
     2505     * @param mixed  $uids      Message UIDs as array or comma-separated string, or '*' 
     2506     * @param string $mbox_name Source mailbox 
    24572507     * @return boolean True on success, False on error 
    24582508     */ 
     
    25072557     * Clear all messages in a specific mailbox 
    25082558     * 
    2509      * @param string Mailbox name 
     2559     * @param string $mbox_name Mailbox name 
    25102560     * @return int Above 0 on success 
    25112561     */ 
     
    25362586     * Send IMAP expunge command and clear cache 
    25372587     * 
    2538      * @param string Mailbox name 
    2539      * @param boolean False if cache should not be cleared 
     2588     * @param string  $mbox_name   Mailbox name 
     2589     * @param boolean $clear_cache False if cache should not be cleared 
    25402590     * @return boolean True on success 
    25412591     */ 
     
    25502600     * Send IMAP expunge command and clear cache 
    25512601     * 
    2552      * @param string     Mailbox name 
    2553      * @param boolean False if cache should not be cleared 
    2554      * @param mixed    Message UIDs as array or comma-separated string, or '*' 
     2602     * @param string  $mailbox    Mailbox name 
     2603     * @param boolean $clear_cache False if cache should not be cleared 
     2604     * @param mixed   $uids        Message UIDs as array or comma-separated string, or '*' 
    25552605     * @return boolean True on success 
    25562606     * @access private 
     
    25782628     * Parse message UIDs input 
    25792629     * 
    2580      * @param mixed  UIDs array or comma-separated list or '*' or '1:*' 
    2581      * @param string Mailbox name 
     2630     * @param mixed  $uids    UIDs array or comma-separated list or '*' or '1:*' 
     2631     * @param string $mailbox Mailbox name 
    25822632     * @return array Two elements array with UIDs converted to list and ALL flag 
    25832633     * @access private 
     
    26212671     * Translate UID to message ID 
    26222672     * 
    2623      * @param int    Message UID 
    2624      * @param string Mailbox name 
     2673     * @param int    $uid       Message UID 
     2674     * @param string $mbox_name Mailbox name 
    26252675     * @return int   Message ID 
    26262676     */ 
     
    26352685     * Translate message number to UID 
    26362686     * 
    2637      * @param int    Message ID 
    2638      * @param string Mailbox name 
     2687     * @param int    $id        Message ID 
     2688     * @param string $mbox_name Mailbox name 
    26392689     * @return int   Message UID 
    26402690     */ 
     
    26562706     * Converts mailbox name with root dir first 
    26572707     * 
    2658      * @param   string  Optional root folder 
    2659      * @param   string  Optional filter for mailbox listing 
     2708     * @param   string  $root   Optional root folder 
     2709     * @param   string  $filter Optional filter for mailbox listing 
    26602710     * @return  array   List of mailboxes/folders 
    26612711     * @access  public 
     
    26862736     * Private method for mailbox listing 
    26872737     * 
     2738     * @param   string  $root   Optional root folder 
     2739     * @param   string  $filter Optional filter for mailbox listing 
    26882740     * @return  array   List of mailboxes/folders 
    26892741     * @see     rcube_imap::list_mailboxes() 
     
    27242776     * Get a list of all folders available on the IMAP server 
    27252777     * 
    2726      * @param string IMAP root dir 
    2727      * @param string Optional filter for mailbox listing 
     2778     * @param string $root   IMAP root dir 
     2779     * @param string $filter Optional filter for mailbox listing 
    27282780     * @return array Indexed array with folder names 
    27292781     */ 
     
    27812833     * Subscribe to a specific mailbox(es) 
    27822834     * 
    2783      * @param array Mailbox name(s) 
     2835     * @param array $a_mboxes Mailbox name(s) 
    27842836     * @return boolean True on success 
    27852837     */ 
     
    27972849     * Unsubscribe mailboxes 
    27982850     * 
    2799      * @param array Mailbox name(s) 
     2851     * @param array $a_mboxes Mailbox name(s) 
    28002852     * @return boolean True on success 
    28012853     */ 
     
    28132865     * Create a new mailbox on the server and register it in local cache 
    28142866     * 
    2815      * @param string  New mailbox name (as utf-7 string) 
    2816      * @param boolean True if the new mailbox should be subscribed 
     2867     * @param string  $name      New mailbox name (as utf-7 string) 
     2868     * @param boolean $subscribe True if the new mailbox should be subscribed 
    28172869     * @param string  Name of the created mailbox, false on error 
    28182870     */ 
     
    28372889     * Set a new name to an existing mailbox 
    28382890     * 
    2839      * @param string Mailbox to rename (as utf-7 string) 
    2840      * @param string New mailbox name (as utf-7 string) 
     2891     * @param string $mbox_name Mailbox to rename (as utf-7 string) 
     2892     * @param string $new_name  New mailbox name (as utf-7 string) 
    28412893     * @return string Name of the renames mailbox, False on error 
    28422894     */ 
     
    28902942     * Remove mailboxes from server 
    28912943     * 
    2892      * @param string Mailbox name(s) string/array 
     2944     * @param string|array $mbox_name sMailbox name(s) string/array 
    28932945     * @return boolean True on success 
    28942946     */ 
     
    29573009     * Checks if folder exists and is subscribed 
    29583010     * 
    2959      * @param string   Folder name 
    2960      * @param boolean  Enable subscription checking 
     3011     * @param string   $mbox_name    Folder name 
     3012     * @param boolean  $subscription Enable subscription checking 
    29613013     * @return boolean TRUE or FALSE 
    29623014     */ 
     
    29913043     * Modify folder name for input/output according to root dir and namespace 
    29923044     * 
    2993      * @param string  Folder name 
    2994      * @param string  Mode 
     3045     * @param string  $mbox_name Folder name 
     3046     * @param string  $mode      Mode 
    29953047     * @return string Folder name 
    29963048     */ 
     
    30163068 
    30173069    /** 
     3070     * Enable or disable caching 
     3071     * 
     3072     * @param boolean $set Flag 
    30183073     * @access public 
    30193074     */ 
     
    30273082 
    30283083    /** 
     3084     * Returns cached value 
     3085     * 
     3086     * @param string $key Cache key 
     3087     * @return mixed 
    30293088     * @access public 
    30303089     */ 
     
    30403099 
    30413100    /** 
     3101     * Update cache 
     3102     * 
     3103     * @param string $key  Cache key 
     3104     * @param mixed  $data Data 
    30423105     * @access private 
    30433106     */ 
     
    30503113 
    30513114    /** 
     3115     * Writes the cache 
     3116     * 
    30523117     * @access private 
    30533118     */ 
     
    30633128 
    30643129    /** 
     3130     * Clears the cache. 
     3131     * 
     3132     * @param string $key Cache key 
    30653133     * @access public 
    30663134     */ 
     
    30863154 
    30873155    /** 
     3156     * Returns cached entry 
     3157     * 
     3158     * @param string $key Cache key 
     3159     * @return mixed Cached value 
    30883160     * @access private 
    30893161     */ 
     
    31113183 
    31123184    /** 
     3185     * Writes single cache record 
     3186     * 
     3187     * @param string $key  Cache key 
     3188     * @param mxied  $data Cache value 
    31133189     * @access private 
    31143190     */ 
     
    31543230 
    31553231    /** 
     3232     * Clears cache for single record 
     3233     * 
     3234     * @param string $ket Cache key 
    31563235     * @access private 
    31573236     */ 
     
    31773256     * Checks if the cache is up-to-date 
    31783257     * 
    3179      * @param string Mailbox name 
    3180      * @param string Internal cache key 
     3258     * @param string $mailbox   Mailbox name 
     3259     * @param string $cache_key Internal cache key 
    31813260     * @return int   Cache status: -3 = off, -2 = incomplete, -1 = dirty, 1 = OK 
    31823261     */ 
     
    32333312 
    32343313    /** 
     3314     * @param string $key Cache key 
     3315     * @param string $from 
     3316     * @param string $to 
     3317     * @param string $sort_field 
     3318     * @param string $sort_order 
    32353319     * @access private 
    32363320     */ 
     
    32723356 
    32733357    /** 
     3358     * @param string $key Cache key 
     3359     * @param int    $uid User id 
     3360     * @return mixed 
    32743361     * @access private 
    32753362     */ 
     
    33033390 
    33043391    /** 
     3392     * @param string  $key   Cache key 
     3393     * @param boolean $force Force flag 
     3394     * @param string  $sort_field 
     3395     * @param string  $sort_order 
    33053396     * @access private 
    33063397     */ 
     
    34403531 
    34413532    /** 
     3533     * @param string $key         Cache key 
     3534     * @param int    $start_index Start index 
    34423535     * @access private 
    34433536     */ 
     
    34953588     * Split an address list into a structured array list 
    34963589     * 
    3497      * @param string  Input string 
    3498      * @param int     List only this number of addresses 
    3499      * @param boolean Decode address strings 
     3590     * @param string  $input  Input string 
     3591     * @param int     $max    List only this number of addresses 
     3592     * @param boolean $decode Decode address strings 
    35003593     * @return array  Indexed list of addresses 
    35013594     */ 
     
    35453638     * Decode a message header value 
    35463639     * 
    3547      * @param string  Header value 
    3548      * @param boolean Remove quotes if necessary 
     3640     * @param string  $input         Header value 
     3641     * @param boolean $remove_quotas Remove quotes if necessary 
    35493642     * @return string Decoded string 
    35503643     */ 
     
    36183711     * Decode a part of a mime-encoded string 
    36193712     * 
     3713     * @param string $str String to decode 
     3714     * @return string Decoded string 
    36203715     * @access private 
    36213716     */ 
     
    36483743     * Decode a mime part 
    36493744     * 
    3650      * @param string Input string 
    3651      * @param string Part encoding 
     3745     * @param string $input    Input string 
     3746     * @param string $encoding Part encoding 
    36523747     * @return string Decoded string 
    36533748     */ 
     
    36743769     * Convert body charset to RCMAIL_CHARSET according to the ctype_parameters 
    36753770     * 
    3676      * @param string Part body to decode 
    3677      * @param string Charset to convert from 
     3771     * @param string $body        Part body to decode 
     3772     * @param string $ctype_param Charset to convert from 
    36783773     * @return string Content converted to internal charset 
    36793774     */ 
     
    36943789    /** 
    36953790     * Validate the given input and save to local properties 
     3791     * 
     3792     * @param string $sort_field Sort column 
     3793     * @param string $sort_order Sort order 
    36963794     * @access private 
    36973795     */ 
     
    37063804    /** 
    37073805     * Sort mailboxes first by default folders and then in alphabethical order 
     3806     * 
     3807     * @param array $a_folders Mailboxes list 
    37083808     * @access private 
    37093809     */ 
     
    37633863 
    37643864    /** 
     3865     * @param int    $uid       User id 
     3866     * @param string $mbox_name Mailbox name 
     3867     * @return int  
    37653868     * @access private 
    37663869     */ 
     
    37773880 
    37783881    /** 
     3882     * @param int    $id        Id 
     3883     * @param string $mbox_name Mailbox name 
     3884     * @return int 
    37793885     * @access private 
    37803886     */ 
     
    39814087     * Set the predetermined sort order. 
    39824088     * 
    3983      * @param array Numerically indexed array of IMAP message sequence numbers 
     4089     * @param array $seqnums Numerically indexed array of IMAP message sequence numbers 
    39844090     */ 
    39854091    function set_sequence_numbers($seqnums) 
     
    39914097     * Sort the array of header objects 
    39924098     * 
    3993      * @param array Array of rcube_mail_header objects indexed by UID 
     4099     * @param array $headers Array of rcube_mail_header objects indexed by UID 
    39944100     */ 
    39954101    function sort_headers(&$headers) 
     
    40074113    /** 
    40084114     * Sort method called by uasort() 
     4115     * 
     4116     * @param rcube_mail_header $a 
     4117     * @param rcube_mail_header $b 
    40094118     */ 
    40104119    function compare_seqnums($a, $b) 
  • program/include/rcube_json_output.php

    re019f2d r5c461ba  
    2929class rcube_json_output 
    3030{ 
     31    /** 
     32     * Stores configuration object. 
     33     * 
     34     * @var rcube_config 
     35     */ 
    3136    private $config; 
    3237    private $charset = RCMAIL_CHARSET; 
     
    5560     * Set environment variable 
    5661     * 
    57      * @param string Property name 
    58      * @param mixed Property value 
     62     * @param string $name Property name 
     63     * @param mixed $value Property value 
    5964     */ 
    6065    public function set_env($name, $value) 
     
    6772     * Issue command to set page title 
    6873     * 
    69      * @param string New page title 
     74     * @param string $title New page title 
    7075     */ 
    7176    public function set_pagetitle($title) 
     
    99104     * Register a template object handler 
    100105     * 
    101      * @param  string Object name 
    102      * @param  string Function name to call 
     106     * @param  string $obj Object name 
     107     * @param  string $func Function name to call 
    103108     * @return void 
    104109     */ 
     
    112117     * Register a list of template object handlers 
    113118     * 
    114      * @param  array Hash array with object=>handler pairs 
     119     * @param  array $arr Hash array with object=>handler pairs 
    115120     * @return void 
    116121     */ 
     
    156161     * Invoke display_message command 
    157162     * 
    158      * @param string Message to display 
    159      * @param string Message type [notice|confirm|error] 
    160      * @param array Key-value pairs to be replaced in localized text 
    161      * @param boolean Override last set message 
     163     * @param string  $message  Message to display 
     164     * @param string  $type     Message type [notice|confirm|error] 
     165     * @param array   $vars     Key-value pairs to be replaced in localized text 
     166     * @param boolean $override Override last set message 
    162167     * @uses self::command() 
    163168     */ 
     
    189194     * Redirect to a certain url 
    190195     * 
    191      * @param mixed Either a string with the action or url parameters as key-value pairs 
     196     * @param mixed $p Either a string with the action or url parameters as key-value pairs 
     197     * @param int $delay Delay in seconds 
    192198     * @see rcmail::url() 
    193199     */ 
     
    213219     * Send an AJAX response with executable JS code 
    214220     * 
    215      * @param  string  Additional JS code 
     221     * @param  string  $add Additional JS code 
    216222     * @param  boolean True if output buffer should be flushed 
    217223     * @return void 
  • program/include/rcube_mdb2.php

    r8603bbb r5c461ba  
    5353     * Object constructor 
    5454     * 
    55      * @param  string DSN for read/write operations 
    56      * @param  string Optional DSN for read only operations 
     55     * @param  string $db_dsnw DSN for read/write operations 
     56     * @param  string $db_dsnr Optional DSN for read only operations 
    5757     */ 
    5858    function __construct($db_dsnw, $db_dsnr='', $pconn=false) 
     
    7373     * Connect to specific database 
    7474     * 
    75      * @param  string DSN for DB connections 
    76      * @return object PEAR database handle 
     75     * @param  string $dsn DSN for DB connections 
     76     * @return MDB2 PEAR database handle 
    7777     * @access private 
    7878     */ 
     
    117117     * Connect to appropiate database depending on the operation 
    118118     * 
    119      * @param  string Connection mode (r|w) 
     119     * @param  string $mode Connection mode (r|w) 
    120120     * @access public 
    121121     */ 
     
    150150     * Activate/deactivate debug mode 
    151151     * 
    152      * @param boolean True if SQL queries should be logged 
     152     * @param boolean $dbg True if SQL queries should be logged 
    153153     * @access public 
    154154     */ 
     
    228228     * Execute a SQL query with limits 
    229229     * 
    230      * @param  string SQL query to execute 
    231      * @param  number Offset for LIMIT statement 
    232      * @param  number Number of rows for LIMIT statement 
    233      * @param  array  Values to be inserted in query 
     230     * @param  string $query  SQL query to execute 
     231     * @param  number $offset Offset for LIMIT statement 
     232     * @param  number $numrows Number of rows for LIMIT statement 
     233     * @param  array  $params Values to be inserted in query 
    234234     * @return number  Query handle identifier 
    235235     * @access private 
     
    280280     * If no query handle is specified, the last query will be taken as reference 
    281281     * 
    282      * @param  number Optional query handle identifier 
     282     * @param  number $res_id Optional query handle identifier 
    283283     * @return mixed   Number of rows or false on failure 
    284284     * @access public 
     
    299299     * Get number of affected rows for the last query 
    300300     * 
    301      * @param  number Optional query handle identifier 
     301     * @param  number $res_id Optional query handle identifier 
    302302     * @return mixed   Number of rows or false on failure 
    303303     * @access public 
     
    316316     * For Postgres databases, a sequence name is required 
    317317     * 
    318      * @param  string Table name (to find the incremented sequence) 
     318     * @param  string $table Table name (to find the incremented sequence) 
    319319     * @return mixed   ID or false on failure 
    320320     * @access public 
     
    344344     * If no query handle is specified, the last query will be taken as reference 
    345345     * 
    346      * @param  number Optional query handle identifier 
     346     * @param  number $res_id Optional query handle identifier 
    347347     * @return mixed   Array with col values or false on failure 
    348348     * @access public 
     
    359359     * If no query handle is specified, the last query will be taken as reference 
    360360     * 
    361      * @param  number Optional query handle identifier 
     361     * @param  number $res_id Optional query handle identifier 
    362362     * @return mixed   Array with col values or false on failure 
    363363     * @access public 
     
    373373     * Get col values for a result row 
    374374     * 
    375      * @param  object  Query result handle 
    376      * @param  number  Fetch mode identifier 
     375     * @param  MDB2_Result_Common Query $result result handle 
     376     * @param  number                   $mode   Fetch mode identifier 
    377377     * @return mixed   Array with col values or false on failure 
    378378     * @access private 
     
    412412     * Formats input so it can be safely used in a query 
    413413     * 
    414      * @param  mixed  Value to quote 
    415      * @param  string Type of data 
     414     * @param  mixed  $input Value to quote 
     415     * @param  string $type  Type of data 
    416416     * @return string  Quoted/converted string for use in query 
    417417     * @access public 
     
    434434     * Quotes a string so it can be safely used as a table or column name 
    435435     * 
    436      * @param  string Value to quote 
     436     * @param  string $str Value to quote 
    437437     * @return string  Quoted string for use in query 
    438438     * @deprecated     Replaced by rcube_MDB2::quote_identifier 
     
    449449     * Quotes a string so it can be safely used as a table or column name 
    450450     * 
    451      * @param  string Value to quote 
     451     * @param  string $str Value to quote 
    452452     * @return string  Quoted string for use in query 
    453453     * @access public 
     
    465465     * Escapes a string 
    466466     * 
    467      * @param  string The string to be escaped 
     467     * @param  string $str The string to be escaped 
    468468     * @return string  The escaped string 
    469469     * @access public 
     
    501501     * Return list of elements for use with SQL's IN clause 
    502502     * 
    503      * @param  array  Input array 
    504      * @param  string Type of data 
     503     * @param  array  $arr  Input array 
     504     * @param  string $type Type of data 
    505505     * @return string Comma-separated list of quoted values for use in query 
    506506     * @access public 
     
    521521     * Return SQL statement to convert a field value into a unix timestamp 
    522522     * 
    523      * @param  string Field name 
     523     * @param  string $field Field name 
    524524     * @return string  SQL statement to use in query 
    525525     * @access public 
     
    544544     * Return SQL statement to convert from a unix timestamp 
    545545     * 
    546      * @param  string Field name 
     546     * @param  string $timestamp Field name 
    547547     * @return string  SQL statement to use in query 
    548548     * @access public 
     
    565565     * Return SQL statement for case insensitive LIKE 
    566566     * 
    567      * @param  string Field name 
    568      * @param  string Search value 
     567     * @param  string $column Field name 
     568     * @param  string $value  Search value 
    569569     * @return string  SQL statement to use in query 
    570570     * @access public 
     
    585585     * Encodes non-UTF-8 characters in string/array/object (recursive) 
    586586     * 
    587      * @param  mixed  Data to fix 
     587     * @param  mixed  $input Data to fix 
    588588     * @return mixed  Properly UTF-8 encoded data 
    589589     * @access public 
     
    609609     * Decodes encoded UTF-8 string/object/array (recursive) 
    610610     * 
    611      * @param  mixed Input data 
     611     * @param  mixed $input Input data 
    612612     * @return mixed  Decoded data 
    613613     * @access public 
     
    633633     * Adds a query result and returns a handle ID 
    634634     * 
    635      * @param  object Query handle 
     635     * @param  object $res Query handle 
    636636     * @return mixed   Handle ID 
    637637     * @access private 
     
    661661     * If no ID is specified, the last resource handle will be returned 
    662662     * 
    663      * @param  number Handle ID 
     663     * @param  number $res_id Handle ID 
    664664     * @return mixed   Resource handle or false on failure 
    665665     * @access private 
     
    681681     * Create a sqlite database from a file 
    682682     * 
    683      * @param  object  SQLite database handle 
    684      * @param  string File path to use for DB creation 
     683     * @param  MDB2   $dbh       SQLite database handle 
     684     * @param  string $file_name File path to use for DB creation 
    685685     * @access private 
    686686     */ 
  • program/include/rcube_message.php

    r6d1ae07 r5c461ba  
    3030class rcube_message 
    3131{ 
     32    /** 
     33     * Instace of rcmail. 
     34     * 
     35     * @var rcmail 
     36     */ 
    3237    private $app; 
     38 
     39    /** 
     40     * Instance of imap class 
     41     * 
     42     * @var rcube_imap 
     43     */ 
    3344    private $imap; 
    3445    private $opt = array(); 
     
    99110     * Return a (decoded) message header 
    100111     * 
    101      * @param string Header name 
    102      * @param bool   Don't mime-decode the value 
     112     * @param string $name Header name 
     113     * @param bool   $row  Don't mime-decode the value 
    103114     * @return string Header value 
    104115     */ 
     
    113124     * Set is_safe var and session data 
    114125     * 
    115      * @param bool enable/disable 
     126     * @param bool $safe enable/disable 
    116127     */ 
    117128    public function set_safe($safe = true) 
     
    125136     * Compose a valid URL for getting a message part 
    126137     * 
    127      * @param string Part MIME-ID 
     138     * @param string $mime_id Part MIME-ID 
    128139     * @return string URL or false if part does not exist 
    129140     */ 
     
    140151     * Get content of a specific part of this message 
    141152     * 
    142      * @param string Part MIME-ID 
    143      * @param resource File pointer to save the message part 
     153     * @param string $mime_id Part MIME-ID 
     154     * @param resource $fp File pointer to save the message part 
    144155     * @return string Part content 
    145156     */ 
     
    242253     * and build flat lists of content parts and attachments 
    243254     * 
    244      * @param object rcube_message_part Message structure node 
    245      * @param bool  True when called recursively 
     255     * @param rcube_message_part $structure Message structure node 
     256     * @param bool               $recursive True when called recursively 
    246257     */ 
    247258    private function parse_structure($structure, $recursive = false) 
     
    502513     * Fill aflat array with references to all parts, indexed by part numbers 
    503514     * 
    504      * @param object rcube_message_part Message body structure 
     515     * @param rcube_message_part $part Message body structure 
    505516     */ 
    506517    private function get_mime_numbers(&$part) 
     
    518529     * Decode a Microsoft Outlook TNEF part (winmail.dat) 
    519530     * 
    520      * @param object rcube_message_part Message part to decode 
     531     * @param rcube_message_part $part Message part to decode 
     532     * @return array 
    521533     */ 
    522534    function tnef_decode(&$part) 
     
    553565     * Parse message body for UUencoded attachments bodies 
    554566     * 
    555      * @param object rcube_message_part Message part to decode 
     567     * @param rcube_message_part $part Message part to decode 
     568     * @return array 
    556569     */ 
    557570    function uu_decode(&$part) 
     
    599612     * Interpret a format=flowed message body according to RFC 2646 
    600613     * 
    601      * @param string  Raw body formatted as flowed text 
     614     * @param string  $text Raw body formatted as flowed text 
    602615     * @return string Interpreted text with unwrapped lines and stuffed space removed 
    603616     */ 
     
    655668    /** 
    656669     * Wrap the given text to comply with RFC 2646 
     670     * 
     671     * @param string $text Text to wrap 
     672     * @param int $length Length 
     673     * @return string Wrapped text 
    657674     */ 
    658675    public static function format_flowed($text, $length = 72) 
  • program/include/rcube_plugin.php

    re019f2d r5c461ba  
    2828{ 
    2929  public $ID; 
     30 
     31  /** 
     32   * Holds an istance of Plugin API 
     33   * 
     34   * @var rcube_plugin_api 
     35   */ 
    3036  public $api; 
    3137  public $task; 
     
    3642  /** 
    3743   * Default constructor. 
     44   * 
     45   * @param rcube_plugin_api $api Plugin API 
    3846   */ 
    3947  public function __construct($api) 
     
    5462   * The loaded values are patched over the global configuration. 
    5563   * 
    56    * @param string Config file name relative to the plugin's folder 
     64   * @param string $fname Config file name relative to the plugin's folder 
    5765   * @return boolean True on success, false on failure 
    5866   */ 
     
    7482   * Register a callback function for a specific (server-side) hook 
    7583   * 
    76    * @param string Hook name 
    77    * @param mixed Callback function as string or array with object reference and method name 
     84   * @param string $hook Hook name 
     85   * @param mixed  $callback Callback function as string or array with object reference and method name 
    7886   */ 
    7987  public function add_hook($hook, $callback) 
     
    8593   * Load localized texts from the plugins dir 
    8694   * 
    87    * @param string Directory to search in 
    88    * @param mixed Make texts also available on the client (array with list or true for all) 
     95   * @param string $dir Directory to search in 
     96   * @param mixed  $add2client Make texts also available on the client (array with list or true for all) 
    8997   */ 
    9098  public function add_texts($dir, $add2client = false) 
     
    121129   * Wrapper for rcmail::gettext() adding the plugin ID as domain 
    122130   * 
     131   * @param string $p Message identifier 
    123132   * @return string Localized text 
    124133   * @see rcmail::gettext() 
     
    132141   * Register this plugin to be responsible for a specific task 
    133142   * 
    134    * @param string Task name (only characters [a-z0-9_.-] are allowed) 
     143   * @param string $task Task name (only characters [a-z0-9_.-] are allowed) 
    135144   */ 
    136145  public function register_task($task) 
     
    145154    * The callback will be executed upon a request like /?_task=mail&_action=plugin.myaction 
    146155    * 
    147     * @param string Action name (should be unique) 
    148     * @param mixed Callback function as string or array with object reference and method name 
     156    * @param string $action  Action name (should be unique) 
     157    * @param mixed $callback Callback function as string or array with object reference and method name 
    149158   */ 
    150159  public function register_action($action, $callback) 
     
    159168   * will be replaced by the return value if the registered callback function. 
    160169   * 
    161    * @param string Object name (should be unique and start with 'plugin.') 
    162    * @param mixed Callback function as string or array with object reference and method name 
     170   * @param string $name Object name (should be unique and start with 'plugin.') 
     171   * @param mixed  $callback Callback function as string or array with object reference and method name 
    163172   */ 
    164173  public function register_handler($name, $callback) 
     
    170179   * Make this javascipt file available on the client 
    171180   * 
    172    * @param string File path; absolute or relative to the plugin directory 
     181   * @param string $fn File path; absolute or relative to the plugin directory 
    173182   */ 
    174183  public function include_script($fn) 
     
    180189   * Make this stylesheet available on the client 
    181190   * 
    182    * @param string File path; absolute or relative to the plugin directory 
     191   * @param string $fn File path; absolute or relative to the plugin directory 
    183192   */ 
    184193  public function include_stylesheet($fn) 
     
    190199   * Append a button to a certain container 
    191200   * 
    192    * @param array Hash array with named parameters (as used in skin templates) 
    193    * @param string Container name where the buttons should be added to 
     201   * @param array $p Hash array with named parameters (as used in skin templates) 
     202   * @param string $container Container name where the buttons should be added to 
    194203   * @see rcube_remplate::button() 
    195204   */ 
     
    210219   * plugin directory 
    211220   * 
    212    * @param string The file name 
     221   * @param string $fn The file name 
    213222   * @return string Absolute URL to the given resource 
    214223   */ 
     
    220229  /** 
    221230   * Make the given file name link into the plugin directory 
     231   * 
     232   * @param string $fn Filename 
    222233   */ 
    223234  private function resource_url($fn) 
     
    245256  /** 
    246257   * Callback function for array_map 
     258   * 
     259   * @param string $key Array key. 
     260   * @return string 
    247261   */ 
    248262  private function label_map_callback($key) 
  • program/include/rcube_plugin_api.php

    re019f2d r5c461ba  
    7777   * This implements the 'singleton' design pattern 
    7878   * 
    79    * @return object rcube_plugin_api The one and only instance if this class 
     79   * @return rcube_plugin_api The one and only instance if this class 
    8080   */ 
    8181  static function get_instance() 
     
    190190   * Allows a plugin object to register a callback for a certain hook 
    191191   * 
    192    * @param string Hook name 
    193    * @param mixed String with global function name or array($obj, 'methodname') 
     192   * @param string $hook Hook name 
     193   * @param mixed  $callback String with global function name or array($obj, 'methodname') 
    194194   */ 
    195195  public function register_hook($hook, $callback) 
     
    215215   * This is called from the application and executes all registered handlers 
    216216   * 
    217    * @param string Hook name 
    218    * @param array Named arguments (key->value pairs) 
     217   * @param string $hook Hook name 
     218   * @param array $args Named arguments (key->value pairs) 
    219219   * @return array The (probably) altered hook arguments 
    220220   */ 
     
    244244   * Let a plugin register a handler for a specific request 
    245245   * 
    246    * @param string Action name (_task=mail&_action=plugin.foo) 
    247    * @param string Plugin name that registers this action 
    248    * @param mixed Callback: string with global function name or array($obj, 'methodname') 
    249    * @param string Task name registered by this plugin 
     246   * @param string $action Action name (_task=mail&_action=plugin.foo) 
     247   * @param string $owner Plugin name that registers this action 
     248   * @param mixed  $callback Callback: string with global function name or array($obj, 'methodname') 
     249   * @param string $task Task name registered by this plugin 
    250250   */ 
    251251  public function register_action($action, $owner, $callback, $task = null) 
     
    274274   * It executes the callback function that was registered with the given action. 
    275275   * 
    276    * @param string Action name 
     276   * @param string $action Action name 
    277277   */ 
    278278  public function exec_action($action) 
     
    292292   * Register a handler function for template objects 
    293293   * 
    294    * @param string Object name 
    295    * @param string Plugin name that registers this action 
    296    * @param mixed Callback: string with global function name or array($obj, 'methodname') 
     294   * @param string $name Object name 
     295   * @param string $owner Plugin name that registers this action 
     296   * @param mixed  $callback Callback: string with global function name or array($obj, 'methodname') 
    297297   */ 
    298298  public function register_handler($name, $owner, $callback) 
     
    318318   * Register this plugin to be responsible for a specific task 
    319319   * 
    320    * @param string Task name (only characters [a-z0-9_.-] are allowed) 
    321    * @param string Plugin name that registers this action 
     320   * @param string $task Task name (only characters [a-z0-9_.-] are allowed) 
     321   * @param string $owner Plugin name that registers this action 
    322322   */ 
    323323  public function register_task($task, $owner) 
     
    346346   * Checks whether the given task is registered by a plugin 
    347347   * 
     348   * @param string $task Task name 
    348349   * @return boolean True if registered, otherwise false 
    349350   */ 
     
    358359   * Mainly used to prevent loops and recursion. 
    359360   * 
    360    * @param string Hook to check (optional) 
     361   * @param string $hook Hook to check (optional) 
    361362   * @return boolean True if any/the given hook is currently processed, otherwise false 
    362363   */ 
     
    368369  /** 
    369370   * Include a plugin script file in the current HTML page 
     371   * 
     372   * @param string $fn Path to script 
    370373   */ 
    371374  public function include_script($fn) 
     
    379382  /** 
    380383   * Include a plugin stylesheet in the current HTML page 
     384   * 
     385   * @param string $fn Path to stylesheet 
    381386   */ 
    382387  public function include_stylesheet($fn) 
     
    390395  /** 
    391396   * Save the given HTML content to be added to a template container 
     397   * 
     398   * @param string $html HTML content 
     399   * @param string $container Template container identifier 
    392400   */ 
    393401  public function add_content($html, $container) 
     
    398406  /** 
    399407   * Callback for template_container hooks 
     408   * 
     409   * @param array $attrib 
     410   * @return array 
    400411   */ 
    401412  private function template_container_hook($attrib) 
     
    407418  /** 
    408419   * Make the given file name link into the plugins directory 
     420   * 
     421   * @param string $fn Filename 
     422   * @return string  
    409423   */ 
    410424  private function resource_url($fn) 
  • program/include/rcube_user.php

    re999919 r5c461ba  
    3434    public $language = null; 
    3535 
     36    /** 
     37     * Holds database connection. 
     38     * 
     39     * @var rcube_mdb2 
     40     */ 
    3641    private $db = null; 
    3742 
     
    4045     * Object constructor 
    4146     * 
    42      * @param object DB Database connection 
     47     * @param int   $id      User id 
     48     * @param array $sql_arr SQL result set 
    4349     */ 
    4450    function __construct($id = null, $sql_arr = null) 
     
    6369     * Build a user name string (as e-mail address) 
    6470     * 
    65      * @param string Username part (empty or 'local' or 'domain') 
     71     * @param  string $part Username part (empty or 'local' or 'domain') 
    6672     * @return string Full user name or its part 
    6773     */ 
     
    115121     * Write the given user prefs to the user's record 
    116122     * 
    117      * @param array User prefs to save 
     123     * @param array $a_user_prefs User prefs to save 
    118124     * @return boolean True on success, False on failure 
    119125     */ 
     
    162168     * Get default identity of this user 
    163169     * 
    164      * @param int Identity ID. If empty, the default identity is returned 
     170     * @param  int   $id Identity ID. If empty, the default identity is returned 
    165171     * @return array Hash array with all cols of the identity record 
    166172     */ 
     
    175181     * Return a list of all identities linked with this user 
    176182     * 
     183     * @param string $sql_add Optional WHERE clauses 
    177184     * @return array List of identities 
    178185     */ 
     
    199206     * Update a specific identity record 
    200207     * 
    201      * @param int    Identity ID 
    202      * @param array  Hash array with col->value pairs to save 
     208     * @param int    $iid  Identity ID 
     209     * @param array  $data Hash array with col->value pairs to save 
    203210     * @return boolean True if saved successfully, false if nothing changed 
    204211     */ 
     
    233240     * Create a new identity record linked with this user 
    234241     * 
    235      * @param array Hash array with col->value pairs to save 
     242     * @param array $data Hash array with col->value pairs to save 
    236243     * @return int  The inserted identity ID or false on error 
    237244     */ 
     
    265272     * Mark the given identity as deleted 
    266273     * 
    267      * @param int Identity ID 
     274     * @param  int     $iid Identity ID 
    268275     * @return boolean True if deleted successfully, false if nothing changed 
    269276     */ 
     
    299306     * Make this identity the default one for this user 
    300307     * 
    301      * @param int The identity ID 
     308     * @param int $iid The identity ID 
    302309     */ 
    303310    function set_default($iid) 
     
    344351     * Find a user record matching the given name and host 
    345352     * 
    346      * @param string IMAP user name 
    347      * @param string IMAP host name 
    348      * @return object rcube_user New user instance 
     353     * @param string $user IMAP user name 
     354     * @param string $host IMAP host name 
     355     * @return rcube_user New user instance 
    349356     */ 
    350357    static function query($user, $host) 
     
    373380     * Create a new user record and return a rcube_user instance 
    374381     * 
    375      * @param string IMAP user name 
    376      * @param string IMAP host 
    377      * @return object rcube_user New user instance 
     382     * @param string $user IMAP user name 
     383     * @param string $host IMAP host 
     384     * @return rcube_user New user instance 
    378385     */ 
    379386    static function create($user, $host) 
     
    472479     * Resolve username using a virtuser plugins 
    473480     * 
    474      * @param string E-mail address to resolve 
     481     * @param string $email E-mail address to resolve 
    475482     * @return string Resolved IMAP username 
    476483     */ 
     
    488495     * Resolve e-mail address from virtuser plugins 
    489496     * 
    490      * @param string User name 
    491      * @param boolean If true returns first found entry 
    492      * @param boolean If true returns email as array (email and name for identity) 
     497     * @param string $user User name 
     498     * @param boolean $first If true returns first found entry 
     499     * @param boolean $extended If true returns email as array (email and name for identity) 
    493500     * @return mixed Resolved e-mail address string or array of strings 
    494501     */ 
Note: See TracChangeset for help on using the changeset viewer.