original_string: public function search($search = '', $criteria = SORTDATE, $opt = SE_UID, $dir = 1)
      {
          if ('' === ($search = trim($search))) {
              $search = null;
          }
  
          return imap_sort($this->stream, $criteria, $dir, $opt, $search);
      }
code: public function search($search = '', $criteria = SORTDATE, $opt = SE_UID, $dir = 1)
      {
          if ('' === ($search = trim($search))) {
              $search = null;
          }
  
          return imap_sort($this->stream, $criteria, $dir, $opt, $search);
      }
code_tokens: public function search ( $ search = '' , $ criteria = SORTDATE , $ opt = SE_UID , $ dir = 1 ) { if ( '' === ( $ search = trim ( $ search ) ) ) { $ search = null ; } return imap_sort ( $ this -> stream , $ criteria , $ dir , $ opt , $ search ) ; }
docstring: Search mailbox for emails
  
  @param  string $search Search string as specified in http://php.net/manual/en/function.imap-search.php
  @param  int $criteria Sort flag from http://php.net/manual/en/function.imap-sort.php
  @param  int $opt Options flags from http://php.net/manual/en/function.imap-sort.php
  @param  int $dir Reverse option from http://php.net/manual/en/function.imap-sort.php
  @return array List of matched uids
docstring_tokens: Search mailbox for emails