com.ibm.wala.emf.wrappers
Class ETypeHierarchyWrapper

java.lang.Object
  extended by com.ibm.wala.emf.wrappers.ETypeHierarchyWrapper

public class ETypeHierarchyWrapper
extends java.lang.Object

This is a convenience class: it provides a view of an EClassHierarchy that should be more convenient for common client-side use. a container of a class hierarchy and an interface hierarchy


Constructor Summary
ETypeHierarchyWrapper(EClassHierarchyWrapper cha, EInterfaceHierarchyWrapper iface)
          Warning: this constructor does NOT set up the "implements" relation; the caller must do this separately.
ETypeHierarchyWrapper(ETypeHierarchy t)
           
 
Method Summary
 java.util.Collection<EJavaClass> getAllSuperclasses(EJavaClass klass)
           
 EClassHierarchyWrapper getClasses()
           
 java.util.Collection<EJavaClass> getImplements(EJavaClass klass)
           
 EInterfaceHierarchyWrapper getInterfaces()
           
 org.eclipse.emf.ecore.EClass getTargetType()
           
static ETypeHierarchyWrapper loadFromFile(java.lang.String fileName)
           
 void recordImplements(EJavaClass klass, EJavaClass i)
           
 org.eclipse.emf.ecore.EObject toEMF()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ETypeHierarchyWrapper

public ETypeHierarchyWrapper(ETypeHierarchy t)
Parameters:
t -
Throws:
java.lang.IllegalArgumentException - if t is null

ETypeHierarchyWrapper

public ETypeHierarchyWrapper(EClassHierarchyWrapper cha,
                             EInterfaceHierarchyWrapper iface)
Warning: this constructor does NOT set up the "implements" relation; the caller must do this separately.

Parameters:
cha -
iface -
Method Detail

toEMF

public org.eclipse.emf.ecore.EObject toEMF()

loadFromFile

public static ETypeHierarchyWrapper loadFromFile(java.lang.String fileName)
                                          throws java.io.FileNotFoundException
Throws:
java.io.FileNotFoundException

getClasses

public EClassHierarchyWrapper getClasses()

getInterfaces

public EInterfaceHierarchyWrapper getInterfaces()

recordImplements

public void recordImplements(EJavaClass klass,
                             EJavaClass i)

getImplements

public java.util.Collection<EJavaClass> getImplements(EJavaClass klass)
Parameters:
klass -
Returns:
set of EJavaClass, the interfaces klass directly implements

getAllSuperclasses

public java.util.Collection<EJavaClass> getAllSuperclasses(EJavaClass klass)
Parameters:
klass -
Returns:
all superclasses of klass.

getTargetType

public org.eclipse.emf.ecore.EClass getTargetType()