Свойство | Type | Description | |
---|---|---|---|
$_charset | string | The charset of the search strings. All text strings must be in this charset. By default, this is 'US-ASCII' (see RFC 3501 [6.4.4]). | |
$_search | array | The list of search params. |
Méthode | Description | |
---|---|---|
__toString ( ) | String representation: The IMAP search string. | |
andSearch ( mixed $queries ) | AND queries - the contents of this query will be AND'ed (in its entirety) with the contents of EACH of the queries passed in. All AND'd queries must share the same charset as this query. | |
build ( Horde_Imap_Client_Base $exts = [] ) : array | Builds an IMAP4rev1 compliant search string. | |
charset ( string $charset, boolean $convert = true ) | Sets the charset of the search text. | |
dateSearch ( mixed $date, string $range, boolean $header = true, boolean $not = false, array $opts = [] ) | Search for messages within a date range. | |
flag ( string $name, boolean $set = true, array $opts = [] ) | Search for a flag/keywords. | |
flagSearch ( ) : boolean | Determines if flags are a part of the search. | |
headerText ( string $header, string $text, boolean $not = false, array $opts = [] ) | Search for text in the header of a message. | |
ids ( Horde_Imap_Client_Ids $ids, boolean $not = false, array $opts = [] ) | Search for messages within a given UID range. Only one message range can be specified per query. | |
intervalSearch ( integer $interval, string $range, boolean $not = false, array $opts = [] ) | Search for messages within a given interval. Only one interval of each type can be specified per search query. If the IMAP server supports the WITHIN extension (RFC 5032), it will be used. Otherwise, the search query will be dynamically created using IMAP4rev1 search terms. | |
modseq ( integer $value, string $name = null, string $type = null, boolean $not = false, array $opts = [] ) | Search for messages modified since a specific moment. The IMAP server must support the CONDSTORE extension (RFC 7162) for this query to be used. | |
newMsgs ( boolean $newmsgs = true, array $opts = [] ) | Search for either new messages (messages that have the '\Recent' flag but not the '\Seen' flag) or old messages (messages that do not have the '\Recent' flag). If new messages are searched, this will clear any '\Recent' or '\Unseen' flag searches. If old messages are searched, this will clear any '\Recent' flag search. | |
orSearch ( mixed $queries ) | OR a query - the contents of this query will be OR'ed (in its entirety) with the contents of EACH of the queries passed in. All OR'd queries must share the same charset as this query. All contents of any single query will be AND'ed together. | |
previousSearch ( boolean $not = false, array $opts = [] ) | Use the results from the previous SEARCH command. The IMAP server must support the SEARCHRES extension (RFC 5182) for this query to be used. | |
serialize ( ) : string | Serialization. | |
size ( integer $size, boolean $larger = false, boolean $not = false, array $opts = [] ) | Search for messages smaller/larger than a certain size. | |
text ( string $text, string $bodyonly = true, boolean $not = false, array $opts = [] ) | Search for text in either the entire message, or just the body. | |
unserialize ( string $data ) | Unserialization. |
Méthode | Description | |
---|---|---|
_addFuzzy ( boolean $add, array &$temp ) | Adds fuzzy modifier to search keys. | |
_buildAndOr ( string $type, array $data, &$charset, &$exts_used, &$cmds ) : boolean | Builds the AND/OR query. |
public build ( Horde_Imap_Client_Base $exts = [] ) : array | ||
$exts | Horde_Imap_Client_Base | The server object this query will be run on (@since 2.24.0), a Horde_Imap_Client_Data_Capability object (@since 2.24.0), or the list of extensions present on the server (@deprecated). If null, all extensions are assumed to be available. |
Résultat | array | An array with these elements: - charset: (string) The charset of the search string. If null, no text strings appear in query. - exts: (array) The list of IMAP extensions used to create the string. - query: (Horde_Imap_Client_Data_Format_List) The IMAP search command. |
public dateSearch ( mixed $date, string $range, boolean $header = true, boolean $not = false, array $opts = [] ) | ||
$date | mixed | DateTime or Horde_Date object. |
$range | string | Either: - Horde_Imap_Client_Search_Query::DATE_BEFORE - Horde_Imap_Client_Search_Query::DATE_ON - Horde_Imap_Client_Search_Query::DATE_SINCE |
$header | boolean | If true, search using the date in the message headers. If false, search using the internal IMAP date (usually arrival time). |
$not | boolean | If true, do a 'NOT' search of the range. |
$opts | array | Additional options: - fuzzy: (boolean) If true, perform a fuzzy search. The IMAP server MUST support RFC 6203. |
public flag ( string $name, boolean $set = true, array $opts = [] ) | ||
$name | string | The flag or keyword name. |
$set | boolean | If true, search for messages that have the flag set. If false, search for messages that do not have the flag set. |
$opts | array | Additional options: - fuzzy: (boolean) If true, perform a fuzzy search. The IMAP server MUST support RFC 6203. |
public flagSearch ( ) : boolean | ||
Résultat | boolean | True if search query involves flags. |
public headerText ( string $header, string $text, boolean $not = false, array $opts = [] ) | ||
$header | string | The header field. |
$text | string | The search text. |
$not | boolean | If true, do a 'NOT' search of $text. |
$opts | array | Additional options: - fuzzy: (boolean) If true, perform a fuzzy search. The IMAP server MUST support RFC 6203. |
public ids ( Horde_Imap_Client_Ids $ids, boolean $not = false, array $opts = [] ) | ||
$ids | Horde_Imap_Client_Ids | The list of UIDs to search. |
$not | boolean | If true, do a 'NOT' search of the UIDs. |
$opts | array | Additional options: - fuzzy: (boolean) If true, perform a fuzzy search. The IMAP server MUST support RFC 6203. |
public intervalSearch ( integer $interval, string $range, boolean $not = false, array $opts = [] ) | ||
$interval | integer | Seconds from the present. |
$range | string | Either: - Horde_Imap_Client_Search_Query::INTERVAL_OLDER - Horde_Imap_Client_Search_Query::INTERVAL_YOUNGER |
$not | boolean | If true, do a 'NOT' search. |
$opts | array | Additional options: - fuzzy: (boolean) If true, perform a fuzzy search. The IMAP server MUST support RFC 6203. |
public modseq ( integer $value, string $name = null, string $type = null, boolean $not = false, array $opts = [] ) | ||
$value | integer | The mod-sequence value. |
$name | string | The entry-name string. |
$type | string | Either 'shared', 'priv', or 'all'. Defaults to 'all' |
$not | boolean | If true, do a 'NOT' search. |
$opts | array | Additional options: - fuzzy: (boolean) If true, perform a fuzzy search. The IMAP server MUST support RFC 6203. |
public previousSearch ( boolean $not = false, array $opts = [] ) | ||
$not | boolean | If true, don't match the previous query. |
$opts | array | Additional options: - fuzzy: (boolean) If true, perform a fuzzy search. The IMAP server MUST support RFC 6203. |
public size ( integer $size, boolean $larger = false, boolean $not = false, array $opts = [] ) | ||
$size | integer | The size (in bytes). |
$larger | boolean | Search for messages larger than $size? |
$not | boolean | If true, do a 'NOT' search of $text. |
$opts | array | Additional options: - fuzzy: (boolean) If true, perform a fuzzy search. The IMAP server MUST support RFC 6203. |
public text ( string $text, string $bodyonly = true, boolean $not = false, array $opts = [] ) | ||
$text | string | The search text. |
$bodyonly | string | If true, only search in the body of the message. If false, also search in the headers. |
$not | boolean | If true, do a 'NOT' search of $text. |
$opts | array | Additional options: - fuzzy: (boolean) If true, perform a fuzzy search. The IMAP server MUST support RFC 6203. |
public unserialize ( string $data ) | ||
$data | string | Serialized data. |
protected string $_charset | ||
Résultat | string |