|
ILIAS
release_5-3 Revision v5.3.23-19-g915713cf615
|
Class ActiveRecord. More...
Inheritance diagram for ActiveRecord:
Collaboration diagram for ActiveRecord:Public Member Functions | |
| 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 | 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) |
Data Fields | |
| const | ACTIVE_RECORD_VERSION = '2.0.7' |
Protected Member Functions | |
| serializeToCSV ($field) | |
| This method is called for every field of your instance if you use __asCsv. More... | |
| installDatabase () | |
Static Protected Member Functions | |
| static | getCalledClass () |
| static | fromCamelCase ($str) |
Protected Attributes | |
| $ar_safe_read = true | |
| $connector_container_name = '' | |
| ActiveRecord::__construct | ( | $primary_key = 0, |
|
| arConnector | $connector = null |
||
| ) |
| int | $primary_key | |
| arConnector | $connector |
Definition at line 117 of file class.ActiveRecord.php.
References $key, arFieldCache\get(), and read().
Here is the call graph for this function:| ActiveRecord::__asArray | ( | ) |
Definition at line 211 of file class.ActiveRecord.php.
References getArFieldList().
Referenced by __asCsv().
Here is the call graph for this function:
Here is the caller graph for this function:| ActiveRecord::__asCsv | ( | $separator = ';', |
|
$header = false |
|||
| ) |
| string | $separator | |
| bool | $header |
Definition at line 172 of file class.ActiveRecord.php.
References $header, __asArray(), getArFieldList(), and serializeToCSV().
Here is the call graph for this function:| ActiveRecord::__asSerializedObject | ( | ) |
Definition at line 241 of file class.ActiveRecord.php.
| ActiveRecord::__asStdClass | ( | ) |
Definition at line 226 of file class.ActiveRecord.php.
References getArFieldList().
Referenced by arConnectorSession\create().
Here is the call graph for this function:
Here is the caller graph for this function:| ActiveRecord::__call | ( | $name, | |
| $arguments | |||
| ) |
| $name | |
| $arguments |
Definition at line 930 of file class.ActiveRecord.php.
References $name.
| ActiveRecord::__getConvertedDateFieldsAsArray | ( | $format = null | ) |
| string | $format |
Definition at line 145 of file class.ActiveRecord.php.
References $format, $name, date, and getArFieldList().
Here is the call graph for this function:
|
static |
| string | $str | |
| bool | $capitalise_first_char |
Definition at line 952 of file class.ActiveRecord.php.
Referenced by arViewField\__construct().
Here is the caller graph for this function:
|
static |
| array | $additional_params |
Definition at line 601 of file class.ActiveRecord.php.
|
static |
Definition at line 798 of file class.ActiveRecord.php.
| ActiveRecord::afterObjectLoad | ( | ) |
Reimplemented in ilDclFieldProperty, ilOrgUnitPosition, and ilOrgUnitPermission.
Definition at line 538 of file class.ActiveRecord.php.
| ActiveRecord::buildFromArray | ( | array | $array | ) |
| array | $array |
Definition at line 252 of file class.ActiveRecord.php.
References arObjectCache\get(), arObjectCache\isCached(), and arObjectCache\store().
Here is the call graph for this function:
|
static |
| arConnector | $connector |
Definition at line 887 of file class.ActiveRecord.php.
| ActiveRecord::copy | ( | $new_id = 0 | ) |
| int | $new_id |
| arException |
Definition at line 526 of file class.ActiveRecord.php.
References arException\COPY_DESTINATION_ID_EXISTS.
|
static |
Definition at line 809 of file class.ActiveRecord.php.
Referenced by ilStudyProgrammeType\loadTranslation(), ilStudyProgrammeType\processAndStoreIconFile(), and ilOrgUnitPosition\storeAuthorities().
Here is the caller graph for this function:| ActiveRecord::create | ( | ) |
Reimplemented in ilDclFieldProperty, ilOrgUnitPosition, ilOrgUnitOperation, ilOrgUnitOperationContext, ilOrgUnitPermission, and arStorage.
Definition at line 508 of file class.ActiveRecord.php.
References arFieldCache\getPrimaryFieldName(), and arObjectCache\store().
Referenced by ilDclTableView\cloneStructure(), ilDclTableViewFieldSetting\cloneStructure(), and ilOrgUnitPathStorage\store().
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
| string | $date_format |
Definition at line 771 of file class.ActiveRecord.php.
|
static |
Definition at line 829 of file class.ActiveRecord.php.
| ActiveRecord::delete | ( | ) |
Reimplemented in ilDclTableView, ilOrgUnitPosition, and ilOrgUnitPermission.
Definition at line 576 of file class.ActiveRecord.php.
References arObjectCache\purge().
Here is the call graph for this function:
|
staticfinal |
| $field_name |
Definition at line 410 of file class.ActiveRecord.php.
|
static |
Tries to find the object and throws an Exception if object is not found, instead of returning null.
| $primary_key | ||
| array | $add_constructor_args |
| arException |
Definition at line 651 of file class.ActiveRecord.php.
References arException\RECORD_NOT_FOUND.
Referenced by ilOrgUnitOperationQueries\findById(), and ilObjDefReader\handlerBeginTag().
Here is the caller graph for this function:
|
static |
| $primary_key | ||
| array | $add_constructor_args |
@description Returns an existing Object with given primary-key or a new Instance with given primary-key set but not yet created
Definition at line 670 of file class.ActiveRecord.php.
Referenced by ilDclTableViewGUI\executeCommand().
Here is the caller graph for this function:
|
static |
Definition at line 840 of file class.ActiveRecord.php.
Referenced by ilDclTableView\createOrGetStandardView(), and ilDclTableViewFieldSetting\getInstance().
Here is the caller graph for this function:| ActiveRecord::fixDateField | ( | $field_name, | |
| $value | |||
| ) |
| $field_name | |
| $value |
Definition at line 279 of file class.ActiveRecord.php.
|
staticfinal |
|
staticprotected |
| string | $str |
Definition at line 968 of file class.ActiveRecord.php.
|
static |
Reimplemented in ilOrgUnitPosition.
Definition at line 818 of file class.ActiveRecord.php.
Referenced by ilBibliographicSetting\getAll(), ilStudyProgrammeType\getAllTypes(), and arConfigFormGUI\getValuesForItem().
Here is the caller graph for this function:| ActiveRecord::getArConnector | ( | ) |
Definition at line 40 of file class.ActiveRecord.php.
References arConnectorMap\get().
Referenced by arWhere\asSQLStatement().
Here is the call graph for this function:
Here is the caller graph for this function:| ActiveRecord::getArFieldList | ( | ) |
Definition at line 49 of file class.ActiveRecord.php.
References arFieldCache\get().
Referenced by __asArray(), __asCsv(), __asStdClass(), __getConvertedDateFieldsAsArray(), arWhere\asSQLStatement(), arConnectorDB\installDatabase(), arConnectorDB\updateDatabase(), and arConnectorDB\updateIndices().
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
| null | $key | |
| null | $values |
Definition at line 914 of file class.ActiveRecord.php.
References $key.
Referenced by ilOrgUnitPositionTableGUI\buildData(), ilOrgUnitPathStorage\getTextRepresentationOfOrgUnits(), ilOrgUnitUserAssignmentGUI\index(), ilOrgUnitPositionFormGUI\initFormElements(), ilMemcacheServerTableGUI\parseData(), and ilPermissionGUI\savePositionsPermissions().
Here is the caller graph for this function:
|
final |
Definition at line 325 of file class.ActiveRecord.php.
References $data.
Referenced by arConnectorDB\create(), and arConnectorDB\update().
Here is the caller graph for this function:
|
final |
Definition at line 316 of file class.ActiveRecord.php.
|
staticprotected |
@description Returns an instance of the instatiated calling active record (needs to be done in static methods) @TODO : This should be cached somehow
Definition at line 351 of file class.ActiveRecord.php.
References arCalledClassCache\get().
Referenced by getConnectorContainerName().
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Definition at line 851 of file class.ActiveRecord.php.
Referenced by arStorageRecordGUI\index().
Here is the caller graph for this function:| ActiveRecord::getConnectorContainerName | ( | ) |
Reimplemented in ilBibliographicSetting, ilOrgUnitPathStorage, arMixedKey, and ilADTActiveRecordWrapper.
Definition at line 69 of file class.ActiveRecord.php.
References $connector_container_name, and getCalledClass().
Referenced by arWhere\asSQLStatement(), arJoin\asStatementText(), arConnectorDB\checkFieldExists(), arConnectorDB\checkTableExists(), arConnectorDB\create(), innerjoinAR(), ActiveRecordList\innerjoinAR(), arConnectorDB\installDatabase(), arConnectorDB\nextID(), arConnectorDB\read(), arConnectorDB\removeField(), arConnectorDB\renameField(), arConnectorDB\resetDatabase(), arConnectorDB\truncateDatabase(), arConnectorDB\update(), arConnectorDB\updateDatabase(), and arConnectorDB\updateIndices().
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
Definition at line 874 of file class.ActiveRecord.php.
| ActiveRecord::getPrimaryFieldValue | ( | ) |
Reimplemented in ilADTActiveRecordWrapper.
Definition at line 94 of file class.ActiveRecord.php.
References arFieldCache\getPrimaryFieldName().
Referenced by arConnectorSession\create(), arObjectCache\purge(), arConnectorDB\read(), arConnectorSession\read(), arObjectCache\store(), and arConnectorDB\update().
Here is the call graph for this function:
Here is the caller graph for this function:
|
static |
| $tablename | ||
| $on_this | ||
| $on_external | ||
| array | $fields | |
| string | $operator |
Definition at line 726 of file class.ActiveRecord.php.
Referenced by ilMStListCoursesGUI\getActions().
Here is the caller graph for this function:
|
static |
| ActiveRecord | $ar | |
| $on_this | ||
| $on_external | ||
| array | $fields | |
| string | $operator |
Definition at line 711 of file class.ActiveRecord.php.
References getConnectorContainerName().
Here is the call graph for this function:| ActiveRecord::installConnector | ( | ) |
Definition at line 378 of file class.ActiveRecord.php.
|
finalprotected |
Definition at line 430 of file class.ActiveRecord.php.
|
staticfinal |
$arBuilder = new arBuilder(new ilYourARBasedClass());
$arBuilder->generateDBUpdateForInstallation();
Definition at line 367 of file class.ActiveRecord.php.
Referenced by arConnectorDB\resetDatabase().
Here is the caller graph for this function:
|
static |
Definition at line 862 of file class.ActiveRecord.php.
|
static |
| $tablename | ||
| $on_this | ||
| $on_external | ||
| array | $fields | |
| string | $operator |
Definition at line 743 of file class.ActiveRecord.php.
|
static |
| $start | |
| $end |
Definition at line 786 of file class.ActiveRecord.php.
References $end.
|
static |
| $orderBy | ||
| string | $orderDirection |
Definition at line 757 of file class.ActiveRecord.php.
Referenced by ilDclTableView\createOrGetStandardView(), ilOrgUnitPathStorage\getTextRepresentationOfOrgUnits(), and ilDclSelectionOption\getValues().
Here is the caller graph for this function:
|
static |
|
static |
| bool | $set_raw |
Definition at line 900 of file class.ActiveRecord.php.
| ActiveRecord::read | ( | ) |
| arException |
Reimplemented in arStorage.
Definition at line 546 of file class.ActiveRecord.php.
References $records, and arException\RECORD_NOT_FOUND.
Referenced by __construct().
Here is the caller graph for this function:
|
staticfinal |
| $field_name |
Definition at line 421 of file class.ActiveRecord.php.
|
staticfinal |
| $old_name | |
| $new_name |
Definition at line 390 of file class.ActiveRecord.php.
|
staticfinal |
|
static |
Reimplemented in ilBibliographicSetting, ilDclFieldProperty, ilDclSelectionOption, ilDclTableFieldSetting, ilDclTableView, ilDclTableViewFieldSetting, ilItemGroupAR, ilOrgUnitAuthority, ilOrgUnitPosition, ilOrgUnitOperation, ilOrgUnitOperationContext, ilOrgUnitPermission, ilOrgUnitUserAssignment, ilStudyProgramme, ilStudyProgrammeAdvancedMetadataRecord, ilStudyProgrammeAssignment, ilStudyProgrammeProgress, ilStudyProgrammeType, ilStudyProgrammeTypeTranslation, arConfig, arMessage, arUser, arMixedKey, arRealRecord, arStorageRecordStorage, ilADTActiveRecordWrapper, ilMemcacheServer, ilWACSecurePath, ILIAS\BackgroundTasks\Implementation\Persistence\BucketContainer, ILIAS\BackgroundTasks\Implementation\Persistence\TaskContainer, ILIAS\BackgroundTasks\Implementation\Persistence\ValueContainer, and ILIAS\BackgroundTasks\Implementation\Persistence\ValueToTaskContainer.
Definition at line 59 of file class.ActiveRecord.php.
References arException\UNKNONWN_EXCEPTION.
| ActiveRecord::save | ( | ) |
Definition at line 502 of file class.ActiveRecord.php.
|
protected |
This method is called for every field of your instance if you use __asCsv.
You can use it to customize your export into csv. (e.g. serialize an array).
| $field | string |
Definition at line 202 of file class.ActiveRecord.php.
Referenced by __asCsv().
Here is the caller graph for this function:| ActiveRecord::setConnectorContainerName | ( | $connector_container_name | ) |
| string | $connector_container_name |
Definition at line 85 of file class.ActiveRecord.php.
References $connector_container_name.
| ActiveRecord::setPrimaryFieldValue | ( | $value | ) |
| $value |
Definition at line 105 of file class.ActiveRecord.php.
References arFieldCache\getPrimaryFieldName().
Here is the call graph for this function:| ActiveRecord::sleep | ( | $field_name | ) |
| $field_name |
Reimplemented in ilDclTableView, ilDclTableViewFieldSetting, ilOrgUnitPermission, and ilADTActiveRecordWrapper.
Definition at line 294 of file class.ActiveRecord.php.
| ActiveRecord::store | ( | ) |
Reimplemented in ilOrgUnitPathStorage.
Definition at line 489 of file class.ActiveRecord.php.
References arFieldCache\getPrimaryFieldName(), and League\Flysystem\Adapter\Polyfill\update().
Here is the call graph for this function:| ActiveRecord::storeObjectToCache | ( | ) |
Definition at line 134 of file class.ActiveRecord.php.
References arObjectCache\store().
Here is the call graph for this function:
|
staticfinal |
|
staticfinal |
| ActiveRecord::update | ( | ) |
Reimplemented in ilDclFieldProperty, ilOrgUnitPosition, ilOrgUnitPermission, and arStorage.
Definition at line 569 of file class.ActiveRecord.php.
References arObjectCache\store().
Referenced by ilOrgUnitPathStorage\store().
Here is the call graph for this function:
Here is the caller graph for this function:
|
staticfinal |
Definition at line 448 of file class.ActiveRecord.php.
| ActiveRecord::wakeUp | ( | $field_name, | |
| $field_value | |||
| ) |
| $field_name | |
| $field_value |
Reimplemented in ilDclTableView, ilDclTableViewFieldSetting, ilOrgUnitPermission, and ilADTActiveRecordWrapper.
Definition at line 306 of file class.ActiveRecord.php.
|
static |
| $where | ||
| null | $operator |
Definition at line 693 of file class.ActiveRecord.php.
Referenced by ilStudyProgrammeUserProgress\__construct(), ilOrgUnitPosition\afterObjectLoad(), ilDclTableView\createFieldSetting(), ilObjOrgUnit\delete(), ilStudyProgrammeTypeTranslation\deleteAllTranslations(), ilOrgUnitOperationContextQueries\findByName(), ilOrgUnitOperationQueries\findByOperationString(), ilOrgUnitUserAssignment\findOrCreateAssignment(), ilDclSelectionOption\getAllForField(), ilDclTableView\getAllForTableId(), ilStudyProgrammeType\getAssignedAdvancedMDRecords(), ilStudyProgrammeType\getAssignedStudyProgrammes(), ilObjOrgUnitTree\getAssignements(), ilOrgUnitUserAssignmentQueries\getAssignmentOrFail(), ilObjStudyProgramme\getAssignmentsOf(), ilOrgUnitUserAssignmentQueries\getAssignmentsOfUserId(), ilObjStudyProgramme\getAssignmentsRaw(), ILIAS\BackgroundTasks\Implementation\Persistence\BasicPersistence\getBucketIdsByState(), ILIAS\BackgroundTasks\Implementation\Persistence\BasicPersistence\getBucketIdsOfUser(), ILIAS\BackgroundTasks\Implementation\Persistence\BasicPersistence\getBucketMetaOfUser(), ilOrgUnitPosition\getCorePosition(), ilDclTableView\getCountForTableId(), ilOrgUnitPosition\getDependentAuthorities(), ilDclCache\getFieldProperties(), ilDclBaseFieldModel\getFieldSettings(), ilDclTableView\getFieldSettings(), ilDclTableView\getFilterableFieldSettings(), ilDclTableFieldSetting\getInstance(), ilStudyProgrammeUserProgressDB\getInstanceForAssignment(), ilStudyProgrammeUserProgressDB\getInstancesForAssignment(), ilStudyProgrammeUserAssignment\getInstancesForProgram(), ilStudyProgrammeUserProgressDB\getInstancesForProgram(), ilStudyProgrammeUserProgressDB\getInstancesForUser(), ilStudyProgrammeUserAssignment\getInstancesOfUser(), ilOrgUnitUserAssignmentQueries\getOrgUnitIdsOfUsersPosition(), ilDclTableHelper\getStandardViewsByVisibleTables(), ilOrgUnitPermissionQueries\getTemplateSetForContextName(), ilOrgUnitUserAssignmentQueries\getUserAssignmentsOfPosition(), ilOrgUnitUserAssignmentQueries\getUserIdsOfOrgUnit(), ilOrgUnitUserAssignmentQueries\getUserIdsOfOrgUnits(), ilOrgUnitUserAssignmentQueries\getUserIdsOfOrgUnitsInPosition(), ilOrgUnitUserAssignmentQueries\getUserIdsOfOrgUnitsOfUsersPosition(), ilOrgUnitUserAssignmentQueries\getUserIdsOfPosition(), ilOrgUnitUserAssignmentQueries\getUserIdsOfUsersOrgUnitsInPosition(), ilDclTableView\getVisibleFields(), ilOrgUnitPermissionQueries\hasLocalSet(), ilStudyProgrammeType\loadTranslation(), ilDclCache\preloadFieldProperties(), and ilOrgUnitPosition\storeAuthorities().
Here is the caller graph for this function:
|
protected |
Definition at line 30 of file class.ActiveRecord.php.
|
protected |
Definition at line 34 of file class.ActiveRecord.php.
Referenced by getConnectorContainerName(), and setConnectorContainerName().
| const ActiveRecord::ACTIVE_RECORD_VERSION = '2.0.7' |
Definition at line 26 of file class.ActiveRecord.php.