class DefaultFilenameMapper implements FilenameMapperInterface (View source)

Default file name mapper.

Traits

SingletonTrait

Constants

SAFE_IDENTIFIER_PATTERN

Safe character list.

If the identifier exclusively contains those character, the file name will corresponds to the identifier.

Methods

string|array
getIdentifier(string $basename)

Get object identifier from a file system base file name

string
getBasename(string|array $identifier)

Get the file base name for the given object identifier

Details

string|array getIdentifier(string $basename)

Get object identifier from a file system base file name

Parameters

string $basename Filesystem base name.

Return Value

string|array Object identifier

See also

FilenameMapperInterface::getIdentifier

string getBasename(string|array $identifier)

Get the file base name for the given object identifier

Parameters

string|array $identifier Identifier to transform to a file system base file name

Return Value

string Filesystem base file name corresponding to the given identifier.

See also

FilenameMapperInterface::getBasename