當前位置: 首頁>>代碼示例>>PHP>>正文


PHP eZPersistentObject::newObjectOrder方法代碼示例

本文整理匯總了PHP中eZPersistentObject::newObjectOrder方法的典型用法代碼示例。如果您正苦於以下問題:PHP eZPersistentObject::newObjectOrder方法的具體用法?PHP eZPersistentObject::newObjectOrder怎麽用?PHP eZPersistentObject::newObjectOrder使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在eZPersistentObject的用法示例。


在下文中一共展示了eZPersistentObject::newObjectOrder方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: create

 static function create( $contentClassAttributeID, $contentClassAttributeVersion, $element )
 {
     $row = array( "id" => null,
                   "contentclass_attribute_id" => $contentClassAttributeID,
                   "contentclass_attribute_version" => $contentClassAttributeVersion,
                   "enumvalue" => "",
                   "enumelement" => $element,
                   "placement" => eZPersistentObject::newObjectOrder( eZEnumValue::definition(),
                                                                      "placement",
                                                                      array( "contentclass_attribute_id" => $contentClassAttributeID,
                                                                             "contentclass_attribute_version" => $contentClassAttributeVersion ) ) );
     return new eZEnumValue( $row );
 }
開發者ID:nottavi,項目名稱:ezpublish,代碼行數:13,代碼來源:ezenumvalue.php

示例2: create

 /**
  * Creates a new workflow event
  *
  * @param int $workflowID
  * @param string $typeString
  *
  * @return eZWorkflowEvent
  */
 static function create($workflowID, $typeString)
 {
     $row = array("id" => null, "version" => 1, "workflow_id" => $workflowID, "workflow_type_string" => $typeString, "description" => "", "placement" => eZPersistentObject::newObjectOrder(eZWorkflowEvent::definition(), "placement", array("version" => 1, "workflow_id" => $workflowID)));
     return new eZWorkflowEvent($row);
 }
開發者ID:netbliss,項目名稱:ezpublish,代碼行數:13,代碼來源:ezworkflowevent.php

示例3: create

    static function create( $class_id, $data_type_string, $optionalValues = array(), $languageLocale = false )
    {
        $nameList = new eZSerializedObjectNameList();
        if ( isset( $optionalValues['serialized_name_list'] ) )
            $nameList->initFromSerializedList( $optionalValues['serialized_name_list'] );
        else if ( isset( $optionalValues['name'] ) )
            $nameList->initFromString( $optionalValues['name'], $languageLocale );
        else
            $nameList->initFromString( '', $languageLocale );

        $descriptionList = new eZSerializedObjectNameList();
        if ( isset( $optionalValues['serialized_description_list'] ) )
            $descriptionList->initFromSerializedList( $optionalValues['serialized_description_list'] );
        else if ( isset( $optionalValues['description'] ) )
            $descriptionList->initFromString( $optionalValues['description'], $languageLocale );
        else
            $descriptionList->initFromString( '', $languageLocale );

        if ( isset( $optionalValues['data_text_i18n'] ) )
        {
            $dataTextI18nList = new eZSerializedObjectNameList( $optionalValues['data_text_i18n'] );
            $optionalValues['serialized_data_text'] = $dataTextI18nList->serializeNames();
        }

        $row = array(
            'id' => null,
            'version' => eZContentClass::VERSION_STATUS_TEMPORARY,
            'contentclass_id' => $class_id,
            'identifier' => '',
            'serialized_name_list' => $nameList->serializeNames(),
            'serialized_description_list' => $descriptionList->serializeNames(),
            'is_searchable' => 1,
            'is_required' => 0,
            'can_translate' => 1,
            'is_information_collector' => 0,
            'data_type_string' => $data_type_string,
            'placement' => eZPersistentObject::newObjectOrder( eZContentClassAttribute::definition(),
                                                               'placement',
                                                               array( 'version' => 1,
                                                                      'contentclass_id' => $class_id ) ) );
        $row = array_merge( $row, $optionalValues );
        $attribute = new eZContentClassAttribute( $row );

        return $attribute;
    }
開發者ID:nottavi,項目名稱:ezpublish,代碼行數:45,代碼來源:ezcontentclassattribute.php


注:本文中的eZPersistentObject::newObjectOrder方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。