CoolCMS API

ParameterRuleConditionValidator extends ParameterRuleConditionValidator
in package

API Parameter Rule Condition Validator

TODO: This class is currently just a pass-through to the Core validator. TODO: During presenter/component refactoring, eliminate this wrapper and use Core validator directly. TODO: If API-specific functionality is needed, add it here. Otherwise, remove this class entirely.

Table of Contents

Constants

ALL_IN  : mixed = ':all_in'
BLANK  : mixed = ':blank'
EMAIL  : mixed = ':email'
EQUAL  : mixed = ':equal'
FILLED  : mixed = ':filled'
FLOAT  : mixed = ':float'
IMAGE  : mixed = ':image'
INTEGER  : mixed = ':integer'
LENGTH  : mixed = ':length'
MAX  : mixed = ':max'
MAX_FILE_SIZE  : mixed = ':fileSize'
MAX_LENGTH  : mixed = ':maxLength'
MIME_TYPE  : mixed = ':mimeType'
MIN  : mixed = ':min'
MIN_LENGTH  : mixed = ':minLength'
NOT_EQUAL  : mixed = ':notEqual'
NUMERIC  : mixed = ':numeric'
PATTERN  : mixed = ':pattern'
PATTERN_ICASE  : mixed = ':patternCaseInsensitive'
RANGE  : mixed = ':range'
URL  : mixed = ':url'
VALIDATORS  : mixed = [self::ALL_IN => ['ALL_IN', true, true, true],...
Validator configurations Format: [name, showOptions, showValue, useAsArray]

Methods

getAllValidators()  : array<string, array{0: string, 1: bool, 2: bool, 3: bool}>
Get all available validators
getValidator()  : array{0: string, 1: bool, 2: bool, 3: bool}|null
Get validator configuration
getValidatorName()  : string|null
Get validator name for display
showsOptions()  : bool
Check if validator shows options
showsValue()  : bool
Check if validator shows value field
usesArray()  : bool
Check if validator uses array values

Constants

VALIDATORS

Validator configurations Format: [name, showOptions, showValue, useAsArray]

public mixed VALIDATORS = [self::ALL_IN => ['ALL_IN', true, true, true], self::EQUAL => ['EQUAL', true, true, true], self::NOT_EQUAL => ['NOT_EQUAL', true, true, true], self::FILLED => ['FILLED', false, false, false], self::BLANK => ['BLANK', false, false, false], self::MIN_LENGTH => ['MIN_LENGTH', false, true, false], self::MAX_LENGTH => ['MAX_LENGTH', false, true, false], self::LENGTH => ['LENGTH', false, true, false], self::EMAIL => ['EMAIL', false, false, false], self::URL => ['URL', false, false, false], self::PATTERN => ['PATTERN', false, true, false], self::PATTERN_ICASE => ['PATTERN_ICASE', false, true, false], self::INTEGER => ['INTEGER', false, false, false], self::NUMERIC => ['NUMERIC', false, false, false], self::FLOAT => ['FLOAT', false, false, false], self::MIN => ['MIN', false, true, false], self::MAX => ['MAX', false, true, false], self::RANGE => ['RANGE', false, true, true], self::MAX_FILE_SIZE => ['MAX_FILE_SIZE', false, true, false], self::MIME_TYPE => ['MIME_TYPE', false, true, true], self::IMAGE => ['IMAGE', false, false, false]]

Methods

getAllValidators()

Get all available validators

public static getAllValidators() : array<string, array{0: string, 1: bool, 2: bool, 3: bool}>
Return values
array<string, array{0: string, 1: bool, 2: bool, 3: bool}>

getValidator()

Get validator configuration

public static getValidator(string $validator) : array{0: string, 1: bool, 2: bool, 3: bool}|null
Parameters
$validator : string
Return values
array{0: string, 1: bool, 2: bool, 3: bool}|null —

[name, showOptions, showValue, useAsArray]

getValidatorName()

Get validator name for display

public static getValidatorName(string $validator) : string|null
Parameters
$validator : string
Return values
string|null

showsOptions()

Check if validator shows options

public static showsOptions(string $validator) : bool
Parameters
$validator : string
Return values
bool

showsValue()

Check if validator shows value field

public static showsValue(string $validator) : bool
Parameters
$validator : string
Return values
bool

usesArray()

Check if validator uses array values

public static usesArray(string $validator) : bool
Parameters
$validator : string
Return values
bool
On this page

Search results