LanguageProviderInterface

Extends

Interface LanguageProviderInterface

category

System

package

Shared

subpackage

Interfaces

Methods

Returns the active language codes.

getActiveCodes() : \KeyValueCollection
Throws
\InvalidArgumentException

If code is not valid.

Response

\KeyValueCollection

Returns the charset from the a specific language, selected by the language code.

getCharsetByCode(\LanguageCode $code) : string
Throws
\UnexpectedValueException

If no directory has been found.

Arguments

$code

\LanguageCode

Language code.

Response

string

Returns the charset from the a specific language, selected by the language ID.

getCharsetById(\IdType $id) : string
Throws
\UnexpectedValueException

If no charset has been found.

Arguments

$id

\IdType

Language ID.

Response

string

Returns the language code from a specific language, selected by the language ID.

getCodeById(\IdType $id) : \LanguageCode
Throws
\UnexpectedValueException

If no code has been found.

\InvalidArgumentException

If code is not valid.

Arguments

$id

\IdType

Language ID.

Response

\LanguageCode

Returns the language codes.

getCodes() : \KeyValueCollection
Throws
\UnexpectedValueException

If no code has been found.

\InvalidArgumentException

If code is not valid.

Response

\KeyValueCollection

Returns the default language code.

getDefaultLanguageCode() : string
Throws
\InvalidArgumentException

If no default code exists.

Response

string

Returns the default language ID.

getDefaultLanguageId() : integer
Throws
\InvalidArgumentException

If no default code exists.

Response

integer

Returns the directory from the a specific language, selected by the language code.

getDirectoryByCode(\LanguageCode $code) : string
Throws
\UnexpectedValueException

If no directory has been found.

Arguments

$code

\LanguageCode

Language code.

Response

string

Returns the directory from the a specific language, selected by the language ID.

getDirectoryById(\IdType $id) : string
Throws
\UnexpectedValueException

If no directory has been found.

\InvalidArgumentException

If code is not valid.

Arguments

$id

\IdType

Language ID.

Response

string

Returns the icon for a specific language by a given language code.

getIconFilenameByCode(\LanguageCode $code) : string
Throws
\UnexpectedValueException

If no icon has been found.

Arguments

$code

\LanguageCode

The given language code

Response

string

Returns the ID from the a specific language, selected by the language code.

getIdByCode(\LanguageCode $code) : integer
Throws
\UnexpectedValueException

If no ID has been found.

Arguments

$code

\LanguageCode

Language code.

Response

integer

Returns the language IDs.

getIds() : \IdCollection
Throws
\UnexpectedValueException

If no ID has been found.

\InvalidArgumentException

If ID is not valid.

Response

\IdCollection