public class GenericObjectType
extends org.apache.bcel.generic.ObjectType
A GenericObjectType is either a parameterized type e.g.
List<String>
, or a type variable e.g. T
.
This class cannot be initialized directly. Instead, create a GenericObjectType by calling GenericUtilities.getType(String) and passing in the bytecode signature for the type.
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object o) |
org.apache.bcel.generic.Type |
getExtension() |
java.lang.String |
getGenericParametersAsString() |
int |
getNumParameters() |
org.apache.bcel.generic.ObjectType |
getObjectType() |
org.apache.bcel.generic.ReferenceType |
getParameterAt(int index) |
java.util.List<? extends org.apache.bcel.generic.ReferenceType> |
getParameters() |
GenericUtilities.TypeCategory |
getTypeCategory()
Get the TypeCategory that represents this Object
|
org.apache.bcel.generic.Type |
getUpperBound() |
java.lang.String |
getVariable() |
int |
hashCode() |
boolean |
hasParameters() |
org.apache.bcel.generic.ReferenceType |
produce() |
java.lang.String |
toPlainString() |
java.lang.String |
toString() |
java.lang.String |
toString(boolean includeGenerics)
Return a string representation of this object.
|
accessibleTo, getClassName, getInstance, referencesClass, referencesClassExact, referencesInterface, referencesInterfaceExact, subclassOf
firstCommonSuperclass, getFirstCommonSuperclass, isAssignmentCompatibleWith, isCastableTo
public org.apache.bcel.generic.ReferenceType produce()
public int hashCode()
hashCode
in class org.apache.bcel.generic.ObjectType
public boolean equals(java.lang.Object o)
equals
in class org.apache.bcel.generic.ObjectType
public org.apache.bcel.generic.Type getUpperBound()
public org.apache.bcel.generic.Type getExtension()
public java.lang.String getVariable()
public GenericUtilities.TypeCategory getTypeCategory()
GenericUtilities.TypeCategory
public boolean hasParameters()
List<String>
. This implies that
isVariable() is falsespublic int getNumParameters()
public org.apache.bcel.generic.ReferenceType getParameterAt(int index)
index
- should be less than getNumParameters()@CheckForNull public java.util.List<? extends org.apache.bcel.generic.ReferenceType> getParameters()
public org.apache.bcel.generic.ObjectType getObjectType()
public java.lang.String toString(boolean includeGenerics)
toString()
in case any existing code assumes that this
object is an ObjectType and expects similar string representation. i.e.
toString()
is equivalent to toString(false)
)includeGenerics
- if true then the string includes generic information in this
object. Otherwise this returns the same value as
ObjectType.toString()public java.lang.String toString()
toString
in class org.apache.bcel.generic.Type
public java.lang.String toPlainString()
public java.lang.String getGenericParametersAsString()
FindBugs™ is licenced under the LGPL. Copyright © 2006 University of Maryland.