All Data Structures Functions Variables Pages
Static Public Member Functions | Static Protected Member Functions
UserConfiguration Class Reference

Static Public Member Functions

static find ($userId, $moduleName, $key)
 
static get ($userId, $moduleName, $key)
 
static getAll ($userId)
 
static getByModuleName ($userId, $moduleName)
 
static set ($userId, $moduleName, $key, $value)
 
static delete ($userId, $moduleName, $key)
 

Static Protected Member Functions

static getBean ($userId, $moduleName, $key)
 
static findBean ($userId, $moduleName, $key)
 
static getTableName ()
 

Detailed Description

Sets, gets, and deletes configuration entries in the application's database by user.

Definition at line 40 of file UserConfiguration.php.

Member Function Documentation

static find (   $userId,
  $moduleName,
  $key 
)
static

Searches for a configuration entry for a particular user.

Parameters
$userid
$moduleNameA non-empty string identifying the module to which the configuration entry belongs.
$keyA non-empty string identifying the configuration entry.
Returns
A value of the type that was originally put in into the entry or null if the entry is not found.

Definition at line 51 of file UserConfiguration.php.

static get (   $userId,
  $moduleName,
  $key 
)
static

Gets a configuration entry for a particular user.

Parameters
$userid
$moduleNameA non-empty string identifying the module to which the configuration entry belongs.
$keyA non-empty string identifying the configuration entry.
Returns
A value of the type that was originally put in into the entry.

Definition at line 74 of file UserConfiguration.php.

static getAll (   $userId)
static

Gets all of the configuration entries for a particular user.

Parameters
$userid
Returns
An array of arrays, keyed first on the module names, and then the entry keys.

Definition at line 90 of file UserConfiguration.php.

static getByModuleName (   $userId,
  $moduleName 
)
static

Gets all of the configuration entries for a module.

Parameters
$userid
Returns
An array of arrays, keyed first on the module names, and then the entry keys.

Definition at line 112 of file UserConfiguration.php.

static set (   $userId,
  $moduleName,
  $key,
  $value 
)
static

Sets a configuration entry.

Parameters
$userid
$moduleNameA non-empty string identifying the module to which the configuration entry belongs.
$keyA non-empty string identifying the configuration entry.
$valueThe value to store, of whatever desired type.

Definition at line 137 of file UserConfiguration.php.

static delete (   $userId,
  $moduleName,
  $key 
)
static

Deletes a configuration entry.

Parameters
$userid
$moduleNameA non-empty string identifying the module to which the configuration entry belongs.
$keyA non-empty string identifying the configuration entry.

Definition at line 166 of file UserConfiguration.php.

static getBean (   $userId,
  $moduleName,
  $key 
)
staticprotected

Gets the RedBean bean representing the user configuration entry.

Parameters
$userid
Returns
A bean.

Definition at line 187 of file UserConfiguration.php.

static getTableName ( )
staticprotected

Gets the table name in which configuration entries are stored in the database.

Definition at line 216 of file UserConfiguration.php.


The documentation for this class was generated from the following file:
Generated on Wed Jun 3 2020 07:11:09