Interface FmiBuilder.ScopeElement<AST>
- Type Parameters:
AST- the type the scoping element encloses
- All Known Subinterfaces:
FmiBuilder.DynamicActiveScope<AST>,FmiBuilder.IfScope<AST>,FmiBuilder.Scope<AST>,FmiBuilder.Scoping<AST>,FmiBuilder.TryScope<AST>,FmiBuilder.WhileScope<AST>
- Enclosing interface:
FmiBuilder<AST,B, E, SETTINGS>
public static interface FmiBuilder.ScopeElement<AST>
Scoping element which defines a scope like a block, if, while etc.
-
Method Summary
Modifier and TypeMethodDescription<P extends FmiBuilder.ScopeElement<AST>>
PfindParent(Class<P> clz) Find a prent element of a specific typeThe declaration node that defined the underlying scopeparent()The parent element of this element or null if root
-
Method Details
-
parent
FmiBuilder.ScopeElement<AST> parent()The parent element of this element or null if root- Returns:
- the parent
-
getDeclaration
AST getDeclaration()The declaration node that defined the underlying scope- Returns:
- the scope
-
findParent
Find a prent element of a specific type- Type Parameters:
P- the type of class- Parameters:
clz- the class type to search for- Returns:
- the parent of the specified type or null
-