Class

eZ\Publish\Core\FieldType\GatewayBasedStorage

abstract class GatewayBasedStorage implements FieldStorage

Storage gateway base class to be used by FieldType storages.

Methods

__construct(array $gateways = array())

Construct from gateways.

addGateway(string $identifier, StorageGateway $gateway)

Adds a storage $gateway assigned to the given $identifier.

null|bool copyLegacyField(VersionInfo $versionInfo, Field $field, Field $originalField, array $context)

This method is used exclusively by Legacy Storage to copy external data of existing field in main language to the untranslatable field not passed in create or update struct, but created implicitly in storage layer.

Details

at line 43
public __construct(array $gateways = array())

Construct from gateways.

Parameters

array $gateways

at line 66
public addGateway(string $identifier, StorageGateway $gateway)

Adds a storage $gateway assigned to the given $identifier.

Parameters

string $identifier
StorageGateway $gateway

at line 115
public null|bool copyLegacyField(VersionInfo $versionInfo, Field $field, Field $originalField, array $context)

This method is used exclusively by Legacy Storage to copy external data of existing field in main language to the untranslatable field not passed in create or update struct, but created implicitly in storage layer.

By default the method falls back to the {@link \eZ\Publish\SPI\FieldType\FieldStorage::storeFieldData()}. External storages implement this method as needed.

Parameters

VersionInfo $versionInfo
Field $field
Field $originalField
array $context

Return Value

null|bool Same as {@link \eZ\Publish\SPI\FieldType\FieldStorage::storeFieldData()}.