public static class InheritanceProvider.ClassInfo.Impl extends InheritanceProvider.ClassInfo.Abstract implements InheritanceProvider.ClassInfo
InheritanceProvider.ClassInfo.InheritanceProvider.ClassInfo.Abstract, InheritanceProvider.ClassInfo.Impl| Modifier and Type | Field and Description |
|---|---|
protected Map<FieldSignature,InheritanceType> |
fields |
protected Map<String,InheritanceType> |
fieldsByName |
protected List<String> |
interfaces |
protected boolean |
isInterface |
protected Map<MethodSignature,InheritanceType> |
methods |
protected String |
name |
protected Set<InheritanceProvider.ClassInfo> |
parents |
protected String |
superName |
| Constructor and Description |
|---|
Impl(String name,
boolean isInterface,
String superName,
List<String> interfaces,
Map<FieldSignature,InheritanceType> fields,
Map<String,InheritanceType> fieldsByName,
Map<MethodSignature,InheritanceType> methods) |
| Modifier and Type | Method and Description |
|---|---|
Map<FieldSignature,InheritanceType> |
getFields()
Gets an unmodifiable view of all fields declared in the class.
|
Map<String,InheritanceType> |
getFieldsByName()
Gets an unmodifiable view of all field names declared in the class.
|
List<String> |
getInterfaces()
Gets an unmodifiable view of all the direct interfaces of the class.
|
Map<MethodSignature,InheritanceType> |
getMethods()
Gets an unmodifiable view of all methods declared in the class.
|
String |
getName()
Gets the name of the class.
|
String |
getSuperName()
Gets the name of this class' super class.
|
boolean |
isInterface()
Gets whether the represented class is an interface.
|
InheritanceProvider.ClassInfo |
lazy()
Returns a new
InheritanceProvider.ClassInfo that caches the information
returned by the getters in this interface. |
Set<InheritanceProvider.ClassInfo> |
provideParents(InheritanceProvider provider)
Gets an unmodifiable view of all parents of this class, recursively.
|
void |
provideParents(InheritanceProvider provider,
Collection<InheritanceProvider.ClassInfo> parents)
Populates the given collection with all parents of this class, recursively.
|
equals, hashCode, toStringclone, finalize, getClass, notify, notifyAll, wait, wait, waitcanInherit, canInherit, getField, getMethod, getPackage, hasParent, hasParent, overridesprotected final String name
protected final boolean isInterface
protected final String superName
protected final Map<FieldSignature,InheritanceType> fields
protected final Map<String,InheritanceType> fieldsByName
protected final Map<MethodSignature,InheritanceType> methods
protected Set<InheritanceProvider.ClassInfo> parents
public Impl(String name, boolean isInterface, String superName, List<String> interfaces, Map<FieldSignature,InheritanceType> fields, Map<String,InheritanceType> fieldsByName, Map<MethodSignature,InheritanceType> methods)
public String getName()
InheritanceProvider.ClassInfogetName in interface InheritanceProvider.ClassInfopublic boolean isInterface()
InheritanceProvider.ClassInfoisInterface in interface InheritanceProvider.ClassInfotrue if the class is an interfacepublic String getSuperName()
InheritanceProvider.ClassInfoReturns an empty string for interfaces or Object.
getSuperName in interface InheritanceProvider.ClassInfopublic List<String> getInterfaces()
InheritanceProvider.ClassInfogetInterfaces in interface InheritanceProvider.ClassInfopublic Map<FieldSignature,InheritanceType> getFields()
InheritanceProvider.ClassInfogetFields in interface InheritanceProvider.ClassInfopublic Map<String,InheritanceType> getFieldsByName()
InheritanceProvider.ClassInfogetFieldsByName in interface InheritanceProvider.ClassInfopublic Map<MethodSignature,InheritanceType> getMethods()
InheritanceProvider.ClassInfogetMethods in interface InheritanceProvider.ClassInfopublic Set<InheritanceProvider.ClassInfo> provideParents(InheritanceProvider provider)
InheritanceProvider.ClassInfoIf a class in the inheritance chain cannot be provided by the
given InheritanceProvider it will be missing in the result,
along with all its parent classes.
provideParents in interface InheritanceProvider.ClassInfoprovider - The provider to use for looking up parent classespublic void provideParents(InheritanceProvider provider, Collection<InheritanceProvider.ClassInfo> parents)
InheritanceProvider.ClassInfoIf a class in the inheritance chain cannot be provided by the
given InheritanceProvider it will be missing in the result,
along with all its parent classes.
provideParents in interface InheritanceProvider.ClassInfoprovider - The provider to use for looking up parent classesparents - The collection to populatepublic InheritanceProvider.ClassInfo lazy()
InheritanceProvider.ClassInfoInheritanceProvider.ClassInfo that caches the information
returned by the getters in this interface.
This method is intended for usage by InheritanceProviders
to simplify their implementation. All InheritanceProvider.ClassInfo provided
by an InheritanceProvider should be lazy initialized
or otherwise cached.
lazy in interface InheritanceProvider.ClassInfo