FluidTemplateCache extends PhpFrontend implements FluidCacheInterface
Class FluidTemplateCache
Connector class that enables the TYPO3 cache called "fluid_template" to be operated with the interface appropriate for the Fluid engine.
Table of Contents
Interfaces
- FluidCacheInterface
Properties
- $backend : BackendInterface|TaggableBackendInterface
- $identifier : string
- Identifies this cache
Methods
- __construct() : mixed
- Constructs the cache
- collectGarbage() : mixed
- Does garbage collection
- flush() : mixed
- Removes all cache entries of this cache.
- flushByTag() : mixed
- Removes all cache entries of this cache which are tagged by the specified tag.
- flushByTags() : mixed
- Removes all cache entries of this cache which are tagged by any of the specified tags.
- get() : mixed
- Finds and returns a variable value from the cache.
- getBackend() : BackendInterface
- Returns the backend used by this cache
- getCacheWarmer() : FluidCacheWarmerInterface
- getIdentifier() : string
- Returns this cache's identifier
- has() : bool
- Checks if a cache entry with the specified identifier exists.
- isValidEntryIdentifier() : bool
- Checks the validity of an entry identifier. Returns TRUE if it's valid.
- isValidTag() : bool
- Checks the validity of a tag. Returns TRUE if it's valid.
- remove() : bool
- Removes the given cache entry from the cache.
- require() : mixed
- Loads PHP code from the cache and require() it right away. Note require() in comparison to requireOnce() is only "safe" if the cache entry only contain stuff that can be required multiple times during one request. For instance a class definition would fail here.
- requireOnce() : mixed
- Loads PHP code from the cache and require_onces it right away.
- set() : mixed
- Saves the PHP source code in the cache.
Properties
$backend
protected
BackendInterface|TaggableBackendInterface
$backend
$identifier
Identifies this cache
protected
string
$identifier
Methods
__construct()
Constructs the cache
public
__construct(string $identifier, PhpCapableBackendInterface $backend) : mixed
Parameters
- $identifier : string
-
An identifier which describes this cache
- $backend : PhpCapableBackendInterface
-
Backend to be used for this cache
collectGarbage()
Does garbage collection
public
collectGarbage() : mixed
flush()
Removes all cache entries of this cache.
public
flush([null $name = null ]) : mixed
Parameters
- $name : null = null
flushByTag()
Removes all cache entries of this cache which are tagged by the specified tag.
public
flushByTag(string $tag) : mixed
Parameters
- $tag : string
-
The tag the entries must have
Tags
flushByTags()
Removes all cache entries of this cache which are tagged by any of the specified tags.
public
flushByTags(array<string|int, string> $tags) : mixed
Parameters
- $tags : array<string|int, string>
Tags
get()
Finds and returns a variable value from the cache.
public
get(string $entryIdentifier) : mixed
Parameters
- $entryIdentifier : string
getBackend()
Returns the backend used by this cache
public
getBackend() : BackendInterface
Return values
BackendInterface —The backend used by this cache
getCacheWarmer()
public
getCacheWarmer() : FluidCacheWarmerInterface
Return values
FluidCacheWarmerInterfacegetIdentifier()
Returns this cache's identifier
public
getIdentifier() : string
Return values
string —The identifier for this cache
has()
Checks if a cache entry with the specified identifier exists.
public
has(string $entryIdentifier) : bool
Parameters
- $entryIdentifier : string
-
An identifier specifying the cache entry
Tags
Return values
bool —TRUE if such an entry exists, FALSE if not
isValidEntryIdentifier()
Checks the validity of an entry identifier. Returns TRUE if it's valid.
public
isValidEntryIdentifier(string $identifier) : bool
Parameters
- $identifier : string
-
An identifier to be checked for validity
Return values
boolisValidTag()
Checks the validity of a tag. Returns TRUE if it's valid.
public
isValidTag(string|array<string|int, mixed> $tag) : bool
Parameters
- $tag : string|array<string|int, mixed>
-
An identifier to be checked for validity
Return values
boolremove()
Removes the given cache entry from the cache.
public
remove(string $entryIdentifier) : bool
Parameters
- $entryIdentifier : string
-
An identifier specifying the cache entry
Tags
Return values
bool —TRUE if such an entry exists, FALSE if not
require()
Loads PHP code from the cache and require() it right away. Note require() in comparison to requireOnce() is only "safe" if the cache entry only contain stuff that can be required multiple times during one request. For instance a class definition would fail here.
public
require(string $entryIdentifier) : mixed
Parameters
- $entryIdentifier : string
-
An identifier which describes the cache entry to load
Return values
mixed —Potential return value from the include operation
requireOnce()
Loads PHP code from the cache and require_onces it right away.
public
requireOnce(string $entryIdentifier) : mixed
Parameters
- $entryIdentifier : string
-
An identifier which describes the cache entry to load
Return values
mixed —Potential return value from the include operation
set()
Saves the PHP source code in the cache.
public
set(string $entryIdentifier, string $sourceCode[, array<string|int, mixed> $tags = [] ][, int $lifetime = null ]) : mixed
Parameters
- $entryIdentifier : string
- $sourceCode : string
- $tags : array<string|int, mixed> = []
- $lifetime : int = null