BUG-1092: rename data.api.InstanceIdentifier to YangInstanceIdentifier
[yangtools.git] / yang / yang-data-api / src / main / java / org / opendaylight / yangtools / yang / data / api / schema / AugmentationNode.java
index babba071fb5e10ad9b9d55699918dca5ec86dfc2..71fa5c705a47a6395bfdf92a0fd71d6e66cc071f 100644 (file)
@@ -7,31 +7,43 @@
  */
 package org.opendaylight.yangtools.yang.data.api.schema;
 
-import org.opendaylight.yangtools.yang.data.api.InstanceIdentifier.AugmentationIdentifier;
-import org.opendaylight.yangtools.yang.data.api.InstanceIdentifier.PathArgument;
-
-import com.google.common.base.Optional;
+import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier;
+import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier.AugmentationIdentifier;
+import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier.PathArgument;
+import org.opendaylight.yangtools.yang.model.api.AugmentationSchema;
 
 
 /**
  *
- * Node representing Augmentation.
+ * Data instance of <code>augment</code> assiociated with parent node.
+ * 
+ * Augmentation is addition of subtree defined by other external YANG Model and
+ * is schema for subtree is described by instance of  {@link AugmentationSchema}
+ * associated with parent node of this node.
  *
  * Augmentation node MUST NOT be direct child of other augmentation node.
  *
  */
 public interface AugmentationNode extends //
     MixinNode, //
-    DataContainerNode<AugmentationIdentifier> {
-
-
-    @Override
-    public Iterable<DataContainerChild<?, ?>> getValue();
-
-
-    @Override
-    public Optional<DataContainerChild<?, ?>> getChild(PathArgument child);
-
+    DataContainerNode<AugmentationIdentifier>,
+    DataContainerChild<YangInstanceIdentifier.AugmentationIdentifier, Iterable<DataContainerChild<? extends PathArgument, ?>>> {
+
+    /**
+     * Gets identifier of augmentation node
+     * 
+     * Returned identifier of augmentation node contains all possible 
+     * direct child QNames.
+     * 
+     * This is sufficient to identify instance of augmentation,
+     * since RFC6020 states that <code>augment</code> that augment
+     * statement must not add multiple nodes from same namespace 
+     * / module
+     * to the target node.
+     * 
+     * @return Identifier which uniquelly identifies augmentation in particular subtree.
+     * 
+     */
     @Override
     public AugmentationIdentifier getIdentifier();
 }