PHP 인터페이스 Sulu\Bundle\PreviewBundle\Preview\PreviewInterface

파일 보기 프로젝트 열기: sulu/sulu 0 사용 예제들

공개 메소드들

메소드 설명
exists ( string $token ) : boolean Returns true if such a session exists.
render ( string $token, string $webspaceKey, string $locale ) : string Returns rendered preview-session.
start ( string $objectClass, string $id, integer $userId, string $webspaceKey, string $locale, array $data = [] ) : string Starts a new preview session.
stop ( string $token ) Stops the preview-session and deletes the data.
update ( string $token, string $webspaceKey, string $locale, array $data ) : array Updates given data in the preview-session.
updateContext ( string $token, string $webspaceKey, string $locale, array $context, array $data ) : string Updates given context and restart preview with given data.

메소드 상세

exists() 공개 메소드

Returns true if such a session exists.
public exists ( string $token ) : boolean
$token string To identify the preview-session
리턴 boolean

render() 공개 메소드

Returns rendered preview-session.
public render ( string $token, string $webspaceKey, string $locale ) : string
$token string To identify the preview-session
$webspaceKey string Webspace to render object
$locale string
리턴 string Complete html response

start() 공개 메소드

Starts a new preview session.
public start ( string $objectClass, string $id, integer $userId, string $webspaceKey, string $locale, array $data = [] ) : string
$objectClass string Class of object
$id string Identifier of object
$userId integer
$webspaceKey string
$locale string
$data array Initial data will be set on the object
리턴 string Token can be used to reuse this preview-session

stop() 공개 메소드

Stops the preview-session and deletes the data.
public stop ( string $token )
$token string To identify the preview-session

update() 공개 메소드

Updates given data in the preview-session.
public update ( string $token, string $webspaceKey, string $locale, array $data ) : array
$token string To identify the preview-session
$webspaceKey string Webspace to render object
$locale string
$data array Data which will be updated before re-rendering content
리턴 array Changes for the rendering

updateContext() 공개 메소드

Updates given context and restart preview with given data.
public updateContext ( string $token, string $webspaceKey, string $locale, array $context, array $data ) : string
$token string To identify the preview-session
$webspaceKey string Webspace to render object
$locale string
$context array Contains contextual data to restart preview
$data array Data which will be updated before re-rendering content
리턴 string Complete html response