Annotation Type PluginAttribute
@Documented
@Retention(RUNTIME)
@Target({PARAMETER,FIELD})
@PluginVisitorStrategy(PluginAttributeVisitor.class)
public @interface PluginAttribute
Identifies a Plugin Attribute and its default value. Note that only one of the defaultFoo attributes will be
used based on the type this annotation is attached to. Thus, for primitive types, the defaultType
attribute will be used for some Type. However, for more complex types (including enums), the default
string value is used instead and should correspond to the string that would correctly convert to the appropriate
enum value using
Enum.valueOf
.-
Required Element Summary
Required Elements -
Optional Element Summary
Optional ElementsModifier and TypeOptional ElementDescriptionboolean
Specifies the default boolean value to use.byte
Specifies the default byte value to use.char
Specifies the default byte value to use.Class<?>
Specifies the defaultClass
value to use.double
Specifies the default double floating point value to use.float
Specifies the default floating point value to use.int
Specifies the default integer value to use.long
Specifies the default long value to use.short
Specifies the default long value to use.Specifies the default value this attribute should use if none is provided or if the provided value is invalid.boolean
Indicates that this attribute is a sensitive one that shouldn't be logged directly.
-
Element Details
-
value
String valueSpecifies the name of the attribute (case-insensitive) this annotation corresponds to.
-
-
-
defaultBoolean
boolean defaultBooleanSpecifies the default boolean value to use.- Default:
- false
-
defaultByte
byte defaultByteSpecifies the default byte value to use.- Default:
- (byte)0x00
-
defaultChar
char defaultCharSpecifies the default byte value to use.- Default:
- '\u0000'
-
defaultClass
Class<?> defaultClassSpecifies the defaultClass
value to use.- Default:
- java.lang.Object.class
-
defaultDouble
double defaultDoubleSpecifies the default double floating point value to use.- Default:
- 0.0
-
defaultFloat
float defaultFloatSpecifies the default floating point value to use.- Default:
- 0.0f
-
defaultInt
int defaultIntSpecifies the default integer value to use.- Default:
- 0
-
defaultLong
long defaultLongSpecifies the default long value to use.- Default:
- 0L
-
defaultShort
short defaultShortSpecifies the default long value to use.- Default:
- 0
-
defaultString
String defaultStringSpecifies the default value this attribute should use if none is provided or if the provided value is invalid.- Default:
- ""
-
sensitive
boolean sensitiveIndicates that this attribute is a sensitive one that shouldn't be logged directly. Such attributes will instead be output as a hashed value.- Default:
- false
-