ninja.validation
Annotation Type Required


@Retention(value=RUNTIME)
@Target(value=PARAMETER)
public @interface Required

Validates that the length of the field meets the given length constraints

Author:
James Roper

Optional Element Summary
 String fieldKey
          The key for formatting the field
 String key
          The key for the violation message
 String message
          Default message if the key isn't found
 

key

public abstract String key
The key for the violation message

Returns:
The key of the violation message
Default:
"validation.required.violation"

message

public abstract String message
Default message if the key isn't found

Returns:
The default message
Default:
"{0} is required"

fieldKey

public abstract String fieldKey
The key for formatting the field

Returns:
The key
Default:
""


Copyright © 2012. All Rights Reserved.