TcfVendorConfiguration
in package
Uses
UtilsProvider
Register TCF vendor configuration custom post type.
Table of Contents
Constants
- CPT_NAME = 'rcb-tcf-vendor-conf'
- META_KEYS = [\DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::META_NAME_VENDOR_ID, \DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::META_NAME_RESTRICTIVE_PURPOSES, \DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::META_NAME_DATA_PROCESSING_IN_COUNTRIES, \DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::META_NAME_DATA_PROCESSING_IN_COUNTRIES_SPECIAL_TREATMENTS]
- META_NAME_DATA_PROCESSING_IN_COUNTRIES = \DevOwl\RealCookieBanner\settings\Cookie::META_NAME_DATA_PROCESSING_IN_COUNTRIES
- META_NAME_DATA_PROCESSING_IN_COUNTRIES_SPECIAL_TREATMENTS = \DevOwl\RealCookieBanner\settings\Cookie::META_NAME_DATA_PROCESSING_IN_COUNTRIES_SPECIAL_TREATMENTS
- META_NAME_RESTRICTIVE_PURPOSES = 'restrictivePurposes'
- META_NAME_VENDOR_ID = 'vendorId'
- SYNC_OPTIONS = ['meta' => ['copy' => \DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::SYNC_OPTIONS_COPY_AND_COPY_ONCE, 'copy-once' => \DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::SYNC_OPTIONS_COPY_AND_COPY_ONCE]]
- SYNC_OPTIONS_COPY_AND_COPY_ONCE = [\DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::META_NAME_VENDOR_ID, \DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::META_NAME_RESTRICTIVE_PURPOSES, \DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::META_NAME_DATA_PROCESSING_IN_COUNTRIES, \DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::META_NAME_DATA_PROCESSING_IN_COUNTRIES_SPECIAL_TREATMENTS]
Properties
- $cacheGetOrdered : mixed
- $me : TcfVendorConfiguration
- Singleton instance.
Methods
- getAllCount() : int
- Get a total count of all TCF vendor configurations.
- getInstance() : mixed
- Get singleton instance.
- getOrdered() : array<string|int, WP_Post>|WP_Error
- Get all available configurations ordered.
- getPluginConstantPrefix() : string
- Get the prefix of this plugin so composer packages can dynamically build other constant values on it.
- modify_search_query_where() : mixed
- When using `WP_Query` with a search term `s` and search for e.g. "Google", it does not return any vendor configurations as the vendor name is not e.g. the post title. This hooks into the SQL `WHERE` statement and searches vendors by name.
- register() : mixed
- Register custom post type.
- __construct() : mixed
- C'tor.
Constants
CPT_NAME
public
mixed
CPT_NAME
= 'rcb-tcf-vendor-conf'
META_KEYS
public
mixed
META_KEYS
= [\DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::META_NAME_VENDOR_ID, \DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::META_NAME_RESTRICTIVE_PURPOSES, \DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::META_NAME_DATA_PROCESSING_IN_COUNTRIES, \DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::META_NAME_DATA_PROCESSING_IN_COUNTRIES_SPECIAL_TREATMENTS]
META_NAME_DATA_PROCESSING_IN_COUNTRIES
public
mixed
META_NAME_DATA_PROCESSING_IN_COUNTRIES
= \DevOwl\RealCookieBanner\settings\Cookie::META_NAME_DATA_PROCESSING_IN_COUNTRIES
META_NAME_DATA_PROCESSING_IN_COUNTRIES_SPECIAL_TREATMENTS
public
mixed
META_NAME_DATA_PROCESSING_IN_COUNTRIES_SPECIAL_TREATMENTS
= \DevOwl\RealCookieBanner\settings\Cookie::META_NAME_DATA_PROCESSING_IN_COUNTRIES_SPECIAL_TREATMENTS
META_NAME_RESTRICTIVE_PURPOSES
public
mixed
META_NAME_RESTRICTIVE_PURPOSES
= 'restrictivePurposes'
META_NAME_VENDOR_ID
public
mixed
META_NAME_VENDOR_ID
= 'vendorId'
SYNC_OPTIONS
public
mixed
SYNC_OPTIONS
= ['meta' => ['copy' => \DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::SYNC_OPTIONS_COPY_AND_COPY_ONCE, 'copy-once' => \DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::SYNC_OPTIONS_COPY_AND_COPY_ONCE]]
SYNC_OPTIONS_COPY_AND_COPY_ONCE
public
mixed
SYNC_OPTIONS_COPY_AND_COPY_ONCE
= [\DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::META_NAME_VENDOR_ID, \DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::META_NAME_RESTRICTIVE_PURPOSES, \DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::META_NAME_DATA_PROCESSING_IN_COUNTRIES, \DevOwl\RealCookieBanner\lite\settings\TcfVendorConfiguration::META_NAME_DATA_PROCESSING_IN_COUNTRIES_SPECIAL_TREATMENTS]
Properties
$cacheGetOrdered
private
mixed
$cacheGetOrdered
= []
$me
Singleton instance.
private
static TcfVendorConfiguration
$me
= null
Methods
getAllCount()
Get a total count of all TCF vendor configurations.
public
getAllCount() : int
Return values
intgetInstance()
Get singleton instance.
public
static getInstance() : mixed
Tags
getOrdered()
Get all available configurations ordered.
public
getOrdered([bool $force = false ][, array<string|int, WP_Post> $usePosts = null ]) : array<string|int, WP_Post>|WP_Error
Parameters
- $force : bool = false
- $usePosts : array<string|int, WP_Post> = null
-
If set, only meta is applied to the passed posts
Return values
array<string|int, WP_Post>|WP_ErrorgetPluginConstantPrefix()
Get the prefix of this plugin so composer packages can dynamically build other constant values on it.
public
getPluginConstantPrefix() : string
Tags
Return values
stringmodify_search_query_where()
When using `WP_Query` with a search term `s` and search for e.g. "Google", it does not return any vendor configurations as the vendor name is not e.g. the post title. This hooks into the SQL `WHERE` statement and searches vendors by name.
public
modify_search_query_where(array<string|int, string> $clauses, WP_Query $query) : mixed
Parameters
- $clauses : array<string|int, string>
- $query : WP_Query
register()
Register custom post type.
public
register() : mixed
__construct()
C'tor.
private
__construct() : mixed