Property | Type | Description | |
---|---|---|---|
$_mbox | string | The IMAP mailbox name (UTF-8). |
Method | Description | |
---|---|---|
__construct ( $mbox ) | Constructor. | |
__get ( $key ) | ||
__set ( $key, $value ) | ||
__toString ( ) | ||
create ( array $opts = [] ) : boolean | Create this mailbox on the server. | |
createMailboxName ( string $new ) : IMP_Mailbox | Return the mailbox name to create given a submailbox name. | |
delete ( array $opts = [] ) : boolean | Deletes mailbox. | |
emptyMailbox ( ) | Empties the entire mailbox. | |
equals ( mixed $mbox ) : boolean | Determines if this mailbox is equal to the given mailbox. | |
expunge ( array $to_expunge = [], array $opts = [] ) : IMP_Indices | Expunges all deleted messages. | |
filter ( ) | Runs filters on this mailbox. | |
filterOnDisplay ( ) : boolean | Filters this mailbox if it is the INBOX and the filter on display pref is active. | |
flagAll ( array $flags, boolean $action = true ) : boolean | Adds or removes flag(s) for all messages in the mailbox. | |
formFrom ( mixed $mbox ) : mixed | Converts a mailbox string from a form representation. | |
formTo ( mixed $mbox ) : mixed | Converts a mailbox string to a form representation. | |
fromBuids ( IMP_Indices | array $buids ) : IMP_Indices | Create an indices object from a list of browser-UIDs. | |
get ( mixed $mbox ) : mixed | Shortcut to obtaining mailbox object(s). | |
getImapMboxOb ( mixed $mbox ) : mixed | Shortcut to obtaining Horde_Imap_Client_Mailbox object(s). | |
getIndicesOb ( mixed $in ) : IMP_Indices | Return an indices object for this mailbox. | |
getPref ( $pref ) : IMP_Mailbox | Shortcut to obtaining a mailbox object from a preference name. | |
getSearchOb ( ) : IMP_Search_Query | Return the search query object for this mailbox. | |
getSort ( boolean $convert = false ) : IMP_Prefs_Sort_Sortpref | Return the sorting preference for this mailbox. | |
getSpecialMailboxes ( ) : array | Return the list of special mailboxes. | |
getSpecialMailboxesSort ( ) : array | Return the list of sorted special mailboxes. | |
hideDeletedMsgs ( boolean $deleted = false ) : boolean | Are deleted messages hidden in this mailbox? | |
prefFrom ( string $mbox ) : string | Converts a mailbox name from a value stored in the preferences. | |
prefTo ( string $mbox ) : string | Converts a mailbox name to a value to be stored in a preference. | |
rename ( string $new_name ) : boolean | Rename this mailbox on the server. The subscription status remains the same. All subfolders will also be renamed. | |
runSearchQuery ( Horde_Imap_Client_Search_Query $query, integer $sortby = null, integer $sortdir = null ) : IMP_Indices | Run a search query on this mailbox that is not stored in the current session. Allows custom queries with custom sorts to be used without affecting cached mailboxes. | |
setHideDeletedMsgs ( boolean $value ) | Sets the 'delhide' preference and clears necessary cached data. | |
setSort ( integer $by = null, integer $dir = null, boolean $delete = false ) | Set the sorting preference for this mailbox. | |
subscribe ( boolean $sub, array $opts = [] ) : boolean | Subscribe/unsubscribe to an IMAP mailbox. | |
toBuids ( IMP_Indices $uids ) : IMP_Indices | Create a BUID indices object from a list of UIDs. | |
url ( string | Horde_Url $page, string $buid = null, boolean $encode = true ) : Horde_Url | Generate a URL using the current mailbox. | |
urlParams ( string $buid = null ) : array | Returns list of URL parameters necessary to indicate current mailbox status. |
Method | Description | |
---|---|---|
_getCacheID ( boolean $date = false ) : string | Returns a unique identifier for this mailbox's status. | |
_getDisplay ( boolean $notranslate = false ) : string | If there is information available to tell us about a prefix in front of mailbox names that shouldn't be displayed to the user, then use it to strip that prefix out. Additionally, translate prefix text if this is a special mailbox. | |
_getIcon ( ) : object | Return icon information. | |
_onDelete ( array $deleted ) | Do the necessary cleanup/cache updates when deleting mailboxes. |
protected _getCacheID ( boolean $date = false ) : string | ||
$date | boolean | If true, adds date information to ID. |
return | string | The cache ID string, which will change when the composition of this mailbox changes. |
protected _getDisplay ( boolean $notranslate = false ) : string | ||
$notranslate | boolean | Don't translate the mailbox prefix? |
return | string | The mailbox, with any prefix gone/translated. |
public createMailboxName ( string $new ) : IMP_Mailbox | ||
$new | string | The submailbox name (UTF-8). |
return | IMP_Mailbox | The mailbox to create. |
public expunge ( array $to_expunge = [], array $opts = [] ) : IMP_Indices | ||
$to_expunge | array | An optional array of indices to delete. If empty, all messages flagged as deleted in the mailbox will be deleted. |
$opts | array | Additional options:
- list: (boolean) Return a list of messages expunged. DEFAULT: false |
return | IMP_Indices | If 'list' option is true, an indices object containing the messages that have been expunged. |
public filterOnDisplay ( ) : boolean | ||
return | boolean | True if filter() was called. |
public static getImapMboxOb ( mixed $mbox ) : mixed | ||
$mbox | mixed | The full IMAP mailbox name(s). |
return | mixed | The Horde_Imap_Client_Mailbox object(s). |
public getIndicesOb ( mixed $in ) : IMP_Indices | ||
$in | mixed | Either a single UID, array of UIDs, or a Horde_Imap_Client_Ids object. |
return | IMP_Indices | An indices object. |
public static getPref ( $pref ) : IMP_Mailbox | ||
return | IMP_Mailbox | The IMP_Mailbox object. |
public getSearchOb ( ) : IMP_Search_Query | ||
return | IMP_Search_Query | The search query object. |
public static getSpecialMailboxes ( ) : array | ||
return | array | A list of mailboxes, with the self::SPECIAL_* constants as keys and values containing the IMP_Mailbox objects or null if the mailbox doesn't exist (self::SPECIAL_SENT contains an array of objects). |
public static getSpecialMailboxesSort ( ) : array | ||
return | array | The list of sorted special mailboxes (IMP_Mailbox objects). |
public hideDeletedMsgs ( boolean $deleted = false ) : boolean | ||
$deleted | boolean | Return value is what should be done with deleted messages in general, as opposed to any deleted message in the mailbox. |
return | boolean | True if deleted messages should be hidden. |
public runSearchQuery ( Horde_Imap_Client_Search_Query $query, integer $sortby = null, integer $sortdir = null ) : IMP_Indices | ||
$query | Horde_Imap_Client_Search_Query | The search query object. |
$sortby | integer | The sort criteria. |
$sortdir | integer | The sort directory. |
return | IMP_Indices | An indices object. |
public setHideDeletedMsgs ( boolean $value ) | ||
$value | boolean | The value to set 'delhide' to. |
public toBuids ( IMP_Indices $uids ) : IMP_Indices | ||
$uids | IMP_Indices | UIDs. |
return | IMP_Indices | An indices object. |
public url ( string | Horde_Url $page, string $buid = null, boolean $encode = true ) : Horde_Url | ||
$page | string | Horde_Url | Page name to link to. |
$buid | string | The BUID to use on the linked page. |
$encode | boolean | Encode the argument separator? |
return | Horde_Url | URL to $page with any necessary mailbox information added to the parameter list of the URL. |