Commit Graph

388 Commits

Author SHA1 Message Date
Bernhard Schussek
708c780213 [Validator] Renamed @Validation constraint to @Set 2011-01-03 22:06:52 +01:00
Bernhard Schussek
52ecffe51b [Validator] Implemented Locale constraint 2011-01-02 10:41:09 +01:00
Jordi Boggiano
094d428e68 CS: Unified strict equality comparisons, put var on the right side 2010-12-21 08:51:21 +01:00
Bernhard Schussek
a059ec891d [Validator] Implemented Image constraint 2010-12-16 10:18:33 +01:00
Bernhard Schussek
993257a83e [Validator] Implemented Language constraint 2010-12-16 10:18:33 +01:00
Bernhard Schussek
fdb7f84c7d [Locale][Form][Validator] Refactored code to new Locale component, implemented Country constraint 2010-12-16 10:18:33 +01:00
Fabien Potencier
48e30537c4 added exception when a loaded YAML resource is not an array 2010-12-12 08:39:37 +01:00
Johannes Schmitt
cc3a783890 removed dead code 2010-12-10 16:34:20 +01:00
Bernhard Schussek
1b2ca259f1 [Validator] Fixed string-based constraint validators to accept empty values 2010-12-10 14:28:11 +01:00
Gustavo Falco
af291bb0f1 [Validator] Fixed UrlValidator to accept empty strings (closes #9297) 2010-12-10 14:28:07 +01:00
pablodip
984a857a96 [Validator] fixed the static method loader to not repeat the loading when the static method is in the parent classes 2010-12-10 14:27:49 +01:00
Bernhard Schussek
68cebd667a [Validator] Group sequences must now always contain the group "<ClassName>" and never the group "Default" since that group is redefined by the group sequence 2010-11-19 07:11:26 +01:00
Bernhard Schussek
a71cad480a [Validator] Added @validation:GroupSequence to annotation driver 2010-11-19 07:11:23 +01:00
Jordi Boggiano
e69c5ae860 Coding style fixes 2010-11-18 07:00:03 +01:00
Bernhard Schussek
46145d8de7 [Validator] Fixed exception thrown in Valid constraint to be thrown only when the options are not empty 2010-11-17 10:55:48 +01:00
Bernhard Schussek
940ce9aedf [Validator] Group "Default" is now propagated to validated references when group sequences are validated
This conforms to JSR303 (see version 1.0 final, page 39).
2010-11-17 08:02:10 +01:00
Bernhard Schussek
6a148465da [Validator][Form] Removed support for match-all group "*"
The constraint "Valid" does not accept any options or groups anymore. As per
JSR303 1.0 final, section 3.5.1 "Object graph validation" (page 39),
properties  annotated with valid should be cascaded independent of the current
group (i.e. always). Thus the group "*" is not necessary anymore and was
removed from the "Valid" constraint in the Form validation.xml.
2010-11-17 08:02:06 +01:00
Bernhard Schussek
8df966f507 [Validator] Made class Constraint abstract because it must not be instantiated 2010-11-17 08:02:03 +01:00
Benjamin Eberlei
5aeb358721 [Validator] Made the namespace prefix for annotations configurable
Modified the framework bundle to use validation => Symfony\Component\Validator\Validator defaults.
Enhanced Framework Extension validator configuration to allow to extend this configuration with
user-specified annotations, for example:

    validation:
        enabled: true
        annotations:
            namespaces:
                myprojectvalidator: MyProject\Validator\

to register @myprojectvalidator:Validator(...)
2010-11-16 07:28:02 +01:00
jeff
69cd21d8be [Validator] Fixed annotation loader to not add parent constraints twice 2010-11-12 17:56:09 +01:00
ever.zet
4c340c5cc9 [Form] fixed forms grouped validation
Added ability to specify **match-all** validation group, which
constraints will runs on every specified validation group.
Added groups="*" option to `Form::data` Valid validator.
2010-11-12 17:53:17 +01:00
Kris Wallsmith
4a18624927 [Validator] removed ftp and ftps from default url protocols 2010-10-18 16:57:07 +02:00
pborreli
082090d880 [Validator] Fixed coding standard 2010-10-16 10:49:41 +02:00
Kris Wallsmith
5d4c80f27b [Validator] removed DependencyInjection integration 2010-10-16 08:34:36 +02:00
Fabien Potencier
0fc8906feb [Validator] forced all validation annotations to be in the validation namespace to avoid collisions, removed the need for the wrapping @Validation annotation
Before:

    /**
     * @Validation({@DateTime()})
     */

After:

    /**
     * @validation:DateTime()
     */

The @validation:Validation() construct is not needed anymore (it is still supported
as this is useful when you have several annotations with the same class).

So, the above is equivalent to:

    /**
     * @validation:Validation({@validation:DateTime()})
     */
2010-10-02 15:07:00 +02:00
Fabien Potencier
3a4d9cb185 [Validation] fixed license 2010-10-02 12:42:35 +02:00
Fabien Potencier
1a055fc7f0 [Validator] fixed typo 2010-09-30 07:21:54 +02:00
Fabien Potencier
3b1e83380b [Validator] removed the convention that error parameters are delimited with %% 2010-09-29 07:59:45 +02:00
Fabien Potencier
9580c74f0b [Validator] changed the convention for placeholders in messages to be compatible with Twig (from %limit% to {{ limit }}) 2010-09-27 09:46:56 +02:00
Fabien Potencier
866c306dc8 removed the message interpolator system in the Validator component (i18n management should be done globally, not in a specific component) 2010-09-24 16:41:28 +02:00
Jordi Boggiano
82f6a68eb2 [Validator] Allow DateTime objects as valid DateTimes 2010-09-22 09:16:26 +02:00
Jeremy Mikola
a86bac44ce [Validator] Remove leading '@' when validating email domain MX record 2010-09-10 20:42:22 +02:00
Fabien Potencier
a141c98917 [HttpFoundation] moved File Component into the HttpFoundation one 2010-09-09 17:01:48 +02:00
Fabien Potencier
fc9325a737 fixed file upload 2010-09-09 16:07:12 +02:00
Bulat Shakirzyanov
bb51e7cb26 [Validator] fixed Xliff loader to use forward slashes in file path 2010-09-09 08:01:46 +02:00
Fabien Potencier
4d669d106e [Validator] changed Xliff loader to get XSD locally 2010-09-07 14:30:50 +02:00
Fabien Potencier
dadfaa271f [Validator] fixed indentation 2010-09-07 14:18:00 +02:00
Fabien Potencier
bf82cf42dd renamed Symfony\Components to Symfony\Component 2010-08-20 23:09:55 +02:00