org.objectweb.asm.attrs
Class AnnotationDefaultAttribute
public class AnnotationDefaultAttribute
The AnnotationDefault attribute is a variable length attribute in the
attributes table of certain method_info structures, namely those representing
elements of annotation types. The AnnotationDefault attribute records the
default value for the element represented by the method_info structure. Each
method_info structures representing an element of an annotation types may contain
at most one AnnotationDefault attribute. The JVM must make this default value
available so it can be applied by appropriate reflective APIs.
The AnnotationDefault attribute has the following format:
AnnotationDefault_attribute {
u2 attribute_name_index;
u4 attribute_length;
element_value default_value;
}
The items of the AnnotationDefault structure are as follows:
element
defaultValue
public Object defaultValue
Default value for annotation. Could be one of
Byte
, Character
, Double
,
Float
, Integer
, Long
, Short
,
Boolean
, String
,
Annotation.EnumConstValue
, Type
,
Annotation
or Object[]
.
AnnotationDefaultAttribute
public AnnotationDefaultAttribute()
AnnotationDefaultAttribute
public AnnotationDefaultAttribute(Object defaultValue)
toString
public String toString()
Returns value in the format described in JSR-175 for Java source code.
- value in the format described in JSR-175 for Java source code.