Package org.jf.dexlib2.immutable.value
Class ImmutableAnnotationEncodedValue
- java.lang.Object
-
- org.jf.dexlib2.base.value.BaseAnnotationEncodedValue
-
- org.jf.dexlib2.immutable.value.ImmutableAnnotationEncodedValue
-
- All Implemented Interfaces:
java.lang.Comparable<EncodedValue>
,BasicAnnotation
,AnnotationEncodedValue
,EncodedValue
,ImmutableEncodedValue
public class ImmutableAnnotationEncodedValue extends BaseAnnotationEncodedValue implements ImmutableEncodedValue
-
-
Field Summary
Fields Modifier and Type Field Description protected com.google.common.collect.ImmutableSet<? extends ImmutableAnnotationElement>
elements
protected java.lang.String
type
-
Constructor Summary
Constructors Constructor Description ImmutableAnnotationEncodedValue(java.lang.String type, com.google.common.collect.ImmutableSet<? extends ImmutableAnnotationElement> elements)
ImmutableAnnotationEncodedValue(java.lang.String type, java.util.Collection<? extends AnnotationElement> elements)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description com.google.common.collect.ImmutableSet<? extends ImmutableAnnotationElement>
getElements()
Gets a set of the name/value elements associated with this annotation.java.lang.String
getType()
Gets the type of this annotation.static ImmutableAnnotationEncodedValue
of(AnnotationEncodedValue annotationEncodedValue)
-
Methods inherited from class org.jf.dexlib2.base.value.BaseAnnotationEncodedValue
compareTo, equals, getValueType, hashCode, toString
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.jf.dexlib2.iface.value.EncodedValue
getValueType
-
-
-
-
Field Detail
-
type
@Nonnull protected final java.lang.String type
-
elements
@Nonnull protected final com.google.common.collect.ImmutableSet<? extends ImmutableAnnotationElement> elements
-
-
Constructor Detail
-
ImmutableAnnotationEncodedValue
public ImmutableAnnotationEncodedValue(@Nonnull java.lang.String type, @Nullable java.util.Collection<? extends AnnotationElement> elements)
-
ImmutableAnnotationEncodedValue
public ImmutableAnnotationEncodedValue(@Nonnull java.lang.String type, @Nullable com.google.common.collect.ImmutableSet<? extends ImmutableAnnotationElement> elements)
-
-
Method Detail
-
of
public static ImmutableAnnotationEncodedValue of(AnnotationEncodedValue annotationEncodedValue)
-
getType
@Nonnull public java.lang.String getType()
Description copied from interface:AnnotationEncodedValue
Gets the type of this annotation. This will be the type descriptor of the class that defines this annotation.- Specified by:
getType
in interfaceAnnotationEncodedValue
- Specified by:
getType
in interfaceBasicAnnotation
- Returns:
- The type of this annotation
-
getElements
@Nonnull public com.google.common.collect.ImmutableSet<? extends ImmutableAnnotationElement> getElements()
Description copied from interface:AnnotationEncodedValue
Gets a set of the name/value elements associated with this annotation. The elements in the returned set will be unique by name.- Specified by:
getElements
in interfaceAnnotationEncodedValue
- Specified by:
getElements
in interfaceBasicAnnotation
- Returns:
- A set of AnnotationElements
-
-