Interface MapNode
- All Superinterfaces:
DataContainerChild
,DistinctContainer<YangInstanceIdentifier.NodeIdentifierWithPredicates,
,MapEntryNode> DistinctNodeContainer<YangInstanceIdentifier.NodeIdentifierWithPredicates,
,MapEntryNode> MixinNode
,NormalizedContainer<MapEntryNode>
,NormalizedData
,NormalizedNode
,NormalizedNodeContainer<MapEntryNode>
,OrderingAware
,PrettyTreeAware
- All Known Subinterfaces:
SystemMapNode
,UserMapNode
- All Known Implementing Classes:
ImmutableMapNodeBuilder.ImmutableMapNode
,ImmutableUserMapNodeBuilder.ImmutableUserMapNode
public sealed interface MapNode
extends DistinctNodeContainer<YangInstanceIdentifier.NodeIdentifierWithPredicates,MapEntryNode>, DataContainerChild, MixinNode
permits SystemMapNode, UserMapNode
Containment node, which contains
MapEntryNode
of the same type, which may be quickly retrieved using a key.
This node maps to the list node in YANG schema, schema and semantics of this node, its children and key construction
is defined by YANG list
statement and its key
and ordered-by
substatements.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.opendaylight.yangtools.yang.data.api.schema.OrderingAware
OrderingAware.System, OrderingAware.User
-
Method Summary
Modifier and TypeMethodDescriptionasMap()
Return aMap
view of this node.default Collection<@NonNull MapEntryNode>
body()
Returns the body of this node.contract()
Return the contract governing thisNormalizedData
instance.default boolean
isEmpty()
Determine whether this container body is empty.default int
size()
Return the logical size of this container body.Methods inherited from interface org.opendaylight.yangtools.yang.data.api.schema.DataContainerChild
getIdentifier, name
Methods inherited from interface org.opendaylight.yangtools.yang.data.api.schema.DistinctContainer
childByArg, findChildByArg, getChildByArg
Methods inherited from interface org.opendaylight.yangtools.yang.data.api.schema.OrderingAware
ordering
Methods inherited from interface org.opendaylight.yangtools.concepts.PrettyTreeAware
prettyTree
-
Method Details
-
contract
Description copied from interface:NormalizedData
Return the contract governing thisNormalizedData
instance.- Specified by:
contract
in interfaceNormalizedData
- Specified by:
contract
in interfaceNormalizedNode
- Returns:
- A class identifying the NormalizedData contract.
-
asMap
Return aMap
view of this node. Note that the iteration order of the returned is map is not defined in this interface.- Returns:
- Map view of this node.
-
body
Description copied from interface:DistinctContainer
Returns the body of this node. While the return value specifiesObject
, this method's return value has further semantics. The returned object must be a well-published contract, such asString
,Collection<NormalizedNode>
orDOMSource
.Returns iteration of all child nodes. Order of returned child nodes may be defined by subinterfaces.
All nodes returned in this iterable, MUST also be accessible via
DistinctContainer.childByArg(PathArgument)
using their associated identifier.- Specified by:
body
in interfaceDistinctContainer<YangInstanceIdentifier.NodeIdentifierWithPredicates,
MapEntryNode> - Specified by:
body
in interfaceNormalizedContainer<MapEntryNode>
- Specified by:
body
in interfaceNormalizedData
- Returns:
- Iteration of all child nodes
-
size
default int size()Description copied from interface:NormalizedContainer
Return the logical size of this container body. The default implementation defers tobody().size()
.- Specified by:
size
in interfaceNormalizedContainer<MapEntryNode>
- Returns:
- Size of this container's body.
-
isEmpty
default boolean isEmpty()Description copied from interface:NormalizedContainer
Determine whether this container body is empty. The default implementation defers tobody().isEmpty()
.- Specified by:
isEmpty
in interfaceNormalizedContainer<MapEntryNode>
- Returns:
- True if this container has an empty body.
-