Zend Framework  3.0
Public Member Functions | List of all members
StorageFactory Class Reference

Public Member Functions

 __invoke (ContainerInterface $container, $requestedName, array $options=null)
 Create session storage object (v3 usage).
 
 createService (ServiceLocatorInterface $services, $canonicalName=null, $requestedName=StorageInterface::class)
 Create and return a storage instance (v2 usage).
 
- Public Member Functions inherited from FactoryInterface
 createService (ServiceLocatorInterface $serviceLocator)
 Create service.
 

Member Function Documentation

__invoke ( ContainerInterface  $container,
  $requestedName,
array  $options = null 
)

Create session storage object (v3 usage).

Uses "session_storage" section of configuration to seed a StorageInterface instance. That array should contain the key "type", specifying the storage type to use, and optionally "options", containing any options to be used in creating the StorageInterface instance.

Parameters
ContainerInterface$container
Returns
StorageInterface
Exceptions
ServiceNotCreatedExceptionif session_storage is missing, or the factory cannot create the storage instance.

Implements FactoryInterface.

createService ( ServiceLocatorInterface  $services,
  $canonicalName = null,
  $requestedName = StorageInterface::class 
)

Create and return a storage instance (v2 usage).

Parameters
ServiceLocatorInterface$services
null | string$canonicalName
string$requestedName
Returns
StorageInterface