ILIAS  release_8 Revision v8.24
ILIAS\Notifications\ilNotificationUserIterator Class Reference
+ Inheritance diagram for ILIAS\Notifications\ilNotificationUserIterator:
+ Collaboration diagram for ILIAS\Notifications\ilNotificationUserIterator:

Public Member Functions

 __construct (string $module, array $userids=[])
 
 __destruct ()
 
 current ()
 
 key ()
 
 next ()
 
 rewind ()
 
 valid ()
 

Private Attributes

array $userids
 
ilDBStatement $rset
 
ilDBInterface $db
 
array $data
 
string $module
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

ILIAS\Notifications\ilNotificationUserIterator::__construct ( string  $module,
array  $userids = [] 
)

◆ __destruct()

ILIAS\Notifications\ilNotificationUserIterator::__destruct ( )

Definition at line 50 of file ilNotificationUserIterator.php.

51 {
52 $this->db->free($this->rset);
53 }

Member Function Documentation

◆ current()

ILIAS\Notifications\ilNotificationUserIterator::current ( )

◆ key()

ILIAS\Notifications\ilNotificationUserIterator::key ( )

Definition at line 60 of file ilNotificationUserIterator.php.

60 : int
61 {
62 return (int) $this->data['usr_id'];
63 }

◆ next()

ILIAS\Notifications\ilNotificationUserIterator::next ( )

Definition at line 65 of file ilNotificationUserIterator.php.

65 : void
66 {
67 }

◆ rewind()

ILIAS\Notifications\ilNotificationUserIterator::rewind ( )

Definition at line 69 of file ilNotificationUserIterator.php.

69 : void
70 {
71 $query = 'SELECT usr_id, module, channel FROM ' . ilNotificationSetupHelper::$tbl_userconfig . ' WHERE module=%s AND ' . $this->db->in('usr_id', $this->userids, false, 'integer');
72 $types = array('text');
73 $values = array($this->module);
74 $this->rset = $this->db->queryF($query, $types, $values);
75 }
$query

References $query, and ILIAS\Notifications\ilNotificationSetupHelper\$tbl_userconfig.

Referenced by ILIAS\Notifications\ilNotificationUserIterator\__construct().

+ Here is the caller graph for this function:

◆ valid()

ILIAS\Notifications\ilNotificationUserIterator::valid ( )

Definition at line 77 of file ilNotificationUserIterator.php.

77 : bool
78 {
79 $this->data = $this->db->fetchAssoc($this->rset);
80 return is_array($this->data);
81 }

Field Documentation

◆ $data

array ILIAS\Notifications\ilNotificationUserIterator::$data
private

◆ $db

ilDBInterface ILIAS\Notifications\ilNotificationUserIterator::$db
private

Definition at line 37 of file ilNotificationUserIterator.php.

◆ $module

string ILIAS\Notifications\ilNotificationUserIterator::$module
private

◆ $rset

ilDBStatement ILIAS\Notifications\ilNotificationUserIterator::$rset
private

Definition at line 36 of file ilNotificationUserIterator.php.

◆ $userids

array ILIAS\Notifications\ilNotificationUserIterator::$userids
private

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