platform/api/symfony/Component/Validator/Constraints/Regex.yaml

78 lines
3.1 KiB
YAML
Raw Normal View History

2024-09-02 17:44:11 +00:00
name: Regex
class_comment: null
dependencies:
- name: Constraint
type: class
source: Symfony\Component\Validator\Constraint
- name: InvalidArgumentException
type: class
source: Symfony\Component\Validator\Exception\InvalidArgumentException
properties:
- name: normalizer
visibility: public
comment: "# * Validates that a value matches a regular expression.\n# *\n# * @author\
\ Bernhard Schussek <bschussek@gmail.com>\n# */\n# #[\\Attribute(\\Attribute::TARGET_PROPERTY\
\ | \\Attribute::TARGET_METHOD | \\Attribute::IS_REPEATABLE)]\n# class Regex extends\
\ Constraint\n# {\n# public const REGEX_FAILED_ERROR = 'de1e3db3-5ed4-4941-aae4-59f3667cc3a3';\n\
# \n# protected const ERROR_NAMES = [\n# self::REGEX_FAILED_ERROR => 'REGEX_FAILED_ERROR',\n\
# ];\n# \n# public string $message = 'This value is not valid.';\n# public ?string\
\ $pattern = null;\n# public ?string $htmlPattern = null;\n# public bool $match\
\ = true;\n# /** @var callable|null"
methods:
- name: __construct
visibility: public
parameters:
- name: pattern
- name: message
default: 'null'
- name: htmlPattern
default: 'null'
- name: match
default: 'null'
- name: normalizer
default: 'null'
- name: groups
default: 'null'
- name: payload
default: 'null'
- name: options
default: '[]'
comment: "# * Validates that a value matches a regular expression.\n# *\n# * @author\
\ Bernhard Schussek <bschussek@gmail.com>\n# */\n# #[\\Attribute(\\Attribute::TARGET_PROPERTY\
\ | \\Attribute::TARGET_METHOD | \\Attribute::IS_REPEATABLE)]\n# class Regex extends\
\ Constraint\n# {\n# public const REGEX_FAILED_ERROR = 'de1e3db3-5ed4-4941-aae4-59f3667cc3a3';\n\
# \n# protected const ERROR_NAMES = [\n# self::REGEX_FAILED_ERROR => 'REGEX_FAILED_ERROR',\n\
# ];\n# \n# public string $message = 'This value is not valid.';\n# public ?string\
\ $pattern = null;\n# public ?string $htmlPattern = null;\n# public bool $match\
\ = true;\n# /** @var callable|null */\n# public $normalizer;\n# \n# /**\n# *\
\ @param string|array<string,mixed>|null $pattern The regular expression to\
\ match\n# * @param string|null $htmlPattern The pattern to\
\ use in the HTML5 pattern attribute\n# * @param bool|null \
\ $match Whether to validate the value matches the configured pattern\
\ or not (defaults to false)\n# * @param string[]|null $groups\n\
# * @param array<string,mixed> $options"
- name: getDefaultOption
visibility: public
parameters: []
comment: null
- name: getRequiredOptions
visibility: public
parameters: []
comment: null
- name: getHtmlPattern
visibility: public
parameters: []
comment: '# * Converts the htmlPattern to a suitable format for HTML5 pattern.
# * Example: /^[a-z]+$/ would be converted to [a-z]+
# * However, if options are specified, it cannot be converted.
# *
# * @see http://dev.w3.org/html5/spec/single-page.html#the-pattern-attribute'
traits:
- Symfony\Component\Validator\Constraint
- Symfony\Component\Validator\Exception\InvalidArgumentException
interfaces: []