Class AbstractDeclaredStatement<A>
- java.lang.Object
-
- org.opendaylight.yangtools.yang.parser.spi.meta.AbstractDeclaredStatement<A>
-
- Type Parameters:
A
- Argument type.
- All Implemented Interfaces:
DeclaredStatement<A>
,ModelStatement<A>
- Direct Known Subclasses:
AbstractRootStatement
,BitsSpecificationImpl
,GroupingStatementImpl
,PatternStatementImpl
public abstract class AbstractDeclaredStatement<A> extends Object implements DeclaredStatement<A>
Utility abstract base class for implementing declared statements.
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
AbstractDeclaredStatement(StmtContext<A,?,?> context)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description A
argument()
Returns statement argument.Collection<? extends DeclaredStatement<?>>
declaredSubstatements()
Returns collection of explicitly declared child statements, while preserving its original ordering from original source.StatementSource
getStatementSource()
Returns statement source, which denotes if statement was explicitly declared in original model or inferred during semantic processing of model.String
rawArgument()
Returns statement argument as was present in original source.StatementDefinition
statementDefinition()
Statement Definition of this statement.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement
declaredSubstatements, findFirstDeclaredSubstatement, findFirstDeclaredSubstatementArgument, streamDeclaredSubstatements
-
-
-
-
Constructor Detail
-
AbstractDeclaredStatement
protected AbstractDeclaredStatement(StmtContext<A,?,?> context)
-
-
Method Detail
-
rawArgument
public String rawArgument()
Description copied from interface:DeclaredStatement
Returns statement argument as was present in original source.- Specified by:
rawArgument
in interfaceDeclaredStatement<A>
- Returns:
- statement argument as was present in original source or null, if statement does not take argument.
-
argument
public A argument()
Description copied from interface:ModelStatement
Returns statement argument.- Specified by:
argument
in interfaceModelStatement<A>
- Returns:
- statement argument or null if statement does not have argument.
-
statementDefinition
public StatementDefinition statementDefinition()
Description copied from interface:ModelStatement
Statement Definition of this statement.- Specified by:
statementDefinition
in interfaceModelStatement<A>
- Returns:
- definition of this statement.
-
declaredSubstatements
public Collection<? extends DeclaredStatement<?>> declaredSubstatements()
Description copied from interface:DeclaredStatement
Returns collection of explicitly declared child statements, while preserving its original ordering from original source.- Specified by:
declaredSubstatements
in interfaceDeclaredStatement<A>
- Returns:
- Collection of statements, which were explicitly declared in source of model.
-
getStatementSource
public StatementSource getStatementSource()
Description copied from interface:ModelStatement
Returns statement source, which denotes if statement was explicitly declared in original model or inferred during semantic processing of model.- Specified by:
getStatementSource
in interfaceModelStatement<A>
- Returns:
- statement source.
-
-