AbstractGvlPersistance
in package
Additional to `AbstractTcf`, this abstract class provides persistence for the TCF GVL vendor list, e.g. by reading vendors, declarations and so on from the database.
Table of Contents
Methods
- allDeclarations() : mixed
- Query all available declaration of the latest GVL and TCF policy version for the current language. If the language does not exist for the current TCF version, let's fallback to the default TCF version.
- getCurrentLanguage() : string
- Get the language which is used for the GVL. It needs to be a two-letter ISO code, see also `self::fourLetterLanguageCodeToTwoLetterCode()`.
- getLatestVersions() : array<string|int, int>
- Get the latest GVL, TCF Policy and vendor list versions.
- stacks() : array<string|int, mixed>
- Query available stacks of the latest GVL and TCF policy version for the current language. If the language does not exist for the current TCF version, let's fallback to the default TCF version.
- vendors() : array<string|int, array<string|int, mixed>>
- Fetch a list of vendors by arguments and return an array of vendors matching the schema of the official `vendor-list.json`.
Methods
allDeclarations()
Query all available declaration of the latest GVL and TCF policy version for the current language. If the language does not exist for the current TCF version, let's fallback to the default TCF version.
public
abstract allDeclarations([array<string|int, mixed> $args = [] ]) : mixed
Additional arguments:
- [
onlyReturnDeclarations
]: (boolean) Default tofalse
, do not populategvlSpecificationVersion
, ...
Parameters
- $args : array<string|int, mixed> = []
-
Additional arguments, see description of
purposes
getCurrentLanguage()
Get the language which is used for the GVL. It needs to be a two-letter ISO code, see also `self::fourLetterLanguageCodeToTwoLetterCode()`.
public
abstract getCurrentLanguage() : string
Return values
stringgetLatestVersions()
Get the latest GVL, TCF Policy and vendor list versions.
public
abstract getLatestVersions() : array<string|int, int>
Return values
array<string|int, int>stacks()
Query available stacks of the latest GVL and TCF policy version for the current language. If the language does not exist for the current TCF version, let's fallback to the default TCF version.
public
abstract stacks([array<string|int, mixed> $args = [] ]) : array<string|int, mixed>
Arguments:
- [
gvlSpecificationVersion
]: (int) Default to latest - [
tcfPolicyVersion
]: (int) Default to latest - [
language
]: (string) Default to current
Parameters
- $args : array<string|int, mixed> = []
-
Additional arguments, see description
Return values
array<string|int, mixed>vendors()
Fetch a list of vendors by arguments and return an array of vendors matching the schema of the official `vendor-list.json`.
public
abstract vendors([array<string|int, mixed> $args = [] ]) : array<string|int, array<string|int, mixed>>
Arguments:
- [
in
]: (int[]) Only read this vendors (WHERE IN
) - [
gvlSpecificationVersion
]: (int) Default to latest - [
tcfPolicyVersion
]: (int) Default to latest - [
vendorListVersion
]: (int) Default to latest - [
language
]: (string) Default to current
Parameters
- $args : array<string|int, mixed> = []