Skip to content

AndoperatorValidator

ANDOperatorValidator only succeeds if all sub-validators succeeded Parameters: ‘skip_errors’ do not submit errors of child validators to validator manager ‘break’ break the execution of child validators after first failure

class AndoperatorValidator extends OperatorValidator

ExtendsOperatorValidator
Since1.0.0
SourceValidator/AndoperatorValidator.php
MethodDescription
getAcceptedParameters(): array<int, string>Returns the base and OperatorValidator parameters plus ‘break’.
reset(): voidReturns the operator to its initial state for reuse across requests.

public static function getAcceptedParameters(): array<int, string>

Returns the base and OperatorValidator parameters plus ‘break’.

‘break’ stops the group at the first failing child instead of running the remaining ones; a CRITICAL child result breaks out regardless of it. ‘skip_errors’ comes from OperatorValidator.

Returns array``<``int``, ``string``> — The accepted parameter names.

public function reset(): void

Returns the operator to its initial state for reuse across requests.

Delegates to OperatorValidator::reset(), which resets and detaches the children, then puts the accumulated result back to SUCCESS.

These come from an ancestor and are documented where they are declared.

MethodDeclared inDescription
addArgumentResult()OperatorValidatorAdds a intermediate result of an validator for the given argument.
addChild()OperatorValidatorAdds new child validator.
addFieldResult()OperatorValidatorAdds a validation result for a given field.
addIncident()OperatorValidatorAdds an incident to the validation result.
appendParameter()ParameterHolderAppend a parameter.
appendParameterByRef()ParameterHolderAppend a parameter by reference.
clearParameters()ParameterHolderClear all parameters associated with this request.
execute()OperatorValidatorExecutes the validator.
getArguments()ValidatorReturns all arguments which should be validated.
getBase()ValidatorReturns the base path of this validator.
getBaseKeys()ValidatorReturns the “keys” in the path of the base
getChild()OperatorValidatorReturns a named child validator.
getChilds()OperatorValidatorReturns all child validators.
getContext()ValidatorRetrieve the current application context.
getDependencyManager()OperatorValidatorGets parent’s dependency manager.
getFlatParameterNames()ParameterHolderRetrieve an array of flattened parameter names.
getLastKey()ValidatorReturns the last “keys” in the path of the base
getMutatedRequest()ValidatorThe WebRequest this validator ended execute() with.
getName()ValidatorReturns the name of this validator.
getParameter()ParameterHolderRetrieve a parameter.
getParameterNames()ParameterHolderRetrieve an array of parameter names.
getParameters()ParameterHolderRetrieve an array of parameters.
getParentContainer()ValidatorRetrieve the parent container.
getResult()OperatorValidatorReturns the result from the error manager.
hasParameter()ParameterHolderIndicates whether or not a parameter exists.
initialize()ValidatorInitialize this validator.
mapErrorCode()ValidatorConverts string severity codes into integer values (see severity constants) critical -> Validator::CRITICAL error -> Validator::ERROR notice -> Validator::NOTICE none -> Validator::NONE success -> not allowed to be specified by the user.
registerValidators()OperatorValidatorRegisters an array of validators.
removeParameter()ParameterHolderRemove a parameter.
setErrorMessage()ValidatorSets an error message override for the given index (the empty string is the default/generic message).
setParameter()ParameterHolderSet a parameter.
setParameterByRef()ParameterHolderSet a parameter by reference.
setParameters()ParameterHolderSet an array of parameters.
setParametersByRef()ParameterHolderSet an array of parameters by reference.
setParentContainer()ValidatorSets the parent container.
shutdown()OperatorValidatorShutdown method, for shutting down the model etc.