PHP Class eZ\Publish\Core\REST\Server\Controller\ObjectState

Inheritance: extends eZ\Publish\Core\REST\Server\Controller
Show file Open project: ezsystems/ezpublish-kernel

Protected Properties

Property Type Description
$contentService eZ\Publish\API\Repository\ContentService Content service.
$objectStateService eZ\Publish\API\Repository\ObjectStateService ObjectState service.

Public Methods

Method Description
__construct ( eZ\Publish\API\Repository\ObjectStateService $objectStateService, eZ\Publish\API\Repository\ContentService $contentService ) Construct controller.
createObjectState ( $objectStateGroupId, Request $request ) : CreatedObjectState Creates a new object state.
createObjectStateGroup ( Request $request ) : CreatedObjectStateGroup Creates a new object state group.
deleteObjectState ( $objectStateId ) : eZ\Publish\Core\REST\Server\Values\NoContent The given object state is deleted.
deleteObjectStateGroup ( $objectStateGroupId ) : eZ\Publish\Core\REST\Server\Values\NoContent The given object state group including the object states is deleted.
getObjectStatesForContent ( $contentId ) : ContentObjectStates Returns the object states of content.
loadObjectState ( $objectStateGroupId, $objectStateId ) : RestObjectState Loads an object state.
loadObjectStateGroup ( $objectStateGroupId ) : eZ\Publish\API\Repository\Values\ObjectState\ObjectStateGroup Loads an object state group.
loadObjectStateGroups ( ) : ObjectStateGroupList Returns a list of all object state groups.
loadObjectStates ( $objectStateGroupId ) : ObjectStateList Returns a list of all object states of the given group.
setObjectStatesForContent ( $contentId, Request $request ) : ContentObjectStates Updates object states of content An object state in the input overrides the state of the object state group.
updateObjectState ( $objectStateGroupId, $objectStateId, Request $request ) : RestObjectState Updates an object state.
updateObjectStateGroup ( $objectStateGroupId, Request $request ) : eZ\Publish\API\Repository\Values\ObjectState\ObjectStateGroup Updates an object state group.

Method Details

__construct() public method

Construct controller.
public __construct ( eZ\Publish\API\Repository\ObjectStateService $objectStateService, eZ\Publish\API\Repository\ContentService $contentService )
$objectStateService eZ\Publish\API\Repository\ObjectStateService
$contentService eZ\Publish\API\Repository\ContentService

createObjectState() public method

Creates a new object state.
public createObjectState ( $objectStateGroupId, Request $request ) : CreatedObjectState
$objectStateGroupId
$request Symfony\Component\HttpFoundation\Request
return eZ\Publish\Core\REST\Server\Values\CreatedObjectState

createObjectStateGroup() public method

Creates a new object state group.
public createObjectStateGroup ( Request $request ) : CreatedObjectStateGroup
$request Symfony\Component\HttpFoundation\Request
return eZ\Publish\Core\REST\Server\Values\CreatedObjectStateGroup

deleteObjectState() public method

The given object state is deleted.
public deleteObjectState ( $objectStateId ) : eZ\Publish\Core\REST\Server\Values\NoContent
$objectStateId
return eZ\Publish\Core\REST\Server\Values\NoContent

deleteObjectStateGroup() public method

The given object state group including the object states is deleted.
public deleteObjectStateGroup ( $objectStateGroupId ) : eZ\Publish\Core\REST\Server\Values\NoContent
$objectStateGroupId
return eZ\Publish\Core\REST\Server\Values\NoContent

getObjectStatesForContent() public method

Returns the object states of content.
public getObjectStatesForContent ( $contentId ) : ContentObjectStates
$contentId
return eZ\Publish\Core\REST\Common\Values\ContentObjectStates

loadObjectState() public method

Loads an object state.
public loadObjectState ( $objectStateGroupId, $objectStateId ) : RestObjectState
$objectStateGroupId
$objectStateId
return eZ\Publish\Core\REST\Common\Values\RestObjectState

loadObjectStateGroup() public method

Loads an object state group.
public loadObjectStateGroup ( $objectStateGroupId ) : eZ\Publish\API\Repository\Values\ObjectState\ObjectStateGroup
$objectStateGroupId
return eZ\Publish\API\Repository\Values\ObjectState\ObjectStateGroup

loadObjectStateGroups() public method

Returns a list of all object state groups.
public loadObjectStateGroups ( ) : ObjectStateGroupList
return eZ\Publish\Core\REST\Server\Values\ObjectStateGroupList

loadObjectStates() public method

Returns a list of all object states of the given group.
public loadObjectStates ( $objectStateGroupId ) : ObjectStateList
$objectStateGroupId
return eZ\Publish\Core\REST\Server\Values\ObjectStateList

setObjectStatesForContent() public method

Updates object states of content An object state in the input overrides the state of the object state group.
public setObjectStatesForContent ( $contentId, Request $request ) : ContentObjectStates
$contentId
$request Symfony\Component\HttpFoundation\Request
return eZ\Publish\Core\REST\Common\Values\ContentObjectStates

updateObjectState() public method

Updates an object state.
public updateObjectState ( $objectStateGroupId, $objectStateId, Request $request ) : RestObjectState
$objectStateGroupId
$objectStateId
$request Symfony\Component\HttpFoundation\Request
return eZ\Publish\Core\REST\Common\Values\RestObjectState

updateObjectStateGroup() public method

Updates an object state group.
public updateObjectStateGroup ( $objectStateGroupId, Request $request ) : eZ\Publish\API\Repository\Values\ObjectState\ObjectStateGroup
$objectStateGroupId
$request Symfony\Component\HttpFoundation\Request
return eZ\Publish\API\Repository\Values\ObjectState\ObjectStateGroup

Property Details

$contentService protected property

Content service.
protected ContentService,eZ\Publish\API\Repository $contentService
return eZ\Publish\API\Repository\ContentService

$objectStateService protected property

ObjectState service.
protected ObjectStateService,eZ\Publish\API\Repository $objectStateService
return eZ\Publish\API\Repository\ObjectStateService