Class GenericAnnotationAttributes<A extends Annotation>
java.lang.Object
java.util.AbstractMap<K,V>
java.util.HashMap<K,V>
java.util.LinkedHashMap<String,Object>
org.springframework.core.annotation.AnnotationAttributes
io.microsphere.spring.core.annotation.GenericAnnotationAttributes<A>
- Type Parameters:
A- The type ofAnnotation
- All Implemented Interfaces:
Serializable,Cloneable,Map<String,Object>
- Direct Known Subclasses:
ResolvablePlaceholderAnnotationAttributes
public class GenericAnnotationAttributes<A extends Annotation>
extends org.springframework.core.annotation.AnnotationAttributes
Generic
AnnotationAttributes- Since:
- 1.0.0
- Author:
- Mercy
- See Also:
-
AnnotationAttributes- Serialized Form
-
Nested Class Summary
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K extends Object,V extends Object>, AbstractMap.SimpleImmutableEntry<K extends Object, V extends Object> -
Constructor Summary
ConstructorsConstructorDescriptionGenericAnnotationAttributes(A annotation) GenericAnnotationAttributes(org.springframework.core.annotation.AnnotationAttributes attributes) -
Method Summary
Modifier and TypeMethodDescriptionGet TheclassofAnnotation.booleaninthashCode()static <A extends Annotation>
GenericAnnotationAttributes<A>of(A annotation) Create an instance ofGenericAnnotationAttributesfrom the specifiedannotationstatic <A extends Annotation>
GenericAnnotationAttributes<A>Create an instance ofGenericAnnotationAttributesfrom the specifiedmapof attributes and theclassofannotation.static <A extends Annotation>
GenericAnnotationAttributes<A>of(org.springframework.core.annotation.AnnotationAttributes attributes) Create an instance ofGenericAnnotationAttributesfrom the specifiedAnnotationAttributesstatic Set<org.springframework.core.annotation.AnnotationAttributes>ofSet(org.springframework.core.annotation.AnnotationAttributes... attributesArray) Create asetofGenericAnnotationAttributestoString()Methods inherited from class org.springframework.core.annotation.AnnotationAttributes
fromMap, getAnnotation, getAnnotation, getAnnotationArray, getAnnotationArray, getBoolean, getClass, getClassArray, getEnum, getNumber, getString, getStringArrayMethods inherited from class java.util.LinkedHashMap
clear, containsValue, entrySet, forEach, get, getOrDefault, keySet, removeEldestEntry, replaceAll, valuesMethods inherited from class java.util.HashMap
clone, compute, computeIfAbsent, computeIfPresent, containsKey, isEmpty, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, sizeMethods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, containsKey, isEmpty, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, size
-
Constructor Details
-
GenericAnnotationAttributes
-
GenericAnnotationAttributes
public GenericAnnotationAttributes(org.springframework.core.annotation.AnnotationAttributes attributes) -
GenericAnnotationAttributes
-
-
Method Details
-
annotationType
Get TheclassofAnnotation.Current method will override the super classes' method since Spring Framework 4.2
- Overrides:
annotationTypein classorg.springframework.core.annotation.AnnotationAttributes- Returns:
- non-null
-
equals
-
hashCode
public int hashCode() -
toString
- Overrides:
toStringin classorg.springframework.core.annotation.AnnotationAttributes
-
of
@Nonnull public static <A extends Annotation> GenericAnnotationAttributes<A> of(@Nonnull A annotation) Create an instance ofGenericAnnotationAttributesfrom the specifiedannotation- Type Parameters:
A- theclassofannotation- Parameters:
annotation-annotation- Returns:
- non-null
-
of
@Nonnull public static <A extends Annotation> GenericAnnotationAttributes<A> of(@Nonnull org.springframework.core.annotation.AnnotationAttributes attributes) Create an instance ofGenericAnnotationAttributesfrom the specifiedAnnotationAttributes- Type Parameters:
A- theclassofannotation- Parameters:
attributes-annotationAttributes- Returns:
- non-null
-
of
@Nonnull public static <A extends Annotation> GenericAnnotationAttributes<A> of(@Nonnull Map<String, Object> attributes, @Nonnull Class<A> annotationType) Create an instance ofGenericAnnotationAttributesfrom the specifiedmapof attributes and theclassofannotation.- Type Parameters:
A- theclassofannotation- Parameters:
attributes- the map of annotation attributes, must not be nullannotationType- theclassofannotation, must not be null- Returns:
- a new instance of
GenericAnnotationAttributes - Throws:
IllegalArgumentException- ifannotationTypeis null- See Also:
-
ofSet
@Nonnull @Immutable public static Set<org.springframework.core.annotation.AnnotationAttributes> ofSet(@Nullable org.springframework.core.annotation.AnnotationAttributes... attributesArray) Create asetofGenericAnnotationAttributes- Parameters:
attributesArray-- Returns:
- non-null
-