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

Test provider, adds all users. More...

+ Inheritance diagram for ilAwarenessUserProviderAllUsers:
+ Collaboration diagram for ilAwarenessUserProviderAllUsers:

Public Member Functions

 __construct ()
 Constructor. More...
 
 getProviderId ()
 Get provider id. More...
 
 getTitle ()
 Provider title (used in awareness overlay and in administration settings) More...
 
 getInfo ()
 Provider info (used in administration settings) More...
 
 getInitialUserSet ()
 Get initial set of users. More...
 
- Public Member Functions inherited from ilAwarenessUserProvider
 __construct ()
 Constructor. More...
 
 setActivationMode ($a_val)
 Activate provider. More...
 
 getActivationMode ()
 Get Activate provider. More...
 
 setUserId ($a_val)
 Set user id. More...
 
 getUserId ()
 Get user id. More...
 
 setRefId ($a_val)
 Set ref id. More...
 
 getRefId ()
 Get ref id. More...
 
 setOnlineUserFilter ($a_val)
 Set online user filter. More...
 
 getOnlineUserFilter ()
 Get online user filter. More...
 
 getProviderId ()
 This should return a unique id for the provider The ID should start with the service/module id, separated by "_" and a second part that is unique within the module/service, e.g. More...
 
 getTitle ()
 Provider title (used in awareness overlay and in administration settings) More...
 
 getInfo ()
 Provider info (used in administration settings) More...
 
 getInitialUserSet ()
 Get initial set of users. More...
 
 collectUsers ()
 Collect all users. More...
 
 isHighlighted ()
 Is highlighted. More...
 

Additional Inherited Members

- Data Fields inherited from ilAwarenessUserProvider
const MODE_INACTIVE = 0
 
const MODE_ONLINE_ONLY = 1
 
const MODE_INCL_OFFLINE = 2
 
- Protected Member Functions inherited from ilAwarenessUserProvider
 addUserToCollection ($a_user_id, ilAwarenessUserCollection $a_collection)
 Add user to collection. More...
 
- Protected Attributes inherited from ilAwarenessUserProvider
 $user_id
 
 $ref_id
 
 $lng
 
 $db
 
 $online_user_filter = false
 
 $log
 

Detailed Description

Test provider, adds all users.

Author
Alex Killing alex..nosp@m.kill.nosp@m.ing@g.nosp@m.mx.d.nosp@m.e
Version
$Id$

Definition at line 14 of file class.ilAwarenessUserProviderAllUsers.php.

Constructor & Destructor Documentation

◆ __construct()

ilAwarenessUserProviderAllUsers::__construct ( )

Constructor.

Definition at line 20 of file class.ilAwarenessUserProviderAllUsers.php.

References $DIC.

21  {
22  global $DIC;
23 
24  parent::__construct();
25 
26  $this->db = $DIC->database();
27  }
global $DIC
Definition: saml.php:7

Member Function Documentation

◆ getInfo()

ilAwarenessUserProviderAllUsers::getInfo ( )

Provider info (used in administration settings)

Returns
string provider info text

Definition at line 55 of file class.ilAwarenessUserProviderAllUsers.php.

56  {
57  $this->lng->loadLanguageModule("user");
58  return $this->lng->txt("user_awrn_all_users_info");
59  }

◆ getInitialUserSet()

ilAwarenessUserProviderAllUsers::getInitialUserSet ( )

Get initial set of users.

Returns
array array of user IDs

Definition at line 66 of file class.ilAwarenessUserProviderAllUsers.php.

References ilAwarenessUserProvider\$db, $ilDB, and ilAwarenessUserProvider\getOnlineUserFilter().

67  {
68  $ilDB = $this->db;
69 
70  $ub = array();
71  // all online users
72  if ($this->getOnlineUserFilter() !== false) {
73  foreach ($this->getOnlineUserFilter() as $u) {
74  $ub[] = $u;
75  }
76  } else { // all users
77  $set = $ilDB->query("SELECT usr_id FROM usr_data ");
78  while ($rec = $ilDB->fetchAssoc($set)) {
79  $ub[] = $rec["usr_id"];
80  }
81  }
82  return $ub;
83  }
global $ilDB
getOnlineUserFilter()
Get online user filter.
+ Here is the call graph for this function:

◆ getProviderId()

ilAwarenessUserProviderAllUsers::getProviderId ( )

Get provider id.

Returns
string provider id

Definition at line 34 of file class.ilAwarenessUserProviderAllUsers.php.

35  {
36  return "user_all";
37  }

◆ getTitle()

ilAwarenessUserProviderAllUsers::getTitle ( )

Provider title (used in awareness overlay and in administration settings)

Returns
string provider title

Definition at line 44 of file class.ilAwarenessUserProviderAllUsers.php.

45  {
46  $this->lng->loadLanguageModule("user");
47  return $this->lng->txt("user_awrn_all_users");
48  }

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