Symfony\Component\Validator\GlobalExecutionContextInterface
Stores the node-independent state of a validation run.
When the validator validates a graph of objects, it uses two classes to
store the state during the validation:
<ul>
<li>For each node in the validation graph (objects, properties, getters) the
validator creates an instance of that
stores the information about that node.</li>
<li>One single <tt>GlobalExecutionContextInterface</tt> stores the state
that is independent of the current node.</li>
</ul>
- Author: Bernhard Schussek <bschussek@gmail.com>
Synopsis
interface GlobalExecutionContextInterface
{
- // methods
- public ConstraintViolationListInterface getViolations()
- public mixed getRoot()
- public ValidationVisitorInterface getVisitor()
- public ConstraintValidatorFactoryInterface getValidatorFactory()
- public MetadataFactoryInterface getMetadataFactory()
Methods
public
- getMetadataFactory() — Returns the factory for validation metadata objects.
- getRoot() — Returns the value at which validation was started in the object graph.
- getValidatorFactory() — Returns the factory for constraint validators.
- getViolations() — Returns the violations generated by the validator so far.
- getVisitor() — Returns the visitor instance used to validate the object graph nodes.