Package de.codecamp.messages
Annotation Type Messages
-
@Target({TYPE,FIELD,METHOD}) @Retention(RUNTIME) @Documented public @interface Messages
This annotation is used to declare message keys on types, fields or methods and can also be used as a meta-annotation.
-
-
Field Summary
Fields Modifier and Type Fields Description static StringPREFIX_SOURCE_TYPE
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description booleanforPropertiesReturns whether message keys for all bean properties of the annotated type should be created.booleanforTypeReturns whether a message key for the annotated type should be created.booleanignoreImplicitReturns whether the annotated element should be ignored for the implicit generation of message keys.String[]keys(Additional) Message keys.StringprefixThe prefix to be used for message keys.String[]value(Additional) Message keys.
-
-
-
Field Detail
-
PREFIX_SOURCE_TYPE
static final String PREFIX_SOURCE_TYPE
-
-
-
ignoreImplicit
boolean ignoreImplicit
Returns whether the annotated element should be ignored for the implicit generation of message keys. E.g. properties (represented by the associated getter) and enum elements annotated withignoreImplicit = truewill be ignored. However, explicitly provided message keys on that element will still be processed!- Returns:
- whether the annotated element should be ignored for the implicit generation of message keys
- Default:
- false
-
-
-
prefix
String prefix
The prefix to be used for message keys. The default is to use the fully qualified name of the source type followed by a period (.). The prefix should usually not be changed, but sometimes it may be necessary to declare very specific message keys. The prefix can only be set at the type level.- Returns:
- prefix to be used for message keys
- Default:
- "__SOURCE_TYPE__"
-
-