public class InterfaceHierarchy extends Object
Modifier and Type | Field and Description |
---|---|
private static ImmutableEntryHashMapRVM<RVMClass,ImmutableEntryHashSetRVM<RVMClass>> |
interfaceMapping
a mapping from RVMClass (an interface) to a set of classes that
claim to implement this interface.
|
Constructor and Description |
---|
InterfaceHierarchy() |
Modifier and Type | Method and Description |
---|---|
private static ImmutableEntryHashSetRVM<RVMClass> |
allImplementors(RVMClass I) |
private static ImmutableEntryHashSetRVM<RVMClass> |
allSubClasses(RVMClass C) |
private static ImmutableEntryHashSetRVM<RVMClass> |
findOrCreateSet(RVMClass I) |
static RVMMethod |
getUniqueImplementation(RVMMethod foo)
If, in the current class hierarchy, there is exactly one method that
defines the interface method foo, then return the unique
implementation.
|
private static void |
noteImplements(RVMClass c,
RVMClass I)
Notes that a class implements an interface.
|
static void |
notifyClassInitialized(RVMClass c)
Notify this dictionary that a new class has been initialized.
|
private static final ImmutableEntryHashMapRVM<RVMClass,ImmutableEntryHashSetRVM<RVMClass>> interfaceMapping
public InterfaceHierarchy()
public static void notifyClassInitialized(RVMClass c)
c
- class that was initializedprivate static void noteImplements(RVMClass c, RVMClass I)
c
- the class that implements the interfaceI
- the implemented interfaceprivate static ImmutableEntryHashSetRVM<RVMClass> findOrCreateSet(RVMClass I)
I
- the implemented interfaceprivate static ImmutableEntryHashSetRVM<RVMClass> allImplementors(RVMClass I)
I
- the implemented interfaceprivate static ImmutableEntryHashSetRVM<RVMClass> allSubClasses(RVMClass C)
C
- an interfacepublic static RVMMethod getUniqueImplementation(RVMMethod foo)
foo
- an interface methodnull
otherwise