Handles eZ publish content classes. More...
Public Member Functions | |
| adjustAttributePlacements (&$attributes) | |
| & | alwaysAvailableLanguage () |
| alwaysAvailableLanguageLocale () | |
| buildContentObjectName (&$contentObjectName, $dataMap, $tmpTags=false) | |
| & | canCreateLanguages () |
| canInstantiateClasses () | |
| & | canInstantiateLanguages () |
| clearAlwaysAvailableLanguageID () | |
| clone () | |
| compareAttributes ($attr1, $attr2) | |
| contentObjectName (&$contentObject, $version=false, $translation=false) | |
| create ($userID=false, $optionalValues=array(), $languageLocale=false) | |
| & | creator () |
| & | dataMap () |
| definition () | |
| exists ($id, $version=EZ_CLASS_VERSION_STATUS_DEFINED, $userID=false, $useIdentifier=false) | |
| eZContentClass ($row) | |
| fetch ($id, $asObject=true, $version=EZ_CLASS_VERSION_STATUS_DEFINED, $user_id=false, $parent_id=null) | |
| & | fetchAllClasses ($asObject=true, $includeFilter=true, $groupList=false) |
| & | fetchAllGroups () |
| & | fetchAttributeByIdentifier ($identifier, $asObject=true) |
| & | fetchAttributes ($id=false, $asObject=true, $version=EZ_CLASS_VERSION_STATUS_DEFINED) |
| fetchByIdentifier ($identifier, $asObject=true, $version=EZ_CLASS_VERSION_STATUS_DEFINED, $user_id=false, $parent_id=null) | |
| fetchByRemoteID ($remoteID, $asObject=true, $version=EZ_CLASS_VERSION_STATUS_DEFINED, $user_id=false, $parent_id=null) | |
| & | fetchGroupIDList () |
| & | fetchGroupList () |
| & | fetchMatchGroupIDList () |
| fetchSearchableAttributes ($id=false, $asObject=true, $version=EZ_CLASS_VERSION_STATUS_DEFINED) | |
| hasNameInLanguage ($languageLocale) | |
| inGroup ($groupID) | |
| initializeCopy (&$originalClass) | |
| instantiate ($userID=false, $sectionID=0, $versionNumber=false, $languageCode=false, $versionStatus=EZ_VERSION_STATUS_INTERNAL_DRAFT) | |
| instantiateIn ($lang, $userID=false, $sectionID=0, $versionNumber=false, $versionStatus=EZ_VERSION_STATUS_INTERNAL_DRAFT) | |
| isRemovable () | |
| & | languages () |
| & | modifier () |
| & | name ($languageLocale=false) |
| & | nameList () |
| & | objectCount () |
| & | objectList () |
| & | prioritizedLanguages () |
| & | prioritizedLanguagesJsArray () |
| & | remoteID () |
| removableInformation ($includeAll=true) | |
| remove ($removeAttributes=false, $version=EZ_CLASS_VERSION_STATUS_DEFINED) | |
| removeAttributes ($removeAttributes=false, $contentClassID=false, $version=false) | |
| removeTranslation ($languageID) | |
| setAlwaysAvailableLanguageID ($languageID, $updateChilds=true) | |
| setCanInstantiateLanguages ($languageCodes) | |
| setName ($name, $languageLocale=false) | |
| setVersion ($version, $set_childs=false) | |
| store ($store_childs=false, $fieldFilters=null) | |
| storeDefined (&$attributes) | |
| sync ($fieldFilters=null) | |
| & | topPriorityLanguageLocale () |
| & | versionCount () |
| & | versionStatus () |
Static Public Member Functions | |
| & | canInstantiateClassList ($asObject=false, $includeFilter=true, $groupList=false, $fetchID=false) |
| fetchList ($version=EZ_CLASS_VERSION_STATUS_DEFINED, $asObject=true, $user_id=false, $sorts=null, $fields=null, $classFilter=false, $limit=null) | |
| nameFromSerializedString ($serailizedNameList) | |
| removeTemporary () | |
Private Attributes | |
| $AllGroups | |
| $CanInstantiateLanguages | |
| $ContentObjectName | |
| $Created | |
| $CreatorID | |
| $ID | |
| $Identifier | |
| $InGroups | |
| $IsContainer | |
| $LanguageMask | |
| $Modified | |
| $ModifierID | |
| $NameList | |
| $SerializedNameList | |
| $Version | |
| $VersionCount | |
Handles eZ publish content classes.
Definition at line 51 of file ezcontentclass.php.
| eZContentClass::adjustAttributePlacements | ( | &$ | attributes | ) |
Definition at line 963 of file ezcontentclass.php.
Referenced by storeDefined().
| & eZContentClass::alwaysAvailableLanguage | ( | ) |
Wrapper for eZContentClassNameList::alwaysAvailableLanguage.
Definition at line 1731 of file ezcontentclass.php.
| eZContentClass::alwaysAvailableLanguageLocale | ( | ) |
Wrapper for eZContentClassNameList::alwaysAvailableLanguageLocale.
Definition at line 1742 of file ezcontentclass.php.
| eZContentClass::buildContentObjectName | ( | &$ | contentObjectName, | |
| $ | dataMap, | |||
| $ | tmpTags = false | |||
| ) |
Generates a name for the content object based on the content object name pattern and data map of an object.
Definition at line 1498 of file ezcontentclass.php.
Referenced by contentObjectName().
| & eZContentClass::canCreateLanguages | ( | ) |
Wrapper for eZContentClassNameList::untranslatedLanguages.
Definition at line 1711 of file ezcontentclass.php.
| eZContentClass::canInstantiateClasses | ( | ) |
Definition at line 356 of file ezcontentclass.php.
| & eZContentClass::canInstantiateClassList | ( | $ | asObject = false, |
|
| $ | includeFilter = true, |
|||
| $ | groupList = false, |
|||
| $ | fetchID = false | |||
| ) | [static] |
Finds all classes that the current user can create objects from and returns. It is also possible to filter the list event more with $includeFilter and $groupList.
| $asObject | If true then it return eZContentClass objects, if not it will be an associative array with name and id keys. | |
| $includeFilter | If true then it will include only from class groups defined in $groupList, if not it will exclude those groups. | |
| $groupList | An array with class group IDs that should be used in filtering, use false if you do not wish to filter at all. | |
| $id | A unique name for the current fetch, this must be supplied when filtering is used if you want caching to work. |
Definition at line 424 of file ezcontentclass.php.
| & eZContentClass::canInstantiateLanguages | ( | ) |
Definition at line 1567 of file ezcontentclass.php.
| eZContentClass::clearAlwaysAvailableLanguageID | ( | ) |
Definition at line 1679 of file ezcontentclass.php.
| eZContentClass::clone | ( | ) |
Definition at line 177 of file ezcontentclass.php.
| eZContentClass::compareAttributes | ( | $ | attr1, | |
| $ | attr2 | |||
| ) |
Definition at line 958 of file ezcontentclass.php.
| eZContentClass::contentObjectName | ( | &$ | contentObject, | |
| $ | version = false, |
|||
| $ | translation = false | |||
| ) |
Will generate a name for the content object based on the class settings for content object.
Definition at line 1467 of file ezcontentclass.php.
| eZContentClass::create | ( | $ | userID = false, |
|
| $ | optionalValues = array(), |
|||
| $ | languageLocale = false | |||
| ) |
Creates an 'eZContentClass' object.
To specify contentclass name use either $optionalValues['serialized_name_list'] or combination of $optionalValues['name'] and/or $languageLocale.
In case of conflict(when both 'serialized_name_list' and 'name' with/without $languageLocale are specified) 'serialized_name_list' has top priority. This means that 'name' and $languageLocale will be ingnored because 'serialized_name_list' already has all needed info about names and languages.
If 'name' is specified then the contentclass will have a name in $languageLocale(if specified) or in default language.
If neither of 'serialized_name_list' or 'name' isn't specified then the contentclass will have an empty name in 'languageLocale'(if specified) or in default language.
'language_mask' and 'initial_language_id' attributes will be set according to specified(either in 'serialized_name_list' or by $languageLocale) languages.
Definition at line 222 of file ezcontentclass.php.
Referenced by eZContentClassPackageHandler::install(), and instantiate().
| & eZContentClass::creator | ( | ) |
Definition at line 636 of file ezcontentclass.php.
| & eZContentClass::dataMap | ( | ) |
Returns all attributes as an associative array with the key taken from the attribute identifier.
Definition at line 1357 of file ezcontentclass.php.
| eZContentClass::definition | ( | ) |
The definition array is an associative array consists of these keys:
asc or desc.Example:
function definition() { return array( "fields" => array( "id" => "ID", "version" => "Version", "name" => "Name" ), "keys" => array( "id", "version" ), "function_attributes" => array( "current" => "currentVersion", "class_name" => "className" ), "increment_key" => "id", "class_name" => "eZContentClass", "sort" => array( "id" => "asc" ), "name" => "ezcontentclass" ); }
Reimplemented from eZPersistentObject.
Definition at line 73 of file ezcontentclass.php.
Referenced by create(), exists(), fetch(), fetchByIdentifier(), fetchByRemoteID(), and fetchList().
| eZContentClass::exists | ( | $ | id, | |
| $ | version = EZ_CLASS_VERSION_STATUS_DEFINED, |
|||
| $ | userID = false, |
|||
| $ | useIdentifier = false | |||
| ) |
Definition at line 1143 of file ezcontentclass.php.
Referenced by eZContentClassPackageHandler::handleParameters().
| eZContentClass::eZContentClass | ( | $ | row | ) |
Definition at line 53 of file ezcontentclass.php.
Referenced by clone(), create(), fetch(), fetchByIdentifier(), and fetchByRemoteID().
| eZContentClass::fetch | ( | $ | id, | |
| $ | asObject = true, |
|||
| $ | version = EZ_CLASS_VERSION_STATUS_DEFINED, |
|||
| $ | user_id = false, |
|||
| $ | parent_id = null | |||
| ) |
Definition at line 1167 of file ezcontentclass.php.
Referenced by eZContentClassPackageHandler::addClass(), eZObjectRelationListType::createNewObject(), creator(), eZObjectRelationListType::customObjectAttributeHTTPAction(), eZContentObjectPackageHandler::generateFetchAliasArray(), eZContentClassPackageCreator::generatePackageInformation(), eZContentClassPackageHandler::handleParameters(), modifier(), eZContentClassOperations::remove(), removeAttributes(), removeTranslation(), and setAlwaysAvailableLanguageID().
| & eZContentClass::fetchAllClasses | ( | $ | asObject = true, |
|
| $ | includeFilter = true, |
|||
| $ | groupList = false | |||
| ) |
Finds all Classes in the system and returns them.
Definition at line 730 of file ezcontentclass.php.
| & eZContentClass::fetchAllGroups | ( | ) |
Finds all Class groups in the system and returns them.
Definition at line 769 of file ezcontentclass.php.
| & eZContentClass::fetchAttributeByIdentifier | ( | $ | identifier, | |
| $ | asObject = true | |||
| ) |
Fetch class attribute by identifier, return null if none exist.
| attribute | identifier. |
Definition at line 1403 of file ezcontentclass.php.
| & eZContentClass::fetchAttributes | ( | $ | id = false, |
|
| $ | asObject = true, |
|||
| $ | version = EZ_CLASS_VERSION_STATUS_DEFINED | |||
| ) |
Definition at line 1373 of file ezcontentclass.php.
Referenced by dataMap(), eZTemplateOptimizer::fetchClassDeclaration(), instantiate(), removableInformation(), eZContentObjectTreeNode::removeSubtrees(), removeTranslation(), setAlwaysAvailableLanguageID(), setVersion(), and store().
| eZContentClass::fetchByIdentifier | ( | $ | identifier, | |
| $ | asObject = true, |
|||
| $ | version = EZ_CLASS_VERSION_STATUS_DEFINED, |
|||
| $ | user_id = false, |
|||
| $ | parent_id = null | |||
| ) |
Definition at line 1252 of file ezcontentclass.php.
Referenced by eZContentFunctions::createAndPublishObject(), eZContentUpload::handleLocalFile(), eZContentUpload::handleUpload(), eZContentClassPackageHandler::install(), and eZContentObject::unserialize().
| eZContentClass::fetchByRemoteID | ( | $ | remoteID, | |
| $ | asObject = true, |
|||
| $ | version = EZ_CLASS_VERSION_STATUS_DEFINED, |
|||
| $ | user_id = false, |
|||
| $ | parent_id = null | |||
| ) |
Definition at line 1218 of file ezcontentclass.php.
Referenced by eZContentClassPackageHandler::install(), eZContentObjectPackageHandler::installFetchAliases(), eZContentObjectPackageHandler::installOverrides(), and eZContentClassPackageHandler::uninstall().
| & eZContentClass::fetchGroupIDList | ( | ) |
Find all groups the current class is placed in and returns a list of group IDs.
Definition at line 687 of file ezcontentclass.php.
| & eZContentClass::fetchGroupList | ( | ) |
Find all groups the current class is placed in and returns a list of group objects.
Definition at line 672 of file ezcontentclass.php.
Referenced by fetchGroupIDList(), and storeDefined().
| eZContentClass::fetchList | ( | $ | version = EZ_CLASS_VERSION_STATUS_DEFINED, |
|
| $ | asObject = true, |
|||
| $ | user_id = false, |
|||
| $ | sorts = null, |
|||
| $ | fields = null, |
|||
| $ | classFilter = false, |
|||
| $ | limit = null | |||
| ) | [static] |
Definition at line 1288 of file ezcontentclass.php.
Referenced by eZWaitUntilDateType::attribute(), eZMultiplexerType::attribute(), fetchAllGroups(), and removeTemporary().
| & eZContentClass::fetchMatchGroupIDList | ( | ) |
Returns the result from fetchGroupIDList() if class group overrides is enabled in content.ini.
false if disabled. EnableClassGroupOverride in group ContentOverrideSettings from INI file content.ini controls this behaviour. Definition at line 709 of file ezcontentclass.php.
| eZContentClass::fetchSearchableAttributes | ( | $ | id = false, |
|
| $ | asObject = true, |
|||
| $ | version = EZ_CLASS_VERSION_STATUS_DEFINED | |||
| ) |
Definition at line 1414 of file ezcontentclass.php.
| eZContentClass::hasNameInLanguage | ( | $ | languageLocale | ) |
Definition at line 1589 of file ezcontentclass.php.
| eZContentClass::inGroup | ( | $ | groupID | ) |
Definition at line 778 of file ezcontentclass.php.
| eZContentClass::initializeCopy | ( | &$ | originalClass | ) |
Initializes this class as a copy of $originalClass by creating new a new name and identifier. It will check if there are other classes already with this name in which case it will append a unique number to the name and identifier.
Definition at line 1031 of file ezcontentclass.php.
| eZContentClass::instantiate | ( | $ | userID = false, |
|
| $ | sectionID = 0, |
|||
| $ | versionNumber = false, |
|||
| $ | languageCode = false, |
|||
| $ | versionStatus = EZ_VERSION_STATUS_INTERNAL_DRAFT | |||
| ) |
Creates a new content object instance and stores it.
| user | ID (optional), current user if not set | |
| section | ID (optional), 0 if not set | |
| version | number, create initial version if not set |
Definition at line 282 of file ezcontentclass.php.
Referenced by instantiateIn().
| eZContentClass::instantiateIn | ( | $ | lang, | |
| $ | userID = false, |
|||
| $ | sectionID = 0, |
|||
| $ | versionNumber = false, |
|||
| $ | versionStatus = EZ_VERSION_STATUS_INTERNAL_DRAFT | |||
| ) |
Definition at line 268 of file ezcontentclass.php.
| eZContentClass::isRemovable | ( | ) |
Checks if the class can be removed and returns true if it can, false otherwise.
Definition at line 843 of file ezcontentclass.php.
Referenced by remove().
| & eZContentClass::languages | ( | ) |
Wrapper for eZContentClassNameList::languages.
Definition at line 1687 of file ezcontentclass.php.
| & eZContentClass::modifier | ( | ) |
Definition at line 653 of file ezcontentclass.php.
| & eZContentClass::name | ( | $ | languageLocale = false |
) |
Returns a contentclass name in $languageLocale language. Uses siteaccess language list or 'always available' language if $languageLocale is 'false'.
Definition at line 1601 of file ezcontentclass.php.
Referenced by instantiate().
| eZContentClass::nameFromSerializedString | ( | $ | serailizedNameList | ) | [static] |
Returns a contentclass name from serialized array $serializedNameList using top language from siteaccess language list or 'always available' name from $serializedNameList.
Definition at line 1584 of file ezcontentclass.php.
Referenced by eZContentObject::className(), eZContentStructureTreeOperator::createContentStructureNode(), eZContentObject::eZContentObject(), eZContentObject::fetchIDArray(), eZContentObjectTreeNode::makeObjectsArray(), and eZContentObject::relatedObjects().
| & eZContentClass::nameList | ( | ) |
Definition at line 1748 of file ezcontentclass.php.
| & eZContentClass::objectCount | ( | ) |
Definition at line 1539 of file ezcontentclass.php.
| & eZContentClass::objectList | ( | ) |
Definition at line 1552 of file ezcontentclass.php.
| & eZContentClass::prioritizedLanguages | ( | ) |
Wrapper for eZContentClassNameList::prioritizedLanguages.
Definition at line 1696 of file ezcontentclass.php.
| & eZContentClass::prioritizedLanguagesJsArray | ( | ) |
Definition at line 1702 of file ezcontentclass.php.
| & eZContentClass::remoteID | ( | ) |
Get remote id of content node
Definition at line 808 of file ezcontentclass.php.
| eZContentClass::removableInformation | ( | $ | includeAll = true |
) |
Returns information on why the class cannot be removed, it does the same checks as in isRemovable() but generates some text in the return array.
| $includeAll | Controls whether the returned information will contain all sources for not being to remove or just the first that it finds. |
Definition at line 861 of file ezcontentclass.php.
Referenced by isRemovable().
| eZContentClass::remove | ( | $ | removeAttributes = false, |
|
| $ | version = EZ_CLASS_VERSION_STATUS_DEFINED | |||
| ) |
Reimplemented from eZPersistentObject.
Definition at line 826 of file ezcontentclass.php.
| eZContentClass::removeAttributes | ( | $ | removeAttributes = false, |
|
| $ | contentClassID = false, |
|||
| $ | version = false | |||
| ) |
Definition at line 903 of file ezcontentclass.php.
Referenced by remove(), and storeDefined().
| eZContentClass::removeTemporary | ( | ) | [static] |
Will remove all temporary classes from the database.
Definition at line 789 of file ezcontentclass.php.
| eZContentClass::removeTranslation | ( | $ | languageID | ) |
Removes translated name for specified by $languageID language.
Definition at line 1757 of file ezcontentclass.php.
| eZContentClass::setAlwaysAvailableLanguageID | ( | $ | languageID, | |
| $ | updateChilds = true | |||
| ) |
Definition at line 1618 of file ezcontentclass.php.
Referenced by clearAlwaysAvailableLanguageID().
| eZContentClass::setCanInstantiateLanguages | ( | $ | languageCodes | ) |
Definition at line 1562 of file ezcontentclass.php.
| eZContentClass::setName | ( | $ | name, | |
| $ | languageLocale = false | |||
| ) |
Definition at line 1607 of file ezcontentclass.php.
Referenced by initializeCopy().
| eZContentClass::setVersion | ( | $ | version, | |
| $ | set_childs = false | |||
| ) |
Definition at line 1122 of file ezcontentclass.php.
Referenced by storeDefined().
| eZContentClass::store | ( | $ | store_childs = false, |
|
| $ | fieldFilters = null | |||
| ) |
Definition at line 978 of file ezcontentclass.php.
Referenced by removeTranslation(), setAlwaysAvailableLanguageID(), storeDefined(), and sync().
| eZContentClass::storeDefined | ( | &$ | attributes | ) |
Stores the current class as a defined version, updates the contentobject_name attribute and recreates the class group entries.
Definition at line 1060 of file ezcontentclass.php.
| eZContentClass::sync | ( | $ | fieldFilters = null |
) |
Reimplemented from eZPersistentObject.
Definition at line 1019 of file ezcontentclass.php.
Referenced by remoteID().
| & eZContentClass::topPriorityLanguageLocale | ( | ) |
Wrapper for eZContentClassNameList::topPriorityLanguageLocale.
Definition at line 1720 of file ezcontentclass.php.
Referenced by setName().
| & eZContentClass::versionCount | ( | ) |
Definition at line 1458 of file ezcontentclass.php.
| & eZContentClass::versionStatus | ( | ) |
Definition at line 1437 of file ezcontentclass.php.
eZContentClass::$AllGroups [private] |
Definition at line 1824 of file ezcontentclass.php.
eZContentClass::$CanInstantiateLanguages [private] |
Definition at line 1826 of file ezcontentclass.php.
eZContentClass::$ContentObjectName [private] |
Definition at line 1816 of file ezcontentclass.php.
eZContentClass::$Created [private] |
Definition at line 1821 of file ezcontentclass.php.
eZContentClass::$CreatorID [private] |
Definition at line 1819 of file ezcontentclass.php.
eZContentClass::$ID [private] |
Definition at line 1810 of file ezcontentclass.php.
eZContentClass::$Identifier [private] |
Definition at line 1815 of file ezcontentclass.php.
eZContentClass::$InGroups [private] |
Definition at line 1823 of file ezcontentclass.php.
eZContentClass::$IsContainer [private] |
Definition at line 1825 of file ezcontentclass.php.
eZContentClass::$LanguageMask [private] |
Definition at line 1827 of file ezcontentclass.php.
eZContentClass::$Modified [private] |
Definition at line 1822 of file ezcontentclass.php.
eZContentClass::$ModifierID [private] |
Definition at line 1820 of file ezcontentclass.php.
eZContentClass::$NameList [private] |
Definition at line 1814 of file ezcontentclass.php.
eZContentClass::$SerializedNameList [private] |
Definition at line 1812 of file ezcontentclass.php.
eZContentClass::$Version [private] |
Definition at line 1817 of file ezcontentclass.php.
eZContentClass::$VersionCount [private] |
Definition at line 1818 of file ezcontentclass.php.
1.6.3