CachedCollectionPersister
extends
CachedPersister, CollectionPersister
in
Interface for second level cache collection persisters.
Table of Contents
Methods
- afterTransactionComplete() : void
- Perform whatever processing is encapsulated here after completion of the transaction.
- afterTransactionRolledBack() : void
- Perform whatever processing is encapsulated here after completion of the rolled-back.
- contains() : bool
- Checks for existence of an element.
- containsKey() : bool
- Checks for existence of a key.
- count() : int
- Counts the size of this persistent collection.
- delete() : void
- Deletes the persistent state represented by the given collection.
- get() : mixed
- Gets an element by key.
- getCacheRegion() : Region
- Gets the The region access.
- getSourceEntityMetadata() : ClassMetadata
- getTargetEntityMetadata() : ClassMetadata
- loadCollectionCache() : array<string|int, mixed>|null
- Loads a collection from cache
- loadCriteria() : array<string|int, mixed>
- Loads association entities matching the given Criteria object.
- slice() : array<string|int, mixed>
- Slices elements.
- storeCollectionCache() : void
- Stores a collection into cache
- update() : void
- Updates the given collection, synchronizing its state with the database by inserting, updating and deleting individual elements.
Methods
afterTransactionComplete()
Perform whatever processing is encapsulated here after completion of the transaction.
public
afterTransactionComplete() : void
afterTransactionRolledBack()
Perform whatever processing is encapsulated here after completion of the rolled-back.
public
afterTransactionRolledBack() : void
contains()
Checks for existence of an element.
public
contains(PersistentCollection $collection, object $element) : bool
Parameters
- $collection : PersistentCollection
- $element : object
Return values
boolcontainsKey()
Checks for existence of a key.
public
containsKey(PersistentCollection $collection, mixed $key) : bool
Parameters
- $collection : PersistentCollection
- $key : mixed
Return values
boolcount()
Counts the size of this persistent collection.
public
count(PersistentCollection $collection) : int
Parameters
- $collection : PersistentCollection
Return values
intdelete()
Deletes the persistent state represented by the given collection.
public
delete(PersistentCollection $collection) : void
Parameters
- $collection : PersistentCollection
get()
Gets an element by key.
public
get(PersistentCollection $collection, mixed $index) : mixed
Parameters
- $collection : PersistentCollection
- $index : mixed
getCacheRegion()
Gets the The region access.
public
getCacheRegion() : Region
Return values
RegiongetSourceEntityMetadata()
public
getSourceEntityMetadata() : ClassMetadata
Return values
ClassMetadatagetTargetEntityMetadata()
public
getTargetEntityMetadata() : ClassMetadata
Return values
ClassMetadataloadCollectionCache()
Loads a collection from cache
public
loadCollectionCache(PersistentCollection $collection, CollectionCacheKey $key) : array<string|int, mixed>|null
Parameters
- $collection : PersistentCollection
- $key : CollectionCacheKey
Return values
array<string|int, mixed>|nullloadCriteria()
Loads association entities matching the given Criteria object.
public
loadCriteria(PersistentCollection $collection, Criteria $criteria) : array<string|int, mixed>
Parameters
- $collection : PersistentCollection
- $criteria : Criteria
Return values
array<string|int, mixed>slice()
Slices elements.
public
slice(PersistentCollection $collection, int $offset[, int|null $length = null ]) : array<string|int, mixed>
Parameters
- $collection : PersistentCollection
- $offset : int
- $length : int|null = null
Return values
array<string|int, mixed>storeCollectionCache()
Stores a collection into cache
public
storeCollectionCache(CollectionCacheKey $key, array<string|int, mixed>|Collection $elements) : void
Parameters
- $key : CollectionCacheKey
- $elements : array<string|int, mixed>|Collection
update()
Updates the given collection, synchronizing its state with the database by inserting, updating and deleting individual elements.
public
update(PersistentCollection $collection) : void
Parameters
- $collection : PersistentCollection