Package javax.validation.constraints

# Annotation Interface Pattern

@Target({METHOD,FIELD,ANNOTATION_TYPE,CONSTRUCTOR,PARAMETER}) @Retention(RUNTIME) @Documented @Constraint(validatedBy={}) public @interface Pattern
Constraint to verify that the validated field, parameter, etc matches the given regexp pattern. The pattern format is as specified in `Pattern`.

Version:
  $Rev$ $Date$

## Nested Class Summary

Nested Classes
Modifier and Type
Class
Description
`static enum`
`Pattern.Flag`
`static @interface`
`Pattern.List`

## Required Element Summary

Required Elements
Modifier and Type
Required Element
Description
`String`
`regexp`

## Optional Element Summary

Optional Elements
Modifier and Type
Optional Element
Description
`Pattern.Flag[]`
`flags`
`Class<?>[]`
`groups`
`String`
`message`
`Class<? extends Payload>[]`
`payload`

## Element Details

### regexp

String regexp

### flags

Pattern.Flag[] flags

Default:
  `{}`

### message

String message

Default:
  `"{javax.validation.constraints.Pattern.message}"`

### groups

Class<?>[] groups

Default:
  `{}`

### payload

Class<? extends Payload>[] payload

Default:
  `{}`