ILIAS  release_8 Revision v8.24
class.ilMailAutoCompleteSearch.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
25{
28 protected array $providers = [];
29
31 {
32 $this->result = $result;
33 }
34
35 public function addProvider(Iterator $provider): void
36 {
37 $this->providers[] = $provider;
38 }
39
40 public function search(): void
41 {
42 foreach ($this->providers as $provider) {
43 foreach ($provider as $row) {
44 if (!$this->result->isResultAddable()) {
45 $this->result->result['hasMoreResults'] = true;
46 break 2;
47 }
48 $this->result->addResult($row['login'], $row['firstname'], $row['lastname']);
49 }
50 }
51 }
52}
Class ilMailAutoCompleteSearch.
__construct(ilMailAutoCompleteRecipientResult $result)
ilMailAutoCompleteRecipientResult $result
$provider
Definition: ltitoken.php:83