Bug 6414: Fixed DataNodeIterator's traverseModule method
[yangtools.git] / yang / yang-model-util / src / main / java / org / opendaylight / yangtools / yang / model / util / InstanceIdentifierType.java
index 02289efb0531f8b25931c5f513cec7379738baa4..452c9a7c80d8c0ea395c6a7a8abcaeed5fd2136e 100644 (file)
@@ -9,7 +9,6 @@ package org.opendaylight.yangtools.yang.model.util;
 
 import java.util.Collections;
 import java.util.List;
-
 import org.opendaylight.yangtools.concepts.Immutable;
 import org.opendaylight.yangtools.yang.common.QName;
 import org.opendaylight.yangtools.yang.model.api.RevisionAwareXPath;
@@ -27,8 +26,9 @@ import org.opendaylight.yangtools.yang.model.api.type.InstanceIdentifierTypeDefi
  * returns false.
  *
  * @see InstanceIdentifierTypeDefinition
- *
+ * @deprecated Use {@link org.opendaylight.yangtools.yang.model.util.type.BaseTypes#instanceIdentifierType()} instead
  */
+@Deprecated
 public final class InstanceIdentifierType implements InstanceIdentifierTypeDefinition, Immutable {
 
     private static final QName NAME = BaseTypes.INSTANCE_IDENTIFIER_QNAME;
@@ -36,35 +36,12 @@ public final class InstanceIdentifierType implements InstanceIdentifierTypeDefin
     private static final String DESCRIPTION = "The instance-identifier built-in type is used to "
             + "uniquely identify a particular instance node in the data tree.";
     private static final String REFERENCE = "https://tools.ietf.org/html/rfc6020#section-9.13";
-
     private static final String UNITS = "";
-    private final Boolean requireInstance;
 
     private static final InstanceIdentifierType INSTANCE_WITH_REQUIRED_TRUE = new InstanceIdentifierType(true);
     private static final InstanceIdentifierType INSTANCE_WITH_REQUIRED_FALSE = new InstanceIdentifierType(false);
 
-    /**
-     * Constructs new instance identifier.
-     *
-     * @param xpath
-     * @deprecated Use {@link #getInstance()} for default one, since Instance Identifier does not have xpath.
-     */
-    @Deprecated
-    public InstanceIdentifierType(final RevisionAwareXPath xpath) {
-        requireInstance = true;
-    }
-
-    /**
-     * Constructs new instance identifier.
-     *
-     * @param xpath
-     * @param requireInstance if instance of data is required
-     * @deprecated Use {@link #create(boolean)}, since Instance Identifier does not have xpath.
-     */
-    @Deprecated
-    public InstanceIdentifierType(final RevisionAwareXPath xpath, final boolean requireInstance) {
-        this.requireInstance = requireInstance;
-    }
+    private final Boolean requireInstance;
 
     private InstanceIdentifierType(final boolean requiredInstance) {
         this.requireInstance = requiredInstance;
@@ -103,8 +80,7 @@ public final class InstanceIdentifierType implements InstanceIdentifierTypeDefin
      * (non-Javadoc)
      *
      * @see
-     * org.opendaylight.yangtools.yang.model.api.TypeDefinition#getDefaultValue
-     * ()
+     * org.opendaylight.yangtools.yang.model.api.TypeDefinition#getDefaultValue()
      */
     @Override
     public Object getDefaultValue() {
@@ -166,8 +142,7 @@ public final class InstanceIdentifierType implements InstanceIdentifierTypeDefin
      * (non-Javadoc)
      *
      * @see
-     * org.opendaylight.yangtools.yang.model.api.SchemaNode#getExtensionSchemaNodes
-     * ()
+     * org.opendaylight.yangtools.yang.model.api.SchemaNode#getExtensionSchemaNodes()
      */
     @Override
     public List<UnknownSchemaNode> getUnknownSchemaNodes() {
@@ -219,7 +194,4 @@ public final class InstanceIdentifierType implements InstanceIdentifierTypeDefin
         InstanceIdentifierType other = (InstanceIdentifierType) obj;
         return requireInstance.equals(other.requireInstance);
     }
-
-
-
 }