|
Jode 1.90-CVS Build Aug 6, 2004 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.jode.type.Type
net.sf.jode.type.ReferenceType
net.sf.jode.type.ClassType
This class is the base class of all types representing a class type.
Field Summary | |
protected java.lang.String |
className
|
Fields inherited from class net.sf.jode.type.Type |
EMPTY_IFACES, tBoolByte, tBoolean, tBoolInt, tBoolUInt, tByte, TC_ARRAY, TC_BOOLEAN, TC_BYTE, TC_CHAR, TC_CLASS, TC_CLASSIFACE, TC_DOUBLE, TC_ERROR, TC_FLOAT, TC_INT, TC_INTEGER, TC_LONG, TC_METHOD, TC_NULL, TC_RANGE, TC_SHORT, TC_SYSCLASS, TC_UNKNOWN, TC_VOID, tChar, tCloneable, tComparable, tDouble, tError, tFloat, tInt, tJavaLangClass, tLong, tNull, tObject, tSerializable, tShort, tString, tStringBuffer, tStringBuilder, tUInt, tUnknown, tUObject, tVoid |
Constructor Summary | |
ClassType(int typecode,
java.lang.String clazzName)
|
Method Summary | |
Type |
createRangeType(ReferenceType bottomType)
Create the type corresponding to the range from bottomType to this. |
boolean |
equals(java.lang.Object o)
|
Type |
getCanonic()
Returns the canonic type of this type set. |
Type |
getCastHelper(Type fromType)
Checks if we need to cast to a middle type, before we can cast from fromType to this type. |
java.lang.String |
getClassName()
|
java.lang.String |
getDefaultName()
Generates the default name, that is the `natural' choice for local of this type. |
Type |
getGeneralizedType(Type type)
Returns the generalized type of this and type. |
Type |
getHint()
Returns the hint type of this type set. |
abstract ClassType[] |
getInterfaces()
Returns the reference type representing the interfaces this class implements. |
Type |
getSpecializedType(Type type)
Returns the specialized type of this and type. |
Type |
getSubType()
The sub types of this type. |
abstract ClassType |
getSuperClass()
Returns the reference type representing the super class, or null if this reference type represents java.lang.Object, or for interfaces. |
java.lang.Class |
getTypeClass()
Returns the java.lang.Class representing this type. |
java.lang.String |
getTypeSignature()
Returns the type signature of this type. |
int |
hashCode()
|
boolean |
isClassType()
Checks if this is a class or array type (but not a null type). |
abstract boolean |
isFinal()
Checks if this type represents an interface. |
abstract boolean |
isInterface()
Checks if this type represents an interface. |
boolean |
isSubTypeOf(Type type)
Returns true, if this is a sub type of type. |
abstract boolean |
isUnknown()
Checks if this type represents an interface. |
boolean |
isValidType()
Checks if this type represents a valid type instead of a list of minimum types. |
boolean |
maybeSubTypeOf(Type type)
Returns true, if this is a sub type of type. |
java.lang.String |
toString()
Returns a string representation describing this type set. |
Methods inherited from class net.sf.jode.type.ReferenceType |
findCommonClassTypes, getSuperType, implementsAllIfaces, intersection |
Methods inherited from class net.sf.jode.type.Type |
getDefaultValue, getTypeCode, isOfType, stackSize, tArray, tClass, tClass, tMethod, tRange, tSubType, tSuperType, tSystemClass, tType |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
protected java.lang.String className
Constructor Detail |
public ClassType(int typecode, java.lang.String clazzName)
Method Detail |
public java.lang.String getClassName()
public abstract boolean isUnknown()
public abstract boolean isInterface()
public abstract boolean isFinal()
public abstract ClassType getSuperClass()
public abstract ClassType[] getInterfaces()
public boolean isSubTypeOf(Type type)
Type
isSubTypeOf
in class Type
public boolean maybeSubTypeOf(Type type)
Type
maybeSubTypeOf
in class Type
public Type getSubType()
Type
getSubType
in class ReferenceType
public Type getHint()
Type
tError
or tUnknown
, and may lead
to errors for certain range types.
getHint
in class Type
public Type getCanonic()
Type
getCanonic
in class Type
public Type createRangeType(ReferenceType bottomType)
createRangeType
in class ReferenceType
bottomType
- the bottom type.
public Type getSpecializedType(Type type)
getSpecializedType
in class ReferenceType
type
- the other type.
public Type getGeneralizedType(Type type)
getGeneralizedType
in class ReferenceType
type
- the other type.
public java.lang.String getTypeSignature()
Type
getTypeSignature
in class Type
public java.lang.Class getTypeClass() throws java.lang.ClassNotFoundException
Type
getTypeClass
in class Type
java.lang.ClassNotFoundException
public java.lang.String toString()
Type
toString
in class Type
public Type getCastHelper(Type fromType)
getCastHelper
in class Type
public boolean isValidType()
isValidType
in class Type
public boolean isClassType()
isClassType
in class Type
public java.lang.String getDefaultName()
getDefaultName
in class Type
public int hashCode()
public boolean equals(java.lang.Object o)
|
Jode 1.90-CVS Build Aug 6, 2004 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |