PHP Class eZ\Publish\Core\Persistence\Legacy\Content\Language\CachingHandler

Inheritance: implements eZ\Publish\SPI\Persistence\Content\Language\Handler
Exibir arquivo Open project: ezsystems/ezpublish-kernel Class Usage Examples

Protected Properties

Property Type Description
$innerHandler Handler Inner Language handler.
$isCacheInitialized boolean If the cache has already been initialized.
$languageCache Cache Language cache.

Public Methods

Method Description
__construct ( eZ\Publish\SPI\Persistence\Content\Language\Handler $innerHandler, Cache $languageCache ) Creates a caching handler around $innerHandler.
clearCache ( ) Clear internal cache.
create ( eZ\Publish\SPI\Persistence\Content\Language\CreateStruct $struct ) : eZ\Publish\SPI\Persistence\Content\Language Create a new language.
delete ( mixed $id ) Delete a language.
load ( mixed $id ) : eZ\Publish\SPI\Persistence\Content\Language Get language by id.
loadAll ( ) : eZ\Publish\SPI\Persistence\Content\Language[] Get all languages.
loadByLanguageCode ( string $languageCode ) : eZ\Publish\SPI\Persistence\Content\Language Get language by Language Code (eg: eng-GB).
update ( eZ\Publish\SPI\Persistence\Content\Language $language ) Update language.

Protected Methods

Method Description
initializeCache ( ) Initializes the cache if necessary.

Method Details

__construct() public method

Creates a caching handler around $innerHandler.
public __construct ( eZ\Publish\SPI\Persistence\Content\Language\Handler $innerHandler, Cache $languageCache )
$innerHandler eZ\Publish\SPI\Persistence\Content\Language\Handler
$languageCache Cache

clearCache() public method

Clear internal cache.
public clearCache ( )

create() public method

Create a new language.
public create ( eZ\Publish\SPI\Persistence\Content\Language\CreateStruct $struct ) : eZ\Publish\SPI\Persistence\Content\Language
$struct eZ\Publish\SPI\Persistence\Content\Language\CreateStruct
return eZ\Publish\SPI\Persistence\Content\Language

delete() public method

Delete a language.
public delete ( mixed $id )
$id mixed

initializeCache() protected method

Initializes the cache if necessary.
protected initializeCache ( )

load() public method

Get language by id.
public load ( mixed $id ) : eZ\Publish\SPI\Persistence\Content\Language
$id mixed
return eZ\Publish\SPI\Persistence\Content\Language

loadAll() public method

Get all languages.
public loadAll ( ) : eZ\Publish\SPI\Persistence\Content\Language[]
return eZ\Publish\SPI\Persistence\Content\Language[]

loadByLanguageCode() public method

Get language by Language Code (eg: eng-GB).
public loadByLanguageCode ( string $languageCode ) : eZ\Publish\SPI\Persistence\Content\Language
$languageCode string
return eZ\Publish\SPI\Persistence\Content\Language

update() public method

Update language.
public update ( eZ\Publish\SPI\Persistence\Content\Language $language )
$language eZ\Publish\SPI\Persistence\Content\Language

Property Details

$innerHandler protected_oe property

Inner Language handler.
protected Handler,eZ\Publish\Core\Persistence\Legacy\Content\Language $innerHandler
return Handler

$isCacheInitialized protected_oe property

If the cache has already been initialized.
protected bool $isCacheInitialized
return boolean

$languageCache protected_oe property

Language cache.
protected Cache,eZ\Publish\Core\Persistence\Legacy\Content\Language $languageCache
return Cache