ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
ilMailAutoCompleteSearch Class Reference

Class ilMailAutoCompleteSearch. More...

+ Collaboration diagram for ilMailAutoCompleteSearch:

Public Member Functions

 __construct (ilMailAutoCompleteRecipientResult $result)
 
 addProvider (Iterator $provider)
 
 search ()
 

Protected Attributes

 $result
 
 $providers = array()
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

ilMailAutoCompleteSearch::__construct ( ilMailAutoCompleteRecipientResult  $result)
Parameters
ilMailAutoCompleteRecipientResult$result

Definition at line 22 of file class.ilMailAutoCompleteSearch.php.

References $result.

23  {
24  $this->result = $result;
25  }

Member Function Documentation

◆ addProvider()

ilMailAutoCompleteSearch::addProvider ( Iterator  $provider)
Parameters
Iterator$provider

Definition at line 30 of file class.ilMailAutoCompleteSearch.php.

References PHPMailer\PHPMailer\$provider.

31  {
32  $this->providers[] = $provider;
33  }

◆ search()

ilMailAutoCompleteSearch::search ( )

Definition at line 38 of file class.ilMailAutoCompleteSearch.php.

References PHPMailer\PHPMailer\$provider, and $row.

39  {
40  foreach ($this->providers as $provider) {
41  foreach ($provider as $row) {
42  if (!$this->result->isResultAddable()) {
43  $this->result->result['hasMoreResults'] = true;
44  break 2;
45  }
46  $this->result->addResult($row['login'], $row['firstname'], $row['lastname']);
47  }
48  }
49  }
$row

Field Documentation

◆ $providers

ilMailAutoCompleteSearch::$providers = array()
protected

Definition at line 17 of file class.ilMailAutoCompleteSearch.php.

◆ $result

ilMailAutoCompleteSearch::$result
protected

Definition at line 12 of file class.ilMailAutoCompleteSearch.php.

Referenced by __construct().


The documentation for this class was generated from the following file: