Populate parser/ hierarchy
[yangtools.git] / yang / rfc8528-data-api / src / main / java / org / opendaylight / yangtools / rfc8528 / data / api / MountPointNode.java
1 /*
2  * Copyright (c) 2019 PANTHEON.tech s.r.o. and others. All rights reserved.
3  *
4  * This program and the accompanying materials are made available under the
5  * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6  * and is available at http://www.eclipse.org/legal/epl-v10.html
7  */
8 package org.opendaylight.yangtools.rfc8528.data.api;
9
10 import com.google.common.annotations.Beta;
11 import org.eclipse.jdt.annotation.NonNull;
12 import org.opendaylight.yangtools.yang.data.api.schema.DataContainerChild;
13 import org.opendaylight.yangtools.yang.data.api.schema.DataContainerNode;
14 import org.opendaylight.yangtools.yang.data.api.schema.MixinNode;
15
16 /**
17  * Common NormalizedNode representation of a YANG mount point.
18  *
19  * <p>
20  * These nodes are not meant to be stored in a DataTree and most NormalizedNode utilities will be confused when
21  * they see them. The purpose of this interface is making data interchange between mount point-aware components more
22  * seamless.
23  */
24 /*
25  * FIXME: 7.0.0: The above is not quite right. DataTree instances should be able to handle mount points and correctly
26  *               handle them, provided they get enough support from MountPointContext.
27  */
28 @Beta
29 public interface MountPointNode extends DataContainerNode, DataContainerChild, MixinNode {
30     @Override
31     default Class<MountPointNode> contract() {
32         return MountPointNode.class;
33     }
34
35     @Override
36     MountPointIdentifier getIdentifier();
37
38     /**
39      * Return the underlying mount point context.
40      *
41      * @return Underlying mount point context
42      */
43     @NonNull MountPointContext getMountPointContext();
44
45     /*
46      * FIXME: consider whether this interface should contain some information based on 'parent-reference':
47      *        - List<YangXPathExpression.QualifiedBound> getParentReference()
48      *        - the node-set required to maintain referential integrity in the subtree of this node
49      */
50 }