Package org.revapi.java.spi
Interface JavaTypeElement
-
- All Superinterfaces:
Comparable<JavaElement>,org.revapi.Element<JavaElement>,JavaElement,JavaModelElement
public interface JavaTypeElement extends JavaModelElement
Elements in the element forest that represent Java types, will implement this interface.- Since:
- 0.1
- Author:
- Lukas Krejci
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description TypeElementgetDeclaringElement()For an inherited method for example, this will return the element in the super type that declares this method.DeclaredTypegetModelRepresentation()Note that this is distinctly different fromJavaModelElement.getDeclaringElement().booleanisInAPI()booleanisInApiThroughUse()-
Methods inherited from interface java.lang.Comparable
compareTo
-
Methods inherited from interface org.revapi.Element
as, getApi, getArchive, getChildren, getCumulativeReferencedElements, getCumulativeReferencingElements, getFullHumanReadableString, getReferencedElements, getReferencingElements, iterateOverChildren, searchChildren, searchChildren, setParent, stream
-
Methods inherited from interface org.revapi.java.spi.JavaElement
getTypeEnvironment
-
Methods inherited from interface org.revapi.java.spi.JavaModelElement
getParent, getParentType, isInherited
-
-
-
-
Method Detail
-
getModelRepresentation
DeclaredType getModelRepresentation()
Description copied from interface:JavaModelElementNote that this is distinctly different fromJavaModelElement.getDeclaringElement(). This method returns a type mirror describing an element on its position in the type hierarchy. I.e. if an inherited method with type parameters resolved according to the class it is inherited "to".- Specified by:
getModelRepresentationin interfaceJavaModelElement- Returns:
- the representation of this java element at its position in the type hierarchy
-
getDeclaringElement
TypeElement getDeclaringElement()
Description copied from interface:JavaModelElementFor an inherited method for example, this will return the element in the super type that declares this method.- Specified by:
getDeclaringElementin interfaceJavaModelElement- Returns:
- The element that represents the declaration this model element.
-
isInAPI
boolean isInAPI()
- Returns:
- true if this type was found to be a part of the API, false otherwise
-
isInApiThroughUse
boolean isInApiThroughUse()
- Returns:
- true, if the class is not accessible in and of itself but is dragged into the API by a significant use.
-
-