public static class Formats.AnnotationNonEmptyFormatter extends Formatters.AnnotationFormatter<Formats.NonEmpty,java.lang.String>
@NonEmpty
annotation.Constructor and Description |
---|
AnnotationNonEmptyFormatter() |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
parse(Formats.NonEmpty annotation,
java.lang.String text,
java.util.Locale locale)
Binds the field - constructs a concrete value from submitted data.
|
java.lang.String |
print(Formats.NonEmpty annotation,
java.lang.String value,
java.util.Locale locale)
Unbinds this field - converts a concrete value to plain string
|
public java.lang.String parse(Formats.NonEmpty annotation, java.lang.String text, java.util.Locale locale) throws java.text.ParseException
parse
in class Formatters.AnnotationFormatter<Formats.NonEmpty,java.lang.String>
annotation
- the annotation that trigerred this formattertext
- the field textlocale
- the current Locale
java.text.ParseException
- when the text could not be parsedpublic java.lang.String print(Formats.NonEmpty annotation, java.lang.String value, java.util.Locale locale)
print
in class Formatters.AnnotationFormatter<Formats.NonEmpty,java.lang.String>
annotation
- the annotation that trigerred this formattervalue
- the value to unbindlocale
- the current Locale