ILIAS
trunk Revision v11.0_alpha-1811-gd2d5443e411
|
Public Member Functions | |
__construct (int $a_record_id=0) | |
Singleton constructor To create an array of new records (without saving them) call the constructor directly. More... | |
setDefaultLanguage (string $language_code) | |
getDefaultLanguage () | |
delete () | |
enabledScope () | |
enableScope (bool $a_stat) | |
setScopes (array $a_scopes) | |
getScopes () | |
Get scopes. More... | |
getScopeRefIds () | |
save () | |
update () | |
validate () | |
setGlobalPosition (int $position) | |
getGlobalPosition () | |
getRecordId () | |
setActive (bool $a_active) | |
isActive () | |
setTitle (string $a_title) | |
getTitle () | |
setDescription (string $a_description) | |
getDescription () | |
setImportId (string $a_id_string) | |
getImportId () | |
setAssignedObjectTypes (array $a_obj_types) | |
appendAssignedObjectType (string $a_obj_type, string $a_sub_type, bool $a_optional=false) | |
getAssignedObjectTypes () | |
isAssignedObjectType (string $a_obj_type, string $a_sub_type) | |
setParentObject (int $a_obj_id) | |
getParentObject () | |
toXML (ilXmlWriter $writer) | |
To Xml. More... | |
__destruct () | |
_clone (array &$a_fields_map, ?int $a_parent_obj_id=null) | |
Static Public Member Functions | |
static | _getInstanceByRecordId (int $a_record_id) |
static | _getActiveSearchableRecords () |
Get active searchable records. More... | |
static | _lookupTitle (int $a_record_id) |
static | _lookupRecordIdByImportId (string $a_ilias_id) |
static | _getAssignableObjectTypes (bool $a_include_text=false) |
Get assignable object type public. More... | |
static | _getActivatedObjTypes () |
get activated obj types More... | |
static | _getRecords () |
Get records public. More... | |
static | _getAllRecordsByObjectType () |
Get records by obj_type Note: this returns only records with no sub types! More... | |
static | _getActivatedRecordsByObjectType (string $a_obj_type, string $a_sub_type="", bool $a_only_optional=false) |
Get activated records by object type. More... | |
static | _getSelectedRecordsByObject (string $a_obj_type, int $a_id, string $a_sub_type="", bool $is_ref_id=true) |
static | isFilteredByScope ($a_ref_id, array $scopes) |
Check if a given ref id is not filtered by scope restriction. More... | |
static | _delete ($a_record_id) |
static | saveObjRecSelection (int $a_obj_id, string $a_sub_type="", ?array $a_records=null, bool $a_delete_before=true) |
Save repository object record selection. More... | |
static | deleteObjRecSelection (int $a_obj_id) |
Delete repository object record selection. More... | |
static | getObjRecSelection (int $a_obj_id, string $a_sub_type="") |
Get repository object record selection. More... | |
static | getSharedRecords (int $a_obj1_id, int $a_obj2_id, string $a_sub_type="-") |
Protected Member Functions | |
setRecordId (int $record_id) | |
generateImportId () | |
generate unique record id More... | |
Protected Attributes | |
int | $record_id |
int | $global_position = 0 |
string | $import_id = '' |
bool | $active = false |
string | $title = '' |
string | $description = '' |
string | $language_default = '' |
array | $obj_types = array() |
int | $parent_obj = 0 |
bool | $scope_enabled = false |
array | $scopes = [] |
ilDBInterface | $db |
Private Member Functions | |
read () | |
Static Private Attributes | |
static | $instances = [] |
Definition at line 26 of file class.ilAdvancedMDRecord.php.
ilAdvancedMDRecord::__construct | ( | int | $a_record_id = 0 | ) |
Singleton constructor To create an array of new records (without saving them) call the constructor directly.
Otherwise call getInstance... public
int | record id |
Definition at line 59 of file class.ilAdvancedMDRecord.php.
References $DIC, getRecordId(), and read().
ilAdvancedMDRecord::__destruct | ( | ) |
Definition at line 760 of file class.ilAdvancedMDRecord.php.
References getRecordId().
ilAdvancedMDRecord::_clone | ( | array & | $a_fields_map, |
?int | $a_parent_obj_id = null |
||
) |
Definition at line 848 of file class.ilAdvancedMDRecord.php.
References getAssignedObjectTypes(), getDefaultLanguage(), getDescription(), ilAdvancedMDRecordTranslations\getInstanceByRecordId(), ilAdvancedMDFieldDefinition\getInstancesByRecordId(), getParentObject(), getRecordId(), getTitle(), isActive(), and setActive().
|
static |
Definition at line 393 of file class.ilAdvancedMDRecord.php.
References $DIC, $ilDB, $res, and ilAdvancedMDFieldDefinition\getInstancesByRecordId().
Referenced by delete().
|
static |
get activated obj types
Definition at line 184 of file class.ilAdvancedMDRecord.php.
References $DIC, $ilDB, $obj_types, $res, and ilDBConstants\FETCHMODE_OBJECT.
Referenced by ilAdvancedSearchGUI\__setSearchOptions(), ilAdvancedSearchGUI\initAdvancedMetaDataForm(), and ilObjFileGUI\initSettingsTab().
|
static |
Get activated records by object type.
Definition at line 254 of file class.ilAdvancedMDRecord.php.
References $DIC, $ilDB, $res, and ilDBConstants\FETCHMODE_OBJECT.
Referenced by ilCourseExporter\getActiveAdvMDRecords(), ilSessionExporter\getActiveAdvMDRecords(), ilGroupExporter\getActiveAdvMDRecords(), ilWikiExporter\getActiveAdvMDRecords(), ilGlossaryExporter\getActiveAdvMDRecords(), ilExerciseExporter\getActiveAdvMDRecords(), ilStudyProgrammeTypeDBRepository\getAllAMDRecords(), ilOrgUnitType\getAvailableAdvancedMDRecords(), ilContainerFilterAdvMDAdapter\getAvailableRecordSets(), and ilAdvancedMDRecordGUI\parseRecordSelection().
|
static |
Get active searchable records.
Definition at line 83 of file class.ilAdvancedMDRecord.php.
References $DIC, $ilDB, $res, and ilDBConstants\FETCHMODE_OBJECT.
|
static |
Get records by obj_type Note: this returns only records with no sub types!
Definition at line 228 of file class.ilAdvancedMDRecord.php.
References $DIC, $ilDB, $res, ilECSSetting\ecsConfigured(), ilDBConstants\FETCHMODE_OBJECT, and ilECSUtils\getPossibleRemoteTypes().
Referenced by ilAdvancedMDSettingsGUI\initFormSubstitutions(), ilAdvancedMDSettingsGUI\setSubTabs(), and ilAdvancedMDSettingsGUI\updateSubstitutions().
|
static |
Get assignable object type public.
Definition at line 141 of file class.ilAdvancedMDRecord.php.
References $DIC, $lng, ilECSSetting\ecsConfigured(), ilECSUtils\getPossibleRemoteTypes(), and ILIAS\UI\examples\Symbol\Glyph\Sort\sort().
Referenced by ilAdvancedMDRecordTableGUI\fillRow(), ilAdvancedMDSettingsGUI\initForm(), ilObjectMetaDataGUI\isAdvMDAvailable(), and ilAdvancedMDSettingsGUI\loadRecordFormData().
|
static |
Definition at line 71 of file class.ilAdvancedMDRecord.php.
Referenced by _getRecords(), ilAdvancedMDFieldDefinitionInteger\addCustomFieldToDefinitionForm(), ilAdvancedMDFieldDefinitionSelect\addCustomFieldToDefinitionFormInTranslationMode(), ilAdvancedMDSettingsGUI\confirmDeleteRecords(), ilAdvancedMDSettingsGUI\deleteRecords(), ilAdvancedMDSettingsGUI\exportRecords(), ilAdvancedMDRecordTableGUI\fillRow(), ilContainerFilterUtil\getContainerRecordTitle(), ilAdvancedMDFieldDefinitionSelectMulti\getValueForXML(), ilAdvancedMDFieldDefinitionSelect\getValueForXML(), ilAdvancedMDFieldDefinition\importDefinitionFormPostValues(), ilAdvancedMDFieldDefinitionText\importValueFromXML(), ilAdvancedMDFieldDefinitionSelect\importXMLProperty(), ilAdvancedMDRecordParser\initRecordObject(), ilAdvancedMDSettingsGUI\initRecordObject(), ilAdvancedMDRecordTranslations\read(), ilAdvancedMDFieldTranslations\read(), ilAdvancedMDFieldDefinitionSelect\readOptions(), ilAdvancedMDFieldDefinitionSelect\translateLegacyImportValueFromXML(), ilAdvancedMDSettingsGUI\updateRecords(), ilAdvancedMDFieldDefinition\useDefaultLanguageMode(), and ilAdvancedMDRecordXMLWriter\write().
|
static |
Get records public.
array | array of record objects |
Definition at line 208 of file class.ilAdvancedMDRecord.php.
References $DIC, $ilDB, $res, _getInstanceByRecordId(), and ilDBConstants\FETCHMODE_OBJECT.
Referenced by ilAdvancedMDValues\_cloneValues(), ilLuceneAdvancedSearchFields\getFields(), and ilAdvancedMDSettingsGUI\getParsedRecordObjects().
|
static |
string | $a_obj_type | |
int | $a_id | |
string | $a_sub_type | |
bool | $is_ref_id |
Definition at line 295 of file class.ilAdvancedMDRecord.php.
References ilContainer\_lookupContainerSetting(), ilObject\_lookupObjId(), and ilObjectServiceSettingsGUI\CUSTOM_METADATA.
Referenced by ilGlossaryTerm\_copyTerm(), ilObjPortfolioBase\clonePagesAndSettings(), ILIAS\EmployeeTalk\Metadata\MetadataHandler\copyValues(), ilGlossaryAdvMetaDataAdapter\getActiveRecords(), ilAdvancedMDRecordGUI\getActiveRecords(), ilObjBookingPool\getAdvancedMDFields(), ilPCAMDFormGUI\getAdvRecords(), ilGlossaryAdvMetaDataAdapter\getAllFields(), ilObjectMetaDataGUI\getBlockHTML(), ilAdvancedMDValues\getInstancesForObjectId(), ilObjectMetaDataGUI\getKeyValueList(), ilWikiFunctionsBlockGUI\getLegacyContent(), ILIAS\Cache\Services\SubObjectModes\Filter\Supplier\getRecordIds(), ILIAS\Cache\Services\SubObjectModes\DataTable\Supplier\getRecordIds(), ilPCAMDPageList\handleCopiedContent(), ilObjectMetaDataGUI\hasActiveRecords(), ilAdvancedMDValues\preloadedRead(), and ilAdvancedMDValues\queryForRecords().
|
static |
Definition at line 121 of file class.ilAdvancedMDRecord.php.
References $DIC, $ilDB, $res, and ilDBConstants\FETCHMODE_OBJECT.
Referenced by ilAdvancedMDRecordParser\extractRecordId().
|
static |
Definition at line 101 of file class.ilAdvancedMDRecord.php.
References $DIC, $ilDB, $res, and ilDBConstants\FETCHMODE_OBJECT.
Referenced by ilAdvancedMDSettingsGUI\initFormSubstitutions(), and ilECSSettingsGUI\prepareFieldSelection().
ilAdvancedMDRecord::appendAssignedObjectType | ( | string | $a_obj_type, |
string | $a_sub_type, | ||
bool | $a_optional = false |
||
) |
Definition at line 635 of file class.ilAdvancedMDRecord.php.
ilAdvancedMDRecord::delete | ( | ) |
Definition at line 431 of file class.ilAdvancedMDRecord.php.
References _delete(), ilAdvancedMDRecordScope\deleteByRecordId(), and getRecordId().
Referenced by ilAdvancedMDSettingsGUI\deleteRecords().
|
static |
Delete repository object record selection.
Definition at line 810 of file class.ilAdvancedMDRecord.php.
Referenced by ilAdvancedMDSettingsGUI\updateRecords().
ilAdvancedMDRecord::enabledScope | ( | ) |
ilAdvancedMDRecord::enableScope | ( | bool | $a_stat | ) |
Definition at line 442 of file class.ilAdvancedMDRecord.php.
|
protected |
generate unique record id
Definition at line 755 of file class.ilAdvancedMDRecord.php.
References getRecordId(), and IL_INST_ID.
Referenced by save(), and toXML().
ilAdvancedMDRecord::getAssignedObjectTypes | ( | ) |
Definition at line 647 of file class.ilAdvancedMDRecord.php.
References $obj_types.
Referenced by _clone(), isAssignedObjectType(), save(), toXML(), and update().
ilAdvancedMDRecord::getDefaultLanguage | ( | ) |
Definition at line 426 of file class.ilAdvancedMDRecord.php.
References $language_default.
Referenced by _clone(), save(), ilAdvancedMDSettingsGUI\saveRecord(), and update().
ilAdvancedMDRecord::getDescription | ( | ) |
Definition at line 611 of file class.ilAdvancedMDRecord.php.
References $description.
Referenced by _clone(), save(), toXML(), and update().
ilAdvancedMDRecord::getGlobalPosition | ( | ) |
Definition at line 576 of file class.ilAdvancedMDRecord.php.
References $global_position.
Referenced by ilAdvancedMDRecordObjectOrderings\compareLocalRecords(), ilAdvancedMDRecordObjectOrderings\compareRecords(), and update().
ilAdvancedMDRecord::getImportId | ( | ) |
Definition at line 621 of file class.ilAdvancedMDRecord.php.
References $import_id.
Referenced by save().
|
static |
Get repository object record selection.
int | $a_obj_id | object id if repository object |
array | $a_records | array of record ids that are selected (in use) by the object |
Definition at line 826 of file class.ilAdvancedMDRecord.php.
References $DIC, $ilDB, $r, and ILIAS\Repository\int().
Referenced by ilAdvancedMDValues\_cloneValues(), ilObjPortfolioBase\clonePagesAndSettings(), ILIAS\EmployeeTalk\Metadata\MetadataHandler\copyValues(), ilWikiExporter\getActiveAdvMDRecords(), ilGlossaryExporter\getActiveAdvMDRecords(), ilAdvancedMDSettingsGUI\getParsedRecordObjects(), getSharedRecords(), and ilAdvancedMDRecordGUI\parseRecordSelection().
ilAdvancedMDRecord::getParentObject | ( | ) |
Definition at line 668 of file class.ilAdvancedMDRecord.php.
References $parent_obj.
Referenced by _clone(), ilAdvancedMDSettingsGUI\deleteRecords(), and save().
ilAdvancedMDRecord::getRecordId | ( | ) |
Definition at line 581 of file class.ilAdvancedMDRecord.php.
References $record_id.
Referenced by __construct(), __destruct(), _clone(), ilAdvancedMDRecordObjectOrderings\compareLocalRecords(), delete(), generateImportId(), read(), save(), ilAdvancedMDSettingsGUI\saveRecord(), toXML(), and update().
ilAdvancedMDRecord::getScopeRefIds | ( | ) |
Definition at line 467 of file class.ilAdvancedMDRecord.php.
References $scope.
Referenced by toXML().
ilAdvancedMDRecord::getScopes | ( | ) |
Get scopes.
Definition at line 459 of file class.ilAdvancedMDRecord.php.
References $scopes.
Referenced by save(), and update().
|
static |
Definition at line 871 of file class.ilAdvancedMDRecord.php.
References $res, ilObject\_lookupType(), and getObjRecSelection().
ilAdvancedMDRecord::getTitle | ( | ) |
Definition at line 601 of file class.ilAdvancedMDRecord.php.
References $title.
Referenced by _clone(), ilAdvancedMDSettingsGUI\confirmDeleteRecords(), ilAdvancedMDSettingsGUI\deleteRecords(), ilAdvancedMDSettingsGUI\exportRecords(), save(), toXML(), update(), and validate().
ilAdvancedMDRecord::isActive | ( | ) |
ilAdvancedMDRecord::isAssignedObjectType | ( | string | $a_obj_type, |
string | $a_sub_type | ||
) |
Definition at line 652 of file class.ilAdvancedMDRecord.php.
References getAssignedObjectTypes().
|
static |
Check if a given ref id is not filtered by scope restriction.
int | $a_ref_id | |
ilAdvancedMDRecordScope[] | $scopes |
Definition at line 369 of file class.ilAdvancedMDRecord.php.
References $GLOBALS, $scope, and ilTree\RELATION_PARENT.
Referenced by ilAdvancedMDSettingsGUI\getParsedRecordObjects().
|
private |
Definition at line 716 of file class.ilAdvancedMDRecord.php.
References $res, ilDBConstants\FETCHMODE_OBJECT, getRecordId(), setActive(), setDefaultLanguage(), setDescription(), setGlobalPosition(), setImportId(), setParentObject(), setTitle(), and ilDBConstants\T_INTEGER.
Referenced by __construct().
ilAdvancedMDRecord::save | ( | ) |
Definition at line 476 of file class.ilAdvancedMDRecord.php.
References $DIC, $ilDB, $res, $scope, generateImportId(), getAssignedObjectTypes(), getDefaultLanguage(), getDescription(), getImportId(), getParentObject(), getRecordId(), getScopes(), getTitle(), isActive(), and ilDBConstants\T_TEXT.
Referenced by ilAdvancedMDSettingsGUI\saveRecord().
|
static |
Save repository object record selection.
int | $a_obj_id | object id if repository object |
string | $a_sub_type | subtype |
int[] | $a_records array of record ids that are selected (in use) by the object | |
bool | $a_delete_before | delete before update |
Definition at line 773 of file class.ilAdvancedMDRecord.php.
References $DIC, $ilDB, and $r.
Referenced by ilAdvancedMDValues\_cloneValues(), ilObjPortfolioBase\clonePagesAndSettings(), ILIAS\EmployeeTalk\Metadata\MetadataHandler\copyValues(), ilOrgUnitType\getAvailableAdvancedMDRecords(), ilAdvancedMetaDataImporter\importXmlRepresentation(), ilAdvancedMDRecordGUI\saveSelection(), ilObjOrgUnit\update(), ilObjStudyProgramme\update(), ilStudyProgrammeType\updateAssignedStudyProgrammesIcons(), and ilAdvancedMDSettingsGUI\updateRecords().
ilAdvancedMDRecord::setActive | ( | bool | $a_active | ) |
Definition at line 586 of file class.ilAdvancedMDRecord.php.
Referenced by _clone(), and read().
ilAdvancedMDRecord::setAssignedObjectTypes | ( | array | $a_obj_types | ) |
string[] |
Definition at line 630 of file class.ilAdvancedMDRecord.php.
ilAdvancedMDRecord::setDefaultLanguage | ( | string | $language_code | ) |
string | $language_code |
Definition at line 421 of file class.ilAdvancedMDRecord.php.
Referenced by read(), and ilAdvancedMDSettingsGUI\saveRecord().
ilAdvancedMDRecord::setDescription | ( | string | $a_description | ) |
Definition at line 606 of file class.ilAdvancedMDRecord.php.
Referenced by read().
ilAdvancedMDRecord::setGlobalPosition | ( | int | $position | ) |
Definition at line 571 of file class.ilAdvancedMDRecord.php.
Referenced by ilAdvancedMDRecordObjectOrderings\compareRecords(), and read().
ilAdvancedMDRecord::setImportId | ( | string | $a_id_string | ) |
Definition at line 616 of file class.ilAdvancedMDRecord.php.
Referenced by read().
ilAdvancedMDRecord::setParentObject | ( | int | $a_obj_id | ) |
Definition at line 663 of file class.ilAdvancedMDRecord.php.
Referenced by read().
|
protected |
ilAdvancedMDRecord::setScopes | ( | array | $a_scopes | ) |
ilAdvancedMDRecordScope[] |
Definition at line 450 of file class.ilAdvancedMDRecord.php.
ilAdvancedMDRecord::setTitle | ( | string | $a_title | ) |
Definition at line 596 of file class.ilAdvancedMDRecord.php.
Referenced by read().
ilAdvancedMDRecord::toXML | ( | ilXmlWriter | $writer | ) |
To Xml.
This method writes only the subset Record (including all fields) Use class.ilAdvancedMDRecordXMLWriter to generate a complete xml presentation.
Definition at line 678 of file class.ilAdvancedMDRecord.php.
References $ref_id, ilObject\_lookupObjId(), ilObject\_lookupType(), generateImportId(), getAssignedObjectTypes(), getDescription(), ilAdvancedMDRecordTranslations\getInstanceByRecordId(), ilAdvancedMDFieldDefinition\getInstancesByRecordId(), getRecordId(), getScopeRefIds(), getTitle(), IL_INST_ID, isActive(), null, ilXmlWriter\xmlElement(), ilXmlWriter\xmlEndTag(), and ilXmlWriter\xmlStartTag().
ilAdvancedMDRecord::update | ( | ) |
Definition at line 525 of file class.ilAdvancedMDRecord.php.
References $DIC, $ilDB, $res, $scope, ilAdvancedMDRecordScope\deleteByRecordId(), getAssignedObjectTypes(), getDefaultLanguage(), getDescription(), getGlobalPosition(), getRecordId(), getScopes(), getTitle(), isActive(), and ilDBConstants\T_TEXT.
ilAdvancedMDRecord::validate | ( | ) |
Definition at line 563 of file class.ilAdvancedMDRecord.php.
References getTitle().
|
protected |
Definition at line 34 of file class.ilAdvancedMDRecord.php.
Referenced by isActive().
|
protected |
Definition at line 50 of file class.ilAdvancedMDRecord.php.
|
protected |
Definition at line 36 of file class.ilAdvancedMDRecord.php.
Referenced by getDescription().
|
protected |
Definition at line 31 of file class.ilAdvancedMDRecord.php.
Referenced by getGlobalPosition().
|
protected |
Definition at line 33 of file class.ilAdvancedMDRecord.php.
Referenced by getImportId().
|
staticprivate |
Definition at line 28 of file class.ilAdvancedMDRecord.php.
|
protected |
Definition at line 37 of file class.ilAdvancedMDRecord.php.
Referenced by getDefaultLanguage().
|
protected |
Definition at line 42 of file class.ilAdvancedMDRecord.php.
Referenced by _getActivatedObjTypes(), and getAssignedObjectTypes().
|
protected |
Definition at line 43 of file class.ilAdvancedMDRecord.php.
Referenced by getParentObject().
|
protected |
Definition at line 30 of file class.ilAdvancedMDRecord.php.
Referenced by getRecordId(), and setRecordId().
|
protected |
Definition at line 44 of file class.ilAdvancedMDRecord.php.
Referenced by enabledScope().
|
protected |
Definition at line 48 of file class.ilAdvancedMDRecord.php.
Referenced by getScopes().
|
protected |
Definition at line 35 of file class.ilAdvancedMDRecord.php.
Referenced by getTitle().