public abstract class ComponentPath
extends java.lang.Object
Constructor and Description |
---|
ComponentPath() |
Modifier and Type | Method and Description |
---|---|
boolean |
atRoot()
|
abstract com.google.common.collect.ImmutableList<javax.lang.model.element.TypeElement> |
components()
Returns the component types, starting from the root
component and ending with the current component.
|
static ComponentPath |
create(java.lang.Iterable<javax.lang.model.element.TypeElement> components)
Returns a new
ComponentPath from components . |
javax.lang.model.element.TypeElement |
currentComponent()
Returns the component at the end of the path.
|
ComponentPath |
parent()
Returns this path's parent path.
|
javax.lang.model.element.TypeElement |
parentComponent()
Returns the parent of the currentComponent() current component}.
|
javax.lang.model.element.TypeElement |
rootComponent()
Returns the root
Component - or ProductionComponent -annotated type |
java.lang.String |
toString() |
public static ComponentPath create(java.lang.Iterable<javax.lang.model.element.TypeElement> components)
ComponentPath
from components
.public abstract com.google.common.collect.ImmutableList<javax.lang.model.element.TypeElement> components()
public final javax.lang.model.element.TypeElement rootComponent()
Component
- or ProductionComponent
-annotated typepublic final javax.lang.model.element.TypeElement currentComponent()
public final javax.lang.model.element.TypeElement parentComponent()
java.lang.IllegalStateException
- if the current graph is the root componentpublic final ComponentPath parent()
java.lang.IllegalStateException
- if the current graph is the root componentpublic final boolean atRoot()
public final java.lang.String toString()
toString
in class java.lang.Object