newMsgs() public method

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.
public newMsgs ( boolean $newmsgs = true, array $opts = [] )
$newmsgs boolean If true, searches for new messages. Else, search for old messages.
$opts array Additional options: - fuzzy: (boolean) If true, perform a fuzzy search. The IMAP server MUST support RFC 6203.
Exemplo n.º 1
0
 /**
  * @dataProvider newMsgsQueryProvider
  */
 public function testNewMsgsQuery($newmsgs, $fuzzy, $expected)
 {
     $ob = new Horde_Imap_Client_Search_Query();
     $ob->newMsgs($newmsgs, array('fuzzy' => $fuzzy));
     $this->assertEquals($expected, $fuzzy ? $this->_fuzzy($ob) : strval($ob));
 }