All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class espresso.util.ClassType

java.lang.Object
   |
   +----espresso.util.Type
           |
           +----espresso.util.ReferenceType
                   |
                   +----espresso.util.ClassType

public class ClassType
extends ReferenceType

Variable Index

 o interfaces_d
 o name_d
 o node_d
 o root_d
 o rootType_d
 o superType_d

Constructor Index

 o ClassType(String)
 o ClassType(Symbol)

Method Index

 o distanceTo(Type)
 o findField(Symbol)
Search for a field in this type or in any of its super types (both classes and interfaces).
 o findMethod(MethodDesc)
Search for a method in this type or in any of its super types Returns the closest unique occurrence of a method type, that is most specific, or null if no match was established If the most specific method type is not unique, than we have 2 cases : - if the 2 methods are defined in the same class, than an ambiguous type error is thrown - if the 2 mthods are defined in different classes, than we have 2 sub cases - if the 2 method types are identical, than the one closer to the leaf of the type hierarchy overrides the one higher up - if the 2 method types are not identical, then a ambiguous type error is thrown If a more specific method type is encountered higher up in the type hierarchy, then this also results in an ambiguous type error
 o identicalTo(Type)
 o IFEQ(boolean)
 o IFNE(boolean)
 o isTopType()
 o name()
 o readClassFile()
Make sure that this type is accessible using the symbol table.
 o subTypeOf(Type)
 o superInterfaces()
 o superType()
 o superTypeOf(Type)
 o toClassFileType()
Map an Espresso type to a ClassGen one.
 o toString()

Variables

 o name_d
 Symbol name_d
 o node_d
 TypeDeclarationNode node_d
 o interfaces_d
 Vector interfaces_d
 o superType_d
 ClassType superType_d
 o root_d
 static Symbol root_d
 o rootType_d
 static ClassType rootType_d

Constructors

 o ClassType
 public ClassType(String name)
 o ClassType
 public ClassType(Symbol name)

Methods

 o name
 public Symbol name()
 o readClassFile
 void readClassFile()
Make sure that this type is accessible using the symbol table. Note that the import manager caches read requests.

 o identicalTo
 public boolean identicalTo(Type other)
Overrides:
identicalTo in class ReferenceType
 o isTopType
 public boolean isTopType()
 o superType
 public ClassType superType()
 o superInterfaces
 public Vector superInterfaces()
 o subTypeOf
 public boolean subTypeOf(Type other)
Overrides:
subTypeOf in class ReferenceType
 o superTypeOf
 public boolean superTypeOf(Type other)
Overrides:
superTypeOf in class ReferenceType
 o distanceTo
 public int distanceTo(Type other)
Overrides:
distanceTo in class ReferenceType
 o findField
 public Symbol findField(Symbol fname) throws AmbiguousName
Search for a field in this type or in any of its super types (both classes and interfaces). Returns a fully qualified name.

 o findMethod
 public MethodDesc findMethod(MethodDesc mdesc) throws TypeCheckError
Search for a method in this type or in any of its super types Returns the closest unique occurrence of a method type, that is most specific, or null if no match was established If the most specific method type is not unique, than we have 2 cases : - if the 2 methods are defined in the same class, than an ambiguous type error is thrown - if the 2 mthods are defined in different classes, than we have 2 sub cases - if the 2 method types are identical, than the one closer to the leaf of the type hierarchy overrides the one higher up - if the 2 method types are not identical, then a ambiguous type error is thrown If a more specific method type is encountered higher up in the type hierarchy, then this also results in an ambiguous type error

 o toString
 public String toString()
Overrides:
toString in class Type
 o toClassFileType
 public ClassGenType toClassFileType()
Map an Espresso type to a ClassGen one.

Overrides:
toClassFileType in class Type
 o IFEQ
 public Instruction IFEQ(boolean tozero)
Overrides:
IFEQ in class Type
 o IFNE
 public Instruction IFNE(boolean tozero)
Overrides:
IFNE in class Type

All Packages  Class Hierarchy  This Package  Previous  Next  Index