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

Class ilDclFieldProperty. More...

+ Inheritance diagram for ilDclFieldProperty:
+ Collaboration diagram for ilDclFieldProperty:

Public Member Functions

 __construct ($primary_key=0, $connector=null)
 ilDclFieldProperty constructor. More...
 
 getId ()
 
 setId ($id)
 
 getFieldId ()
 
 setFieldId ($field_id)
 
 getName ()
 
 setName ($name)
 
 getValue ()
 
 setValue ($value)
 
 create ()
 
 update ()
 
 afterObjectLoad ()
 
 serializeData ($value)
 Serialize data before storing to db. More...
 
 deserializeData ($value)
 Deserialize data before applying to field. More...
 
- Public Member Functions inherited from ActiveRecord
 getArConnector ()
 
 getArFieldList ()
 
 getConnectorContainerName ()
 
 setConnectorContainerName ($connector_container_name)
 
 getPrimaryFieldValue ()
 
 setPrimaryFieldValue ($value)
 
 __construct ($primary_key=0, arConnector $connector=null)
 
 storeObjectToCache ()
 
 __getConvertedDateFieldsAsArray ($format=null)
 
 __asCsv ($separator=';', $header=false)
 
 __asArray ()
 
 __asStdClass ()
 
 __asSerializedObject ()
 
 buildFromArray (array $array)
 
 fixDateField ($field_name, $value)
 
 sleep ($field_name)
 
 wakeUp ($field_name, $field_value)
 
 getArrayForDb ()
 
 getArrayForConnector ()
 
 installConnector ()
 
 store ()
 
 save ()
 
 create ()
 
 copy ($new_id=0)
 
 afterObjectLoad ()
 
 read ()
 
 update ()
 
 delete ()
 
 __call ($name, $arguments)
 

Static Public Member Functions

static returnDbTableName ()
 
- Static Public Member Functions inherited from ActiveRecord
static returnDbTableName ()
 
static installDB ()
 
static renameDBField ($old_name, $new_name)
 
static tableExists ()
 
static fieldExists ($field_name)
 
static removeDBField ($field_name)
 
static updateDB ()
 
static resetDB ()
 
static truncateDB ()
 
static flushDB ()
 
static preloadObjects ()
 
static additionalParams (array $additional_params)
 
static findOrFail ($primary_key, array $add_constructor_args=array())
 Tries to find the object and throws an Exception if object is not found, instead of returning null. More...
 
static findOrGetInstance ($primary_key, array $add_constructor_args=array())
 
static where ($where, $operator=null)
 
static innerjoinAR (ActiveRecord $ar, $on_this, $on_external, $fields=array(' *'), $operator='=', $both_external=false)
 
static innerjoin ($tablename, $on_this, $on_external, $fields=array(' *'), $operator='=', $both_external=false)
 
static leftjoin ($tablename, $on_this, $on_external, $fields=array(' *'), $operator='=', $both_external=false)
 
static orderBy ($orderBy, $orderDirection='ASC')
 
static dateFormat ($date_format='d.m.Y - H:i:s')
 
static limit ($start, $end)
 
static affectedRows ()
 
static count ()
 
static get ()
 
static debug ()
 
static first ()
 
static getCollection ()
 
static last ()
 
static getFirstFromLastQuery ()
 
static connector (arConnector $connector)
 
static raw ($set_raw=true)
 
static getArray ($key=null, $values=null)
 
static _toCamelCase ($str, $capitalise_first_char=false)
 

Protected Attributes

 $id
 
 $field_id
 
 $name
 
 $value
 
- Protected Attributes inherited from ActiveRecord
 $ar_safe_read = true
 
 $connector_container_name = ''
 

Additional Inherited Members

- Data Fields inherited from ActiveRecord
const ACTIVE_RECORD_VERSION = '2.0.7'
 
- Protected Member Functions inherited from ActiveRecord
 serializeToCSV ($field)
 This method is called for every field of your instance if you use __asCsv. More...
 
 installDatabase ()
 
- Static Protected Member Functions inherited from ActiveRecord
static getCalledClass ()
 
static fromCamelCase ($str)
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

ilDclFieldProperty::__construct (   $primary_key = 0,
  $connector = null 
)

ilDclFieldProperty constructor.

Parameters
int$primary_key
null$connector

Definition at line 61 of file class.ilDclFieldProperty.php.

62 {
63 parent::__construct($primary_key, $connector);
64 }

Member Function Documentation

◆ afterObjectLoad()

ilDclFieldProperty::afterObjectLoad ( )

Reimplemented from ActiveRecord.

Definition at line 172 of file class.ilDclFieldProperty.php.

173 {
174 $this->value = $this->deserializeData($this->value);
175 }
deserializeData($value)
Deserialize data before applying to field.

References deserializeData().

+ Here is the call graph for this function:

◆ create()

ilDclFieldProperty::create ( )

Reimplemented from ActiveRecord.

Definition at line 152 of file class.ilDclFieldProperty.php.

153 {
154 $this->value = $this->serializeData($this->value);
155 parent::create();
156 }
serializeData($value)
Serialize data before storing to db.

References serializeData().

+ Here is the call graph for this function:

◆ deserializeData()

ilDclFieldProperty::deserializeData (   $value)

Deserialize data before applying to field.

Parameters
$valuemixed
Returns
mixed

Definition at line 202 of file class.ilDclFieldProperty.php.

203 {
204 $deserialize = json_decode($value, true);
205 if (is_array($deserialize)) {
206 return $deserialize;
207 }
208
209 return $value;
210 }

References $value.

Referenced by afterObjectLoad().

+ Here is the caller graph for this function:

◆ getFieldId()

ilDclFieldProperty::getFieldId ( )
Returns
int

Definition at line 98 of file class.ilDclFieldProperty.php.

References $field_id.

◆ getId()

ilDclFieldProperty::getId ( )
Returns
int

Definition at line 80 of file class.ilDclFieldProperty.php.

References $id.

◆ getName()

ilDclFieldProperty::getName ( )
Returns
string

Definition at line 116 of file class.ilDclFieldProperty.php.

117 {
118 return $this->name;
119 }

References $name.

◆ getValue()

ilDclFieldProperty::getValue ( )
Returns
string

Definition at line 134 of file class.ilDclFieldProperty.php.

135 {
136 return $this->value;
137 }

References $value.

◆ returnDbTableName()

static ilDclFieldProperty::returnDbTableName ( )
static
Returns
string @description Return the Name of your Database Table

Reimplemented from ActiveRecord.

Definition at line 71 of file class.ilDclFieldProperty.php.

72 {
73 return "il_dcl_field_prop";
74 }

◆ serializeData()

ilDclFieldProperty::serializeData (   $value)

Serialize data before storing to db.

Parameters
$valuemixed
Returns
mixed

Definition at line 185 of file class.ilDclFieldProperty.php.

186 {
187 if (is_array($value)) {
188 $value = json_encode($value);
189 }
190
191 return $value;
192 }

References $value.

Referenced by create(), and update().

+ Here is the caller graph for this function:

◆ setFieldId()

ilDclFieldProperty::setFieldId (   $field_id)
Parameters
int$field_id

Definition at line 107 of file class.ilDclFieldProperty.php.

108 {
109 $this->field_id = $field_id;
110 }

References $field_id.

◆ setId()

ilDclFieldProperty::setId (   $id)
Parameters
int$id

Definition at line 89 of file class.ilDclFieldProperty.php.

90 {
91 $this->id = $id;
92 }

References $id.

◆ setName()

ilDclFieldProperty::setName (   $name)
Parameters
string$name

Definition at line 125 of file class.ilDclFieldProperty.php.

126 {
127 $this->name = $name;
128 }

References $name.

◆ setValue()

ilDclFieldProperty::setValue (   $value)
Parameters
string$value

Definition at line 143 of file class.ilDclFieldProperty.php.

144 {
145 $this->value = $value;
146 }

References $value.

◆ update()

ilDclFieldProperty::update ( )

Reimplemented from ActiveRecord.

Definition at line 162 of file class.ilDclFieldProperty.php.

163 {
164 $this->value = $this->serializeData($this->value);
166 }
update($pash, $contents, Config $config)

References serializeData(), and League\Flysystem\Adapter\Polyfill\update().

+ Here is the call graph for this function:

Field Documentation

◆ $field_id

ilDclFieldProperty::$field_id
protected

Definition at line 35 of file class.ilDclFieldProperty.php.

Referenced by getFieldId(), and setFieldId().

◆ $id

ilDclFieldProperty::$id
protected

Definition at line 25 of file class.ilDclFieldProperty.php.

Referenced by getId(), and setId().

◆ $name

ilDclFieldProperty::$name
protected

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

Referenced by getName(), and setName().

◆ $value

ilDclFieldProperty::$value
protected

Definition at line 52 of file class.ilDclFieldProperty.php.

Referenced by deserializeData(), getValue(), serializeData(), and setValue().


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