Drupal 8  8.0.2
PrivateTempStoreFactory Class Reference

Public Member Functions

 __construct (KeyValueExpirableFactoryInterface $storage_factory, LockBackendInterface $lock_backend, AccountProxyInterface $current_user, RequestStack $request_stack, $expire=604800)
 
 get ($collection)
 

Protected Attributes

 $storageFactory
 
 $lockBackend
 
 $currentUser
 
 $requestStack
 
 $expire
 

Detailed Description

Creates a PrivateTempStore object for a given collection.

Constructor & Destructor Documentation

__construct ( KeyValueExpirableFactoryInterface  $storage_factory,
LockBackendInterface  $lock_backend,
AccountProxyInterface  $current_user,
RequestStack  $request_stack,
  $expire = 604800 
)

Constructs a Drupal object.

Parameters
\Drupal\Core\KeyValueStore\KeyValueExpirableFactoryInterface$storage_factoryThe key/value store factory.
\Drupal\Core\Lock\LockBackendInterface$lock_backendThe lock object used for this data.
\Drupal\Core\Session\AccountProxyInterface$current_userThe current account.
\Symfony\Component\HttpFoundation\RequestStack$request_stackThe request stack.
int$expireThe time to live for items, in seconds.

References Drupal\currentUser(), and Drupal\requestStack().

Here is the call graph for this function:

Member Function Documentation

get (   $collection)

Creates a PrivateTempStore.

Parameters
string$collectionThe collection name to use for this key/value store. This is typically a shared namespace or module name, e.g. 'views', 'entity', etc.
Returns
An instance of the key/value store.

References Drupal\currentUser(), and Drupal\requestStack().

Here is the call graph for this function:

Field Documentation

Drupal Core Lock LockBackendInterface $lockBackend
protected

The lock object used for this data.


The documentation for this class was generated from the following file: