|
| static | getDataFields ($objectType=null, $objectClass='', $includeNullClass=false) |
| |
| static | getDataClass () |
| |
| static | permMask ($perm) |
| |
| static | getReadableUserClass ($class) |
| |
| static | exportUserData (StoredUserData $storage) |
| |
| static | tableScheme ($db_table) |
| |
| static | expireTableScheme () |
| |
| static | find ($id) |
| |
| static | exists ($id) |
| |
| static | countBySql ($sql=1, $params=array()) |
| |
| static | create ($data) |
| |
| static | build ($data, $is_new=true) |
| |
| static | buildExisting ($data) |
| |
| static | import ($data) |
| |
| static | findBySQL ($sql, $params=array()) |
| |
| static | findOneBySQL ($where, $params=array()) |
| |
| static | findThru ($foreign_key_value, $options) |
| |
| static | findEachBySQL ($callable, $sql, $params=array()) |
| |
| static | findMany ($pks=array(), $order='', $order_params=array()) |
| |
| static | findEachMany ($callable, $pks=array(), $order='', $order_params=array()) |
| |
| static | findAndMapBySQL ($callable, $where, $params=array()) |
| |
| static | findAndMapMany ($callable, $pks=array(), $order='', $order_params=array()) |
| |
| static | deleteBySQL ($where, $params=array()) |
| |
| static | toObject ($id_or_object) |
| |
| static | __callStatic ($name, $arguments) |
| |
| static | exportUserData (StoredUserData $storage) |
| |
◆ __call()
| __call |
( |
|
$method, |
|
|
array |
$arguments |
|
) |
| |
Legacy handler for access via [get|set]VariableName().
- Parameters
-
| String | $method | Called method |
| Array | $arguments | Given arguments |
- Returns
- mixed Return value of the getter/setter
- Exceptions
-
| BadMethodCallException | when the method does not match a valid pattern |
◆ accessAllowed()
| accessAllowed |
( |
|
$perm = null, |
|
|
|
$watcher = '', |
|
|
|
$user = '' |
|
) |
| |
Returns whether a user may access this datafield.
- Parameters
-
| String | $perm | Permission of the user, optional defaults to current user |
| String | $watcher | Current user |
| String | $user | Associated user of the datafield |
- Returns
- bool indicating whether the datafield may be accessed.
◆ configure()
| static configure |
( |
|
$config = array() | ) |
|
|
staticprotected |
Configures this model.
- Parameters
-
| Array | $config | Configuration array |
Reimplemented from SimpleORMap.
◆ count()
Specialized count method that returns the number of concrete entries.
- Returns
- int number of entries
Reimplemented from SimpleORMap.
◆ editAllowed()
| editAllowed |
( |
|
$userPerms | ) |
|
Returns whether a user may edit this datafield.
- Parameters
-
| String | $userPerms | Permissions of the user |
- Returns
- bool indicating whether the datafield may be edited
◆ exportUserData()
◆ getDataClass()
Returns a list of all datatype classes with an id as key and a name as value.
- Returns
- array() list of all datatype classes
◆ getDataFields()
| static getDataFields |
( |
|
$objectType = null, |
|
|
|
$objectClass = '', |
|
|
|
$includeNullClass = false |
|
) |
| |
|
static |
Returns a collection of datafields filtered by objectType, objectClass and/or unassigned objectClasses.
- Parameters
-
| mixed | $objectType | Object type |
| String | $objectClass | Object class |
| bool | $includeNullClass | Should the object class "null" be included |
- Returns
- array of DataField instances
◆ getReadableUserClass()
| static getReadableUserClass |
( |
|
$class | ) |
|
|
static |
liefert String zu gegebener user_class-Maske
- Parameters
-
| integer | the user class mask |
- Returns
- string a string consisting of a comma separated list of permissions
◆ getValue()
Specialized getter for values. Will try to obtain the value and if an error occurs, convert it to snake case and try again.
- Parameters
-
- Returns
- mixed Contents of the variable with the key "$field"
- Exceptions
-
- Todo:
- This should be removed after a while (today is 2015-11-19)
Reimplemented from SimpleORMap.
◆ permMask()
Return the mask for the given permission
- Parameters
-
| string | the name of the permission |
- Returns
- integer the mask for the permission
◆ setType()
Sets the type and adjusts type param as well.
- Parameters
-
| String | $type | Type of this datafield |
◆ setValue()
| setValue |
( |
|
$field, |
|
|
|
$value |
|
) |
| |
Specialized setter for values. Will try to set the value first and if an error occurs, convert the field name to snake case and try again.
- Parameters
-
| String | $field | Field name |
| mixed | $value | Field value |
- Returns
- mixed Whatever SimpleORMap::setValue() might return
- Exceptions
-
- Todo:
- This should be removed after a while (today is 2015-11-19)
Reimplemented from SimpleORMap.
◆ $permission_masks
Initial value:= array(
'user' => 1,
'autor' => 2,
'tutor' => 4,
'dozent' => 8,
'admin' => 16,
'root' => 32,
'self' => 64,
)
The documentation for this class was generated from the following file: