PHP 클래스 eZ\Publish\Core\Persistence\Legacy\Content\Type\Handler

상속: implements eZ\Publish\SPI\Persistence\Content\Type\Handler
파일 보기 프로젝트 열기: ezsystems/ezpublish-kernel

보호된 프로퍼티들

프로퍼티 타입 설명
$contentTypeGateway Gateway
$mapper Mapper Mapper for Type objects.
$updateHandler eZ\Publish\Core\Persistence\Legacy\Content\Type\Update\Handler Content Type update handler.

공개 메소드들

메소드 설명
__construct ( Gateway $contentTypeGateway, Mapper $mapper, Handler $updateHandler ) Creates a new content type handler.
addFieldDefinition ( mixed $contentTypeId, integer $status, eZ\Publish\SPI\Persistence\Content\Type\FieldDefinition $fieldDefinition ) Adds a new field definition to an existing Type.
copy ( mixed $userId, mixed $contentTypeId, integer $status ) : eZ\Publish\SPI\Persistence\Content\Type
create ( eZ\Publish\SPI\Persistence\Content\Type\CreateStruct $createStruct ) : eZ\Publish\SPI\Persistence\Content\Type
createDraft ( mixed $modifierId, mixed $contentTypeId ) : eZ\Publish\SPI\Persistence\Content\Type Creates a draft of existing defined content type.
createGroup ( eZ\Publish\SPI\Persistence\Content\Type\Group\CreateStruct $createStruct ) : eZ\Publish\SPI\Persistence\Content\Type\Group
delete ( mixed $contentTypeId, integer $status ) : boolean
deleteGroup ( mixed $groupId )
getContentCount ( mixed $contentTypeId ) : integer Counts the number of Content instances of the ContentType identified by given $contentTypeId.
getFieldDefinition ( mixed $id, integer $status ) : eZ\Publish\SPI\Persistence\Content\Type\FieldDefinition Returns field definition for the given field definition id.
getSearchableFieldMap ( )
link ( mixed $groupId, mixed $contentTypeId, $status ) Link a content type group with a content type.
load ( integer $contentTypeId, integer $status = Type::STATUS_DEFINED ) : eZ\Publish\SPI\Persistence\Content\Type Loads a content type by id and status.
loadAllGroups ( ) : eZ\Publish\SPI\Persistence\Content\Type\Group[]
loadByIdentifier ( string $identifier ) : eZ\Publish\SPI\Persistence\Content\Type Loads a (defined) content type by identifier.
loadByRemoteId ( mixed $remoteId ) : eZ\Publish\SPI\Persistence\Content\Type Loads a (defined) content type by remote id.
loadContentTypes ( mixed $groupId, integer $status ) : eZ\Publish\SPI\Persistence\Content\Type[]
loadGroup ( mixed $groupId ) : eZ\Publish\SPI\Persistence\Content\Type\Group
loadGroupByIdentifier ( string $identifier ) : eZ\Publish\SPI\Persistence\Content\Type\Group
publish ( mixed $contentTypeId ) Update content objects.
removeFieldDefinition ( mixed $contentTypeId, $status, mixed $fieldDefinitionId ) : boolean Removes a field definition from an existing Type.
unlink ( mixed $groupId, mixed $contentTypeId, integer $status ) Unlink a content type group from a content type.
update ( mixed $typeId, integer $status, eZ\Publish\SPI\Persistence\Content\Type\UpdateStruct $contentType ) : eZ\Publish\SPI\Persistence\Content\Type
updateFieldDefinition ( mixed $contentTypeId, $status, eZ\Publish\SPI\Persistence\Content\Type\FieldDefinition $fieldDefinition ) This method updates the given $fieldDefinition on a Type.
updateGroup ( eZ\Publish\SPI\Persistence\Content\Type\Group\UpdateStruct $struct ) : eZ\Publish\SPI\Persistence\Content\Type\Group

보호된 메소드들

메소드 설명
internalCreate ( eZ\Publish\SPI\Persistence\Content\Type\CreateStruct $createStruct, mixed | null $contentTypeId = null ) : eZ\Publish\SPI\Persistence\Content\Type Internal method for creating ContentType.
loadFromRows ( array $rows, mixed $typeIdentifier, integer $status ) : eZ\Publish\SPI\Persistence\Content\Type Loads a single Type from $rows.

메소드 상세

__construct() 공개 메소드

Creates a new content type handler.
public __construct ( Gateway $contentTypeGateway, Mapper $mapper, Handler $updateHandler )
$contentTypeGateway Gateway
$mapper Mapper
$updateHandler eZ\Publish\Core\Persistence\Legacy\Content\Type\Update\Handler

addFieldDefinition() 공개 메소드

This method creates a new status of the Type with the $fieldDefinition added. It does not update existing content objects depending on the field (default) values.
public addFieldDefinition ( mixed $contentTypeId, integer $status, eZ\Publish\SPI\Persistence\Content\Type\FieldDefinition $fieldDefinition )
$contentTypeId mixed
$status integer One of Type::STATUS_DEFINED|Type::STATUS_DRAFT|Type::STATUS_MODIFIED
$fieldDefinition eZ\Publish\SPI\Persistence\Content\Type\FieldDefinition

copy() 공개 메소드

public copy ( mixed $userId, mixed $contentTypeId, integer $status ) : eZ\Publish\SPI\Persistence\Content\Type
$userId mixed
$contentTypeId mixed
$status integer One of Type::STATUS_DEFINED|Type::STATUS_DRAFT|Type::STATUS_MODIFIED
리턴 eZ\Publish\SPI\Persistence\Content\Type

create() 공개 메소드

public create ( eZ\Publish\SPI\Persistence\Content\Type\CreateStruct $createStruct ) : eZ\Publish\SPI\Persistence\Content\Type
$createStruct eZ\Publish\SPI\Persistence\Content\Type\CreateStruct
리턴 eZ\Publish\SPI\Persistence\Content\Type

createDraft() 공개 메소드

Updates modified date, sets $modifierId and status to Type::STATUS_DRAFT on the new returned draft.
public createDraft ( mixed $modifierId, mixed $contentTypeId ) : eZ\Publish\SPI\Persistence\Content\Type
$modifierId mixed
$contentTypeId mixed
리턴 eZ\Publish\SPI\Persistence\Content\Type

createGroup() 공개 메소드

public createGroup ( eZ\Publish\SPI\Persistence\Content\Type\Group\CreateStruct $createStruct ) : eZ\Publish\SPI\Persistence\Content\Type\Group
$createStruct eZ\Publish\SPI\Persistence\Content\Type\Group\CreateStruct
리턴 eZ\Publish\SPI\Persistence\Content\Type\Group

delete() 공개 메소드

public delete ( mixed $contentTypeId, integer $status ) : boolean
$contentTypeId mixed
$status integer
리턴 boolean

deleteGroup() 공개 메소드

public deleteGroup ( mixed $groupId )
$groupId mixed

getContentCount() 공개 메소드

Counts the number of Content instances of the ContentType identified by given $contentTypeId.
public getContentCount ( mixed $contentTypeId ) : integer
$contentTypeId mixed
리턴 integer

getFieldDefinition() 공개 메소드

Returns field definition for the given field definition id.
public getFieldDefinition ( mixed $id, integer $status ) : eZ\Publish\SPI\Persistence\Content\Type\FieldDefinition
$id mixed
$status integer One of Type::STATUS_DEFINED|Type::STATUS_DRAFT|Type::STATUS_MODIFIED
리턴 eZ\Publish\SPI\Persistence\Content\Type\FieldDefinition

getSearchableFieldMap() 공개 메소드

또한 보기: eZ\Publish\SPI\Persistence\Content\Type\Handler::getSearchableFieldMap

internalCreate() 보호된 메소드

Used by self::create(), self::createDraft() and self::copy()
protected internalCreate ( eZ\Publish\SPI\Persistence\Content\Type\CreateStruct $createStruct, mixed | null $contentTypeId = null ) : eZ\Publish\SPI\Persistence\Content\Type
$createStruct eZ\Publish\SPI\Persistence\Content\Type\CreateStruct
$contentTypeId mixed | null Used by self::createDraft() to retain ContentType id in the draft
리턴 eZ\Publish\SPI\Persistence\Content\Type

load() 공개 메소드

Note: This method is responsible of having the Field Definitions of the loaded ContentType sorted by placement.
public load ( integer $contentTypeId, integer $status = Type::STATUS_DEFINED ) : eZ\Publish\SPI\Persistence\Content\Type
$contentTypeId integer
$status integer
리턴 eZ\Publish\SPI\Persistence\Content\Type

loadAllGroups() 공개 메소드

public loadAllGroups ( ) : eZ\Publish\SPI\Persistence\Content\Type\Group[]
리턴 eZ\Publish\SPI\Persistence\Content\Type\Group[]

loadByIdentifier() 공개 메소드

Note: This method is responsible of having the Field Definitions of the loaded ContentType sorted by placement.
public loadByIdentifier ( string $identifier ) : eZ\Publish\SPI\Persistence\Content\Type
$identifier string
리턴 eZ\Publish\SPI\Persistence\Content\Type

loadByRemoteId() 공개 메소드

Note: This method is responsible of having the Field Definitions of the loaded ContentType sorted by placement.
public loadByRemoteId ( mixed $remoteId ) : eZ\Publish\SPI\Persistence\Content\Type
$remoteId mixed
리턴 eZ\Publish\SPI\Persistence\Content\Type

loadContentTypes() 공개 메소드

public loadContentTypes ( mixed $groupId, integer $status ) : eZ\Publish\SPI\Persistence\Content\Type[]
$groupId mixed
$status integer
리턴 eZ\Publish\SPI\Persistence\Content\Type[]

loadFromRows() 보호된 메소드

Loads a single Type from $rows.
protected loadFromRows ( array $rows, mixed $typeIdentifier, integer $status ) : eZ\Publish\SPI\Persistence\Content\Type
$rows array
$typeIdentifier mixed
$status integer
리턴 eZ\Publish\SPI\Persistence\Content\Type

loadGroup() 공개 메소드

public loadGroup ( mixed $groupId ) : eZ\Publish\SPI\Persistence\Content\Type\Group
$groupId mixed
리턴 eZ\Publish\SPI\Persistence\Content\Type\Group

loadGroupByIdentifier() 공개 메소드

public loadGroupByIdentifier ( string $identifier ) : eZ\Publish\SPI\Persistence\Content\Type\Group
$identifier string
리턴 eZ\Publish\SPI\Persistence\Content\Type\Group

publish() 공개 메소드

Updates content objects, depending on the changed field definitions. A content type has a state which tells if its content objects yet have been adapted. Flags the content type as updated.
public publish ( mixed $contentTypeId )
$contentTypeId mixed

removeFieldDefinition() 공개 메소드

This method creates a new status of the Type with the field definition referred to by $fieldDefinitionId removed. It does not update existing content objects depending on the field (default) values.
public removeFieldDefinition ( mixed $contentTypeId, $status, mixed $fieldDefinitionId ) : boolean
$contentTypeId mixed
$fieldDefinitionId mixed
리턴 boolean

update() 공개 메소드

public update ( mixed $typeId, integer $status, eZ\Publish\SPI\Persistence\Content\Type\UpdateStruct $contentType ) : eZ\Publish\SPI\Persistence\Content\Type
$typeId mixed
$status integer
$contentType eZ\Publish\SPI\Persistence\Content\Type\UpdateStruct
리턴 eZ\Publish\SPI\Persistence\Content\Type

updateFieldDefinition() 공개 메소드

This method creates a new status of the Type with the updated $fieldDefinition. It does not update existing content objects depending on the field (default) values.
public updateFieldDefinition ( mixed $contentTypeId, $status, eZ\Publish\SPI\Persistence\Content\Type\FieldDefinition $fieldDefinition )
$contentTypeId mixed
$fieldDefinition eZ\Publish\SPI\Persistence\Content\Type\FieldDefinition

updateGroup() 공개 메소드

public updateGroup ( eZ\Publish\SPI\Persistence\Content\Type\Group\UpdateStruct $struct ) : eZ\Publish\SPI\Persistence\Content\Type\Group
$struct eZ\Publish\SPI\Persistence\Content\Type\Group\UpdateStruct
리턴 eZ\Publish\SPI\Persistence\Content\Type\Group

프로퍼티 상세

$contentTypeGateway 보호되어 있는 프로퍼티

protected Gateway,eZ\Publish\Core\Persistence\Legacy\Content\Type $contentTypeGateway
리턴 Gateway

$mapper 보호되어 있는 프로퍼티

Mapper for Type objects.
protected Mapper,eZ\Publish\Core\Persistence\Legacy\Content\Type $mapper
리턴 Mapper

$updateHandler 보호되어 있는 프로퍼티

Content Type update handler.
protected Handler,eZ\Publish\Core\Persistence\Legacy\Content\Type\Update $updateHandler
리턴 eZ\Publish\Core\Persistence\Legacy\Content\Type\Update\Handler