Validation

class Validation Entry point for the Validator component. Methods static ValidatorInterface createValidator() Creates a new validator. static ValidatorBuilderInterface createValidatorBuilder() Creates a configurable builder for validator objects. Details static ValidatorInterface createValidator() Creates a new validator. If you want to configure the validator, use {@link createValidatorBuilder()} instead. Return Value ValidatorInterface

ValidateRequestListener::onKernelRequest()

onKernelRequest(GetResponseEvent $event) Performs the validation. Parameters GetResponseEvent $event

ValidateRequestListener::getSubscribedEvents()

static array getSubscribedEvents() Returns an array of event names this subscriber wants to listen to. The array keys are event names and the value can be: The method name to call (priority defaults to 0) An array composed of the method name to call and the priority An array of arrays composed of the method names to call and respective priorities, or 0 if unset For instance: array('eventName' => 'methodName') array('eventName' => array('methodName', $priority)) a

ValidateRequestListener

class ValidateRequestListener implements EventSubscriberInterface Validates that the headers and other information indicating the client IP address of a request are consistent. Methods onKernelRequest(GetResponseEvent $event) Performs the validation. static array getSubscribedEvents() Returns an array of event names this subscriber wants to listen to. Details onKernelRequest(GetResponseEvent $event) Performs the validation. Parameters G

Valid

class Valid extends Constraint Constants DEFAULT_GROUP The name of the group given to all constraints with no explicit group. CLASS_CONSTRAINT Marks a constraint that can be put onto classes. PROPERTY_CONSTRAINT Marks a constraint that can be put onto properties. Properties mixed $payload Domain-specific data attached to a constraint. from Constraint array $groups The groups that the constraint belongs to from Constraint $traverse Methods static string getErrorName(int

UuidValidator

class UuidValidator extends ConstraintValidator Validates whether the value is a valid UUID per RFC 4122. Constants PRETTY_DATE Whether to format {@link \DateTime} objects as RFC-3339 dates ("Y-m-d H:i:s"). OBJECT_TO_STRING Whether to cast objects with a "__toString()" method to strings. STRICT_LENGTH STRICT_FIRST_HYPHEN_POSITION STRICT_LAST_HYPHEN_POSITION STRICT_VERSION_POSITION STRICT_VARIANT_POSITION LOOSE_MAX_LENGTH LOOSE_FIRST_HYPHEN_POSITION Method

Uuid

class Uuid extends Constraint Constants DEFAULT_GROUP The name of the group given to all constraints with no explicit group. CLASS_CONSTRAINT Marks a constraint that can be put onto classes. PROPERTY_CONSTRAINT Marks a constraint that can be put onto properties. TOO_SHORT_ERROR TOO_LONG_ERROR INVALID_CHARACTERS_ERROR INVALID_HYPHEN_PLACEMENT_ERROR INVALID_VERSION_ERROR INVALID_VARIANT_ERROR V1_MAC V2_DCE V3_MD5 V4_RANDOM V5_SHA1 Propertie

UserSecurityIdentity::getUsername()

string getUsername() Returns the username Return Value string

UserSecurityIdentity::getClass()

string getClass() Returns the user's class name Return Value string

UserSecurityIdentity::fromToken()

static UserSecurityIdentity fromToken(TokenInterface $token) Creates a user security identity from a TokenInterface Parameters TokenInterface $token Return Value UserSecurityIdentity