PHP 클래스 Neos\Flow\Persistence\Generic\Session

파일 보기 프로젝트 열기: neos/flow-development-collection 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$identifierMap array
$objectMap SplObjectStorage
$reconstitutedEntities SplObjectStorage Reconstituted objects
$reconstitutedEntitiesData array Reconstituted entity data (effectively their clean state)
$reflectionService Neos\Flow\Reflection\ReflectionService

공개 메소드들

메소드 설명
__construct ( ) Constructs a new Session
destroy ( ) : void Destroy the state of the persistence session and reset all internal data.
getCleanStateOfProperty ( object $object, string $propertyName ) : mixed Returns the previous (last persisted) state of the property.
getIdentifierByObject ( object $object ) : string Returns the identifier for the given object either from the session, if the object was registered, or from the object itself using a special uuid property or the internal properties set by AOP.
getObjectByIdentifier ( string $identifier ) : object Returns the object for the given identifier
getReconstitutedEntities ( ) : SplObjectStorage Returns all objects which have been registered as reconstituted
hasIdentifier ( string $identifier ) : boolean Checks whether the given identifier is known to the identity map
hasObject ( object $object ) : boolean Checks whether the given object is known to the identity map
injectReflectionService ( ReflectionService $reflectionService ) : void Injects a Reflection Service instance
isDirty ( object $object, string $propertyName ) : boolean Checks whether the given property was changed in the object since it was reconstituted. Returns TRUE for unknown objects in all cases!
isReconstitutedEntity ( object $entity ) : boolean Tells whether the given object is a reconstituted entity.
registerObject ( object $object, string $identifier ) Register an identifier for an object
registerReconstitutedEntity ( object $entity, array $entityData ) : void Registers data for a reconstituted object.
replaceReconstitutedEntity ( object $oldEntity, object $newEntity ) : void Replace a reconstituted object, leaves the clean data unchanged.
unregisterObject ( string $object ) : void Unregister an object
unregisterReconstitutedEntity ( object $entity ) : void Unregisters data for a reconstituted object

보호된 메소드들

메소드 설명
isMultiValuedPropertyDirty ( array $cleanData, Traversable $currentValue ) : boolean Checks the $currentValue against the $cleanData.
isSingleValuedPropertyDirty ( string $type, mixed $previousValue, $currentValue ) : boolean Checks the $previousValue against the $currentValue.

메소드 상세

__construct() 공개 메소드

Constructs a new Session
public __construct ( )

destroy() 공개 메소드

Destroy the state of the persistence session and reset all internal data.
public destroy ( ) : void
리턴 void

getCleanStateOfProperty() 공개 메소드

If nothing is found, NULL is returned.
public getCleanStateOfProperty ( object $object, string $propertyName ) : mixed
$object object
$propertyName string
리턴 mixed

getIdentifierByObject() 공개 메소드

Note: this returns an UUID even if the object has not been persisted in case of AOP-managed entities. Use isNewObject() if you need to distinguish those cases.
public getIdentifierByObject ( object $object ) : string
$object object
리턴 string

getObjectByIdentifier() 공개 메소드

Returns the object for the given identifier
public getObjectByIdentifier ( string $identifier ) : object
$identifier string
리턴 object

getReconstitutedEntities() 공개 메소드

Returns all objects which have been registered as reconstituted
public getReconstitutedEntities ( ) : SplObjectStorage
리턴 SplObjectStorage All reconstituted objects

hasIdentifier() 공개 메소드

Checks whether the given identifier is known to the identity map
public hasIdentifier ( string $identifier ) : boolean
$identifier string
리턴 boolean

hasObject() 공개 메소드

Checks whether the given object is known to the identity map
public hasObject ( object $object ) : boolean
$object object
리턴 boolean

injectReflectionService() 공개 메소드

Injects a Reflection Service instance
public injectReflectionService ( ReflectionService $reflectionService ) : void
$reflectionService Neos\Flow\Reflection\ReflectionService
리턴 void

isDirty() 공개 메소드

Checks whether the given property was changed in the object since it was reconstituted. Returns TRUE for unknown objects in all cases!
public isDirty ( object $object, string $propertyName ) : boolean
$object object
$propertyName string
리턴 boolean

isMultiValuedPropertyDirty() 보호된 메소드

Checks the $currentValue against the $cleanData.
protected isMultiValuedPropertyDirty ( array $cleanData, Traversable $currentValue ) : boolean
$cleanData array
$currentValue Traversable
리턴 boolean

isReconstitutedEntity() 공개 메소드

Tells whether the given object is a reconstituted entity.
public isReconstitutedEntity ( object $entity ) : boolean
$entity object
리턴 boolean

isSingleValuedPropertyDirty() 보호된 메소드

Checks the $previousValue against the $currentValue.
protected isSingleValuedPropertyDirty ( string $type, mixed $previousValue, $currentValue ) : boolean
$type string
$previousValue mixed
리턴 boolean

registerObject() 공개 메소드

Register an identifier for an object
public registerObject ( object $object, string $identifier )
$object object
$identifier string

registerReconstitutedEntity() 공개 메소드

$entityData format is described in "Documentation/PersistenceFramework object data format.txt"
public registerReconstitutedEntity ( object $entity, array $entityData ) : void
$entity object
$entityData array
리턴 void

replaceReconstitutedEntity() 공개 메소드

Replace a reconstituted object, leaves the clean data unchanged.
public replaceReconstitutedEntity ( object $oldEntity, object $newEntity ) : void
$oldEntity object
$newEntity object
리턴 void

unregisterObject() 공개 메소드

Unregister an object
public unregisterObject ( string $object ) : void
$object string
리턴 void

unregisterReconstitutedEntity() 공개 메소드

Unregisters data for a reconstituted object
public unregisterReconstitutedEntity ( object $entity ) : void
$entity object
리턴 void

프로퍼티 상세

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

protected array $identifierMap
리턴 array

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

protected SplObjectStorage $objectMap
리턴 SplObjectStorage

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

Reconstituted objects
protected SplObjectStorage $reconstitutedEntities
리턴 SplObjectStorage

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

Reconstituted entity data (effectively their clean state)
protected array $reconstitutedEntitiesData
리턴 array

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

protected ReflectionService,Neos\Flow\Reflection $reflectionService
리턴 Neos\Flow\Reflection\ReflectionService