TokenCollection
class TokenCollection
Methods
No description
Merges the passed TokenCollection into this collection. If the token already exists the tokens will be merged.
Merges an array with multiple TokenCollections into this collection
Sets the passed domain for all Tokens in this collection
Details
at line 12
__construct()
No description
at line 21
add(Token $newToken)
Adds a Token object to this collection. If the token already exists the token will be merged with the existing one
at line 91
bool
exists(Token $token, string[] $requiredLanguages = false)
Returns true if the passed Token object exists. If a requiredLanguage is passed the token must also have a matching translation set
at line 36
Token
get(string $tokenId)
Returns the Token for the passed Token ID
at line 57
Token[]
getTokens()
Returns an array with all token objects in this collection
at line 66
$this
merge(TokenCollection $collection)
Merges the passed TokenCollection into this collection. If the token already exists the tokens will be merged.
at line 78
$this
mergeMany(array $collections)
Merges an array with multiple TokenCollections into this collection
at line 44
setDomain(string $domain)
Sets the passed domain for all Tokens in this collection