Class SchemaInferenceStack.Inference
java.lang.Object
org.opendaylight.yangtools.yang.model.spi.AbstractEffectiveStatementInference<EffectiveStatement<?,?>>
org.opendaylight.yangtools.yang.model.util.SchemaInferenceStack.Inference
- All Implemented Interfaces:
Immutable
,EffectiveStatementInference
- Enclosing class:
SchemaInferenceStack
@Beta
public static final class SchemaInferenceStack.Inference
extends AbstractEffectiveStatementInference<EffectiveStatement<?,?>>
Semantic binding of
EffectiveStatementInference
produced by SchemaInferenceStack
. Sequence of
statementPath()
is implementation-specific.-
Nested Class Summary
Nested classes/interfaces inherited from class org.opendaylight.yangtools.yang.model.spi.AbstractEffectiveStatementInference
AbstractEffectiveStatementInference.WithPath<T extends EffectiveStatement<?,
?>> -
Method Summary
Modifier and TypeMethodDescriptionboolean
isEmpty()
Returntrue
if this inference is empty.static @NonNull SchemaInferenceStack.Inference
of
(EffectiveModelContext modelContext) Create a newSchemaInferenceStack.Inference
backed by an effective model.static @NonNull SchemaInferenceStack.Inference
ofDataTreePath
(EffectiveModelContext modelContext, QName... qnames) Create a newSchemaInferenceStack.Inference
backed by an effective model and set up to point and specified data tree node.List
<EffectiveStatement<?, ?>> @NonNull SchemaInferenceStack
Convert this inference into aSchemaInferenceStack
.Methods inherited from class org.opendaylight.yangtools.yang.model.spi.AbstractEffectiveStatementInference
addToStringAttributes, modelContext, toString
-
Method Details
-
of
Create a newSchemaInferenceStack.Inference
backed by an effective model.- Parameters:
modelContext
-EffectiveModelContext
to which the inference is attached- Returns:
- A new @link Inference}
- Throws:
NullPointerException
- ifmodelContext
isnull
-
ofDataTreePath
public static @NonNull SchemaInferenceStack.Inference ofDataTreePath(EffectiveModelContext modelContext, QName... qnames) Create a newSchemaInferenceStack.Inference
backed by an effective model and set up to point and specified data tree node.- Parameters:
modelContext
-EffectiveModelContext
to which the inference is attachedqnames
- Data tree path qnames- Returns:
- A new @link Inference}
- Throws:
NullPointerException
- if any argument isnull
or path contains anull
elementIllegalArgumentException
- if a path element cannot be found
-
statementPath
Description copied from interface:EffectiveStatementInference
AnUnmodifiable
List
ofEffectiveStatement
s, ordered in some meaningful way. Precise semantics of the statement order is clarified by individualEffectiveStatementInference
specializations.- Specified by:
statementPath
in interfaceEffectiveStatementInference
- Specified by:
statementPath
in classAbstractEffectiveStatementInference<EffectiveStatement<?,
?>> - Returns:
- A List of EffectiveStatements
- See Also:
-
isEmpty
public boolean isEmpty()Returntrue
if this inference is empty. This is a more efficient alternative tostatementPath().isEmpty()
.- Returns:
true
ifstatementPath()
returns an empty list
-
toSchemaInferenceStack
Convert this inference into aSchemaInferenceStack
.- Returns:
- A new stack
-