Coding gudilines for class and methods javadocs fixed.
Change-Id: I0153e6391c9ec9eacaac65c3989834b6bf5c65bf
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/ResolutionType.java b/src/main/java/org/onosproject/yangutils/datamodel/ResolutionType.java
index 6b0da18..aa0abbb 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/ResolutionType.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/ResolutionType.java
@@ -17,7 +17,7 @@
package org.onosproject.yangutils.datamodel;
/**
- * ENUM to identify the YANG resolution type.
+ * Represents ENUM to identify the YANG resolution type.
*/
public enum ResolutionType {
/**
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangAppErrorInfo.java b/src/main/java/org/onosproject/yangutils/datamodel/YangAppErrorInfo.java
index 9b3ba3f..671aa08 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangAppErrorInfo.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangAppErrorInfo.java
@@ -17,29 +17,30 @@
* Abstraction of error message and application info processing.
*/
public interface YangAppErrorInfo {
+
/**
- * Get the application's error message for data error.
+ * Returns the application's error message for data error.
*
* @return application's error message for data error.
*/
String getGetErrorMessage();
/**
- * Set the application's error message for data error.
+ * Sets the application's error message for data error.
*
* @param errorMessage application's error message for data error.
*/
void setErrorMessage(String errorMessage);
/**
- * Get the application's error tag for data error.
+ * Returns the application's error tag for data error.
*
* @return application's error tag for data error.
*/
String getGetErrorAppTag();
/**
- * Set the application's error tag for data error.
+ * Sets the application's error tag for data error.
*
* @param errorMessage application's error tag for data error.
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangAugment.java b/src/main/java/org/onosproject/yangutils/datamodel/YangAugment.java
index 9ca828b..374e2ab 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangAugment.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangAugment.java
@@ -76,7 +76,7 @@
* +--------------+---------+-------------+------------------+
*/
/**
- * Data model node to maintain information defined in YANG augment.
+ * Representation of data model node to maintain information defined in YANG augment.
*/
public class YangAugment extends YangNode
implements YangLeavesHolder, YangCommonInfo, Parsable, CollisionDetector {
@@ -124,7 +124,7 @@
}
/**
- * Get the augmented node.
+ * Returns the augmented node.
*
* @return the augmented node
*/
@@ -133,7 +133,7 @@
}
/**
- * Set the augmented node.
+ * Sets the augmented node.
*
* @param nodeIdentifiers the augmented node
*/
@@ -142,7 +142,7 @@
}
/**
- * Get the description.
+ * Returns the description.
*
* @return the description
*/
@@ -176,7 +176,7 @@
}
/**
- * Get the list of leaves.
+ * Returns the list of leaves.
*
* @return the list of leaves
*/
@@ -186,7 +186,7 @@
}
/**
- * Set the list of leaves.
+ * Sets the list of leaves.
*
* @param leafsList the list of leaf to set
*/
@@ -195,7 +195,7 @@
}
/**
- * Add a leaf.
+ * Adds a leaf.
*
* @param leaf the leaf to be added
*/
@@ -209,7 +209,7 @@
}
/**
- * Get the list of leaf-list.
+ * Returns the list of leaf-list.
*
* @return the list of leaf-list
*/
@@ -219,7 +219,7 @@
}
/**
- * Set the list of leaf-list.
+ * Sets the list of leaf-list.
*
* @param listOfLeafList the list of leaf-list to set
*/
@@ -228,7 +228,7 @@
}
/**
- * Add a leaf-list.
+ * Adds a leaf-list.
*
* @param leafList the leaf-list to be added
*/
@@ -242,7 +242,7 @@
}
/**
- * Get the textual reference.
+ * Returns the textual reference.
*
* @return the reference
*/
@@ -252,7 +252,7 @@
}
/**
- * Set the textual reference.
+ * Sets the textual reference.
*
* @param reference the reference to set
*/
@@ -262,7 +262,7 @@
}
/**
- * Get the status.
+ * Returns the status.
*
* @return the status
*/
@@ -272,7 +272,7 @@
}
/**
- * Set the status.
+ * Sets the status.
*
* @param status the status to set
*/
@@ -292,7 +292,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -302,7 +302,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -312,7 +312,7 @@
}
/**
- * Get the target nodes name where the augmentation is being done.
+ * Returns the target nodes name where the augmentation is being done.
*
* @return target nodes name where the augmentation is being done
*/
@@ -322,14 +322,13 @@
}
/**
- * Set the target nodes name where the augmentation is being done.
+ * Sets the target nodes name where the augmentation is being done.
*
* @param name target nodes name where the augmentation is being done
*/
@Override
public void setName(String name) {
this.name = name;
-
}
}
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangBelongsTo.java b/src/main/java/org/onosproject/yangutils/datamodel/YangBelongsTo.java
index 42e8bc6..7fd8a1a 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangBelongsTo.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangBelongsTo.java
@@ -44,7 +44,7 @@
*/
/**
- * Maintains the belongs-to data type information.
+ * Represents the belongs-to data type information.
*/
public class YangBelongsTo implements Parsable {
@@ -73,7 +73,7 @@
}
/**
- * Get the belongs to module name.
+ * Returns the belongs to module name.
*
* @return the belongs to module name
*/
@@ -82,7 +82,7 @@
}
/**
- * Set the belongs to module name.
+ * Sets the belongs to module name.
*
* @param belongsToModuleName the belongs to module name to set
*
@@ -92,7 +92,7 @@
}
/**
- * Get the prefix.
+ * Returns the prefix.
*
* @return the prefix
*/
@@ -101,7 +101,7 @@
}
/**
- * Set the prefix.
+ * Sets the prefix.
*
* @param prefix the prefix to set
*/
@@ -120,7 +120,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -130,7 +130,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangBit.java b/src/main/java/org/onosproject/yangutils/datamodel/YangBit.java
index 68dc985..4449b6a 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangBit.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangBit.java
@@ -16,12 +16,12 @@
package org.onosproject.yangutils.datamodel;
+import java.util.Objects;
+
import org.onosproject.yangutils.datamodel.exceptions.DataModelException;
import org.onosproject.yangutils.parser.Parsable;
import org.onosproject.yangutils.utils.YangConstructType;
-import java.util.Objects;
-
/*-
* The "bit" statement, which is a sub-statement to the "type" statement,
* MUST be present if the type is "bits". It is repeatedly used to
@@ -44,7 +44,7 @@
*/
/**
- * Maintains the bit data type information.
+ * Represents the bit data type information.
*/
public class YangBit implements YangCommonInfo, Parsable {
@@ -90,7 +90,7 @@
}
/**
- * Set the bit name.
+ * Sets the bit name.
*
* @param bitName the bit name to set
*/
@@ -109,7 +109,7 @@
}
/**
- * Set the description.
+ * Sets the description.
*
* @param description set the description
*/
@@ -129,7 +129,7 @@
}
/**
- * Set the textual reference.
+ * Sets the textual reference.
*
* @param reference the reference to set
*/
@@ -149,7 +149,7 @@
}
/**
- * Set the status.
+ * Sets the status.
*
* @param status the status to set
*/
@@ -168,7 +168,7 @@
}
/**
- * Set the bit position.
+ * Sets the bit position.
*
* @param position the position to set
*/
@@ -188,6 +188,7 @@
@Override
public boolean equals(Object obj) {
+
if (this == obj) {
return true;
}
@@ -204,7 +205,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -214,7 +215,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangBits.java b/src/main/java/org/onosproject/yangutils/datamodel/YangBits.java
index 1f53c09..4771aad 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangBits.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangBits.java
@@ -32,7 +32,7 @@
*/
/**
- * Maintains the bits data type information.
+ * Represents the bits data type information.
*/
public class YangBits implements Parsable {
@@ -43,7 +43,7 @@
private String bitsName;
/**
- * Create a YANG bits type object.
+ * Creates a YANG bits type object.
*/
public YangBits() {
setBitSet(new HashSet<YangBit>());
@@ -59,7 +59,7 @@
}
/**
- * Set the bit set.
+ * Sets the bit set.
*
* @param bitSet the bit set
*/
@@ -68,7 +68,7 @@
}
/**
- * Add bit info.
+ * Adds bit info.
*
* @param bitInfo the bit information to be added
* @throws DataModelException due to violation in data model rules
@@ -100,7 +100,7 @@
}
/**
- * Set bits name.
+ * Sets bits name.
*
* @param bitsName bit name to be set
*/
@@ -109,7 +109,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -119,7 +119,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangCase.java b/src/main/java/org/onosproject/yangutils/datamodel/YangCase.java
index 987e34a..48f5d17 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangCase.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangCase.java
@@ -89,7 +89,7 @@
* +--------------+---------+-------------+------------------+
*/
/**
- * Data model node to maintain information defined in YANG case.
+ * Represents data model node to maintain information defined in YANG case.
*/
public class YangCase extends YangNode
implements YangLeavesHolder, YangCommonInfo, Parsable, CollisionDetector {
@@ -127,14 +127,14 @@
private YangStatusType status;
/**
- * Create a choice node.
+ * Creates a choice node.
*/
public YangCase() {
super(YangNodeType.CASE_NODE);
}
/**
- * Get the case name.
+ * Returns the case name.
*
* @return case name
*/
@@ -144,7 +144,7 @@
}
/**
- * Set the case name.
+ * Sets the case name.
*
* @param name case name
*/
@@ -154,7 +154,7 @@
}
/**
- * Get the description.
+ * Returns the description.
*
* @return the description
*/
@@ -164,7 +164,7 @@
}
/**
- * Set the description.
+ * Sets the description.
*
* @param description set the description
*/
@@ -174,7 +174,7 @@
}
/**
- * Get the list of leaves.
+ * Returns the list of leaves.
*
* @return the list of leaves
*/
@@ -184,7 +184,7 @@
}
/**
- * Set the list of leaves.
+ * Sets the list of leaves.
*
* @param leafsList the list of leaf to set
*/
@@ -193,7 +193,7 @@
}
/**
- * Add a leaf.
+ * Adds a leaf.
*
* @param leaf the leaf to be added
*/
@@ -207,7 +207,7 @@
}
/**
- * Get the list of leaf-list.
+ * Returns the list of leaf-list.
*
* @return the list of leaf-list
*/
@@ -217,7 +217,7 @@
}
/**
- * Set the list of leaf-list.
+ * Sets the list of leaf-list.
*
* @param listOfLeafList the list of leaf-list to set
*/
@@ -226,7 +226,7 @@
}
/**
- * Add a leaf-list.
+ * Adds a leaf-list.
*
* @param leafList the leaf-list to be added
*/
@@ -240,7 +240,7 @@
}
/**
- * Get the textual reference.
+ * Returns the textual reference.
*
* @return the reference
*/
@@ -250,7 +250,7 @@
}
/**
- * Set the textual reference.
+ * Sets the textual reference.
*
* @param reference the reference to set
*/
@@ -260,7 +260,7 @@
}
/**
- * Get the status.
+ * Returns the status.
*
* @return the status
*/
@@ -270,7 +270,7 @@
}
/**
- * Set the status.
+ * Sets the status.
*
* @param status the status to set
*/
@@ -290,7 +290,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -300,7 +300,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangChoice.java b/src/main/java/org/onosproject/yangutils/datamodel/YangChoice.java
index cfc1445..43a486f 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangChoice.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangChoice.java
@@ -57,7 +57,7 @@
* +--------------+---------+-------------+------------------+
*/
/**
- * Data model node to maintain information defined in YANG choice.
+ * Represents data model node to maintain information defined in YANG choice.
*/
public class YangChoice extends YangNode implements YangCommonInfo, Parsable, CollisionDetector {
@@ -141,7 +141,7 @@
}
/**
- * Get the choice name.
+ * Returns the choice name.
*
* @return choice name
*/
@@ -151,7 +151,7 @@
}
/**
- * Set the choice name.
+ * Sets the choice name.
*
* @param name choice name
*/
@@ -161,7 +161,7 @@
}
/**
- * Get config flag.
+ * Returns config flag.
*
* @return the config flag
*/
@@ -170,7 +170,7 @@
}
/**
- * Set config flag.
+ * Sets config flag.
*
* @param isCfg the config flag
*/
@@ -179,7 +179,7 @@
}
/**
- * Get the default case.
+ * Returns the default case.
*
* @return the default case
*/
@@ -188,7 +188,7 @@
}
/**
- * Set the default case.
+ * Sets the default case.
*
* @param defaultCase the default case to set
*/
@@ -197,7 +197,7 @@
}
/**
- * Get the mandatory status.
+ * Returns the mandatory status.
*
* @return the mandatory status
*/
@@ -206,7 +206,7 @@
}
/**
- * Set the mandatory status.
+ * Sets the mandatory status.
*
* @param mandatory the mandatory status
*/
@@ -215,7 +215,7 @@
}
/**
- * Get the description.
+ * Returns the description.
*
* @return the description
*/
@@ -225,7 +225,7 @@
}
/**
- * Set the description.
+ * Sets the description.
*
* @param description set the description
*/
@@ -235,7 +235,7 @@
}
/**
- * Get the textual reference.
+ * Returns the textual reference.
*
* @return the reference
*/
@@ -245,7 +245,7 @@
}
/**
- * Set the textual reference.
+ * Sets the textual reference.
*
* @param reference the reference to set
*/
@@ -255,7 +255,7 @@
}
/**
- * Get the status.
+ * Returns the status.
*
* @return the status
*/
@@ -265,7 +265,7 @@
}
/**
- * Set the status.
+ * Sets the status.
*
* @param status the status to set
*/
@@ -285,7 +285,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -295,7 +295,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangContainer.java b/src/main/java/org/onosproject/yangutils/datamodel/YangContainer.java
index a6f4592..5941837 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangContainer.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangContainer.java
@@ -85,7 +85,7 @@
*/
/**
- * Data model node to maintain information defined in YANG container.
+ * Represents data model node to maintain information defined in YANG container.
*/
public class YangContainer extends YangNode implements YangLeavesHolder, YangCommonInfo, Parsable, CollisionDetector {
@@ -138,7 +138,7 @@
}
/**
- * Get the YANG name of container.
+ * Returns the YANG name of container.
*
* @return the name of container as defined in YANG file
*/
@@ -148,7 +148,7 @@
}
/**
- * Set the YANG name of container.
+ * Sets the YANG name of container.
*
* @param name the name of container as defined in YANG file
*/
@@ -158,7 +158,7 @@
}
/**
- * Get the config flag.
+ * Returns the config flag.
*
* @return the isConfig
*/
@@ -167,7 +167,7 @@
}
/**
- * Set the config flag.
+ * Sets the config flag.
*
* @param isCfg the config flag
*/
@@ -176,7 +176,7 @@
}
/**
- * Get the description.
+ * Returns the description.
*
* @return the description
*/
@@ -186,7 +186,7 @@
}
/**
- * Set the description.
+ * Sets the description.
*
* @param description set the description
*/
@@ -196,7 +196,7 @@
}
/**
- * Get the list of leaves.
+ * Returns the list of leaves.
*
* @return the list of leaves
*/
@@ -206,7 +206,7 @@
}
/**
- * Set the list of leaves.
+ * Sets the list of leaves.
*
* @param leafsList the list of leaf to set
*/
@@ -215,12 +215,13 @@
}
/**
- * Add a leaf.
+ * Adds a leaf.
*
* @param leaf the leaf to be added
*/
@Override
public void addLeaf(YangLeaf leaf) {
+
if (getListOfLeaf() == null) {
setListOfLeaf(new LinkedList<YangLeaf>());
}
@@ -229,7 +230,7 @@
}
/**
- * Get the list of leaf-list.
+ * Returns the list of leaf-list.
*
* @return the list of leaf-list
*/
@@ -239,7 +240,7 @@
}
/**
- * Set the list of leaf-list.
+ * Sets the list of leaf-list.
*
* @param listOfLeafList the list of leaf-list to set
*/
@@ -248,12 +249,13 @@
}
/**
- * Add a leaf-list.
+ * Adds a leaf-list.
*
* @param leafList the leaf-list to be added
*/
@Override
public void addLeafList(YangLeafList leafList) {
+
if (getListOfLeafList() == null) {
setListOfLeafList(new LinkedList<YangLeafList>());
}
@@ -262,7 +264,7 @@
}
/**
- * Get the presence string if present.
+ * Returns the presence string if present.
*
* @return the presence
*/
@@ -271,7 +273,7 @@
}
/**
- * Set the presence string.
+ * Sets the presence string.
*
* @param presence the presence flag
*/
@@ -280,7 +282,7 @@
}
/**
- * Get the textual reference.
+ * Returns the textual reference.
*
* @return the reference
*/
@@ -290,7 +292,7 @@
}
/**
- * Set the textual reference.
+ * Sets the textual reference.
*
* @param reference the reference to set
*/
@@ -300,7 +302,7 @@
}
/**
- * Get the status.
+ * Returns the status.
*
* @return the status
*/
@@ -310,7 +312,7 @@
}
/**
- * Set the status.
+ * Sets the status.
*
* @param status the status to set
*/
@@ -330,7 +332,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -340,7 +342,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangDataTypes.java b/src/main/java/org/onosproject/yangutils/datamodel/YangDataTypes.java
index 18697df..601a831 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangDataTypes.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangDataTypes.java
@@ -17,7 +17,7 @@
package org.onosproject.yangutils.datamodel;
/**
- * ENUM to identify the YANG data type.
+ * Represents ENUM to identify the YANG data type.
*/
public enum YangDataTypes {
/**
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangDerivedInfo.java b/src/main/java/org/onosproject/yangutils/datamodel/YangDerivedInfo.java
index 7691e4a..a0e83ec 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangDerivedInfo.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangDerivedInfo.java
@@ -17,7 +17,7 @@
package org.onosproject.yangutils.datamodel;
/**
- * Maintains the derived information.
+ * Represents the derived information.
*
* @param <T> extended information.
*/
@@ -52,7 +52,7 @@
}
/**
- * Set the referred typedef reference.
+ * Sets the referred typedef reference.
*
* @param referredTypeDef referred typedef reference
*/
@@ -70,7 +70,7 @@
}
/**
- * Set resolved extended information after successful linking.
+ * Sets resolved extended information after successful linking.
*
* @param resolvedExtendedInfo resolved extended information
*/
@@ -88,7 +88,7 @@
}
/**
- * Set extended information.
+ * Sets extended information.
*
* @param extendedInfo extended information
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangDesc.java b/src/main/java/org/onosproject/yangutils/datamodel/YangDesc.java
index c4b81b1..8c9d60e 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangDesc.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangDesc.java
@@ -21,8 +21,9 @@
* parsing and translator processing of description.
*/
public interface YangDesc {
+
/**
- * Get the description of YANG entity.
+ * Returns the description of YANG entity.
*
* @return the description of YANG entity.
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangEnum.java b/src/main/java/org/onosproject/yangutils/datamodel/YangEnum.java
index 6f04af1..a9f80e3 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangEnum.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangEnum.java
@@ -16,12 +16,12 @@
package org.onosproject.yangutils.datamodel;
+import java.util.Objects;
+
import org.onosproject.yangutils.datamodel.exceptions.DataModelException;
import org.onosproject.yangutils.parser.Parsable;
import org.onosproject.yangutils.utils.YangConstructType;
-import java.util.Objects;
-
/*-
* The "ENUM" statement, which is a sub-statement to the "type"
* statement, MUST be present if the type is "enumeration". It is
@@ -48,7 +48,7 @@
*/
/**
- * Maintains the ENUM data type information.
+ * Represents the ENUM data type information.
*/
public class YangEnum implements YangCommonInfo, Parsable {
@@ -85,7 +85,7 @@
}
/**
- * Get the named value.
+ * Returns the named value.
*
* @return the named value
*/
@@ -94,7 +94,7 @@
}
/**
- * Set the named value.
+ * Sets the named value.
*
* @param namedValue the named value to set
*/
@@ -103,7 +103,7 @@
}
/**
- * Get the description.
+ * Returns the description.
*
* @return the description
*/
@@ -113,7 +113,7 @@
}
/**
- * Set the description.
+ * Sets the description.
*
* @param description set the description
*/
@@ -123,7 +123,7 @@
}
/**
- * Get the textual reference.
+ * Returns the textual reference.
*
* @return the reference
*/
@@ -133,7 +133,7 @@
}
/**
- * Set the textual reference.
+ * Sets the textual reference.
*
* @param reference the reference to set
*/
@@ -143,7 +143,7 @@
}
/**
- * Get the status.
+ * Returns the status.
*
* @return the status
*/
@@ -153,7 +153,7 @@
}
/**
- * Set the status.
+ * Sets the status.
*
* @param status the status to set
*/
@@ -163,7 +163,7 @@
}
/**
- * Get the value.
+ * Returns the value.
*
* @return the value
*/
@@ -172,7 +172,7 @@
}
/**
- * Set the value.
+ * Sets the value.
*
* @param value the value to set
*/
@@ -208,7 +208,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -218,7 +218,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangEnumeration.java b/src/main/java/org/onosproject/yangutils/datamodel/YangEnumeration.java
index 7e597e3..469809c 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangEnumeration.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangEnumeration.java
@@ -29,7 +29,7 @@
*/
/**
- * Maintains the enumeration data type information.
+ * Represents the enumeration data type information.
*/
public class YangEnumeration implements Parsable {
@@ -47,7 +47,7 @@
}
/**
- * Get the ENUM set.
+ * Returns the ENUM set.
*
* @return the ENUM set
*/
@@ -56,7 +56,7 @@
}
/**
- * Set the ENUM set.
+ * Sets the ENUM set.
*
* @param enumSet the ENUM set to set
*/
@@ -65,7 +65,7 @@
}
/**
- * Add ENUM information.
+ * Adds ENUM information.
*
* @param enumInfo the ENUM information to be added
* @throws DataModelException due to violation in data model rules
@@ -86,7 +86,7 @@
}
/**
- * Set the enumeration name.
+ * Sets the enumeration name.
*
* @param enumerationName enumeration name
*/
@@ -105,7 +105,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -115,7 +115,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangGrouping.java b/src/main/java/org/onosproject/yangutils/datamodel/YangGrouping.java
index 36345d5..47abdca 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangGrouping.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangGrouping.java
@@ -17,6 +17,7 @@
import java.util.LinkedList;
import java.util.List;
+
import org.onosproject.yangutils.datamodel.exceptions.DataModelException;
import org.onosproject.yangutils.parser.Parsable;
import org.onosproject.yangutils.utils.YangConstructType;
@@ -74,7 +75,7 @@
*/
/**
- * Data model node to maintain information defined in YANG grouping.
+ * Represents data model node to maintain information defined in YANG grouping.
*/
public class YangGrouping extends YangNode
implements YangLeavesHolder, YangCommonInfo, Parsable, CollisionDetector {
@@ -119,7 +120,7 @@
}
/**
- * Get YANG grouping name.
+ * Returns YANG grouping name.
*
* @return YANG grouping name
*/
@@ -129,7 +130,7 @@
}
/**
- * Set YANG grouping name.
+ * Sets YANG grouping name.
*
* @param name YANG grouping name
*/
@@ -139,7 +140,7 @@
}
/**
- * Get the description.
+ * Returns the description.
*
* @return the description
*/
@@ -149,7 +150,7 @@
}
/**
- * Set the description.
+ * Sets the description.
*
* @param description set the description
*/
@@ -159,7 +160,7 @@
}
/**
- * Get the list of leaves.
+ * Returns the list of leaves.
*
* @return the list of leaves
*/
@@ -169,7 +170,7 @@
}
/**
- * Set the list of leaves.
+ * Sets the list of leaves.
*
* @param leafsList the list of leaf to set
*/
@@ -178,7 +179,7 @@
}
/**
- * Add a leaf.
+ * Adds a leaf.
*
* @param leaf the leaf to be added
*/
@@ -188,7 +189,7 @@
}
/**
- * Get the list of leaf-list.
+ * Returns the list of leaf-list.
*
* @return the list of leaf-list
*/
@@ -198,7 +199,7 @@
}
/**
- * Set the list of leaf-list.
+ * Sets the list of leaf-list.
*
* @param listOfLeafList the list of leaf-list to set
*/
@@ -207,7 +208,7 @@
}
/**
- * Add a leaf-list.
+ * Adds a leaf-list.
*
* @param leafList the leaf-list to be added
*/
@@ -217,7 +218,7 @@
}
/**
- * Get the textual reference.
+ * Returns the textual reference.
*
* @return the reference
*/
@@ -227,7 +228,7 @@
}
/**
- * Set the textual reference.
+ * Sets the textual reference.
*
* @param reference the reference to set
*/
@@ -237,7 +238,7 @@
}
/**
- * Get the status.
+ * Returns the status.
*
* @return the status
*/
@@ -247,7 +248,7 @@
}
/**
- * Set the status.
+ * Sets the status.
*
* @param status the status to set
*/
@@ -267,7 +268,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -277,7 +278,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -299,7 +300,6 @@
*/
@Override
public void detectCollidingChild(String identifierName, YangConstructType dataType) throws DataModelException {
-
// Asks helper to detect colliding child.
detectCollidingChildUtil(identifierName, dataType, this);
}
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangImport.java b/src/main/java/org/onosproject/yangutils/datamodel/YangImport.java
index 70df4dd..b079d3f 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangImport.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangImport.java
@@ -60,7 +60,7 @@
* +---------------+---------+-------------+------------------+
*/
/**
- * Maintains the information about the imported modules.
+ * Represents the information about the imported modules.
*/
public class YangImport implements Parsable {
@@ -90,14 +90,14 @@
private String revision;
/**
- * Default constructor.
+ * Creates a YANG import.
*/
public YangImport() {
}
/**
- * Get the imported module name.
+ * Returns the imported module name.
*
* @return the module name
*/
@@ -106,7 +106,7 @@
}
/**
- * Set module name.
+ * Sets module name.
*
* @param moduleName the module name to set
*/
@@ -115,7 +115,7 @@
}
/**
- * Get the prefix used to identify the entities from the imported module.
+ * Returns the prefix used to identify the entities from the imported module.
*
* @return the prefix used to identify the entities from the imported
* module
@@ -125,7 +125,7 @@
}
/**
- * Set prefix identifier.
+ * Sets prefix identifier.
*
* @param prefixId set the prefix identifier of the imported module
*/
@@ -134,7 +134,7 @@
}
/**
- * Get the revision of the imported module.
+ * Returns the revision of the imported module.
*
* @return the revision of the imported module
*/
@@ -143,7 +143,7 @@
}
/**
- * Set the revision of the imported module.
+ * Sets the revision of the imported module.
*
* @param rev set the revision of the imported module
*/
@@ -162,7 +162,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -173,7 +173,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -193,7 +193,7 @@
}
/**
- * Set the dresolution information node.
+ * Sets the dresolution information node.
*
* @param resolutionInfoNode the resolution information node
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangInclude.java b/src/main/java/org/onosproject/yangutils/datamodel/YangInclude.java
index 70e7016..9010368 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangInclude.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangInclude.java
@@ -34,8 +34,7 @@
* +---------------+---------+-------------+------------------+
*/
/**
- * Maintains the information about the included sub-modules.
- *
+ * Represents the information about the included sub-modules.
*/
public class YangInclude implements Parsable {
@@ -56,13 +55,13 @@
private HasResolutionInfo resolutionInfoNode;
/**
- * Default constructor.
+ * Creates a YANG include.
*/
public YangInclude() {
}
/**
- * Get the name of included sub-module.
+ * Returns the name of included sub-module.
*
* @return the sub-module name
*/
@@ -71,7 +70,7 @@
}
/**
- * Set the name of included sub-modules.
+ * Sets the name of included sub-modules.
*
* @param subModuleName the sub-module name to set
*/
@@ -80,7 +79,7 @@
}
/**
- * Get the revision.
+ * Returns the revision.
*
* @return the revision
*/
@@ -89,7 +88,7 @@
}
/**
- * Set the revision.
+ * Sets the revision.
*
* @param revision the revision to set
*/
@@ -108,7 +107,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -119,7 +118,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -139,7 +138,7 @@
}
/**
- * Set the dresolution information node.
+ * Sets the dresolution information node.
*
* @param resolutionInfoNode the resolution information node
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangInput.java b/src/main/java/org/onosproject/yangutils/datamodel/YangInput.java
index 2ccd8de..10f1ef4 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangInput.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangInput.java
@@ -18,6 +18,7 @@
import java.util.LinkedList;
import java.util.List;
+
import org.onosproject.yangutils.datamodel.exceptions.DataModelException;
import org.onosproject.yangutils.parser.Parsable;
import org.onosproject.yangutils.utils.YangConstructType;
@@ -65,7 +66,7 @@
*/
/**
- * Data model node to maintain information defined in YANG input.
+ * Represents data model node to maintain information defined in YANG input.
*/
public class YangInput extends YangNode implements YangLeavesHolder, Parsable, CollisionDetector {
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangLeaf.java b/src/main/java/org/onosproject/yangutils/datamodel/YangLeaf.java
index 8422e14..83091b1 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangLeaf.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangLeaf.java
@@ -54,8 +54,7 @@
* +--------------+---------+-------------+------------------+
*/
/**
- * Leaf data represented in YANG.
- *
+ * Represents leaf data represented in YANG.
*/
public class YangLeaf implements YangCommonInfo, Parsable {
@@ -100,13 +99,13 @@
private YangType<?> dataType;
/**
- * Default constructor to create a YANG leaf.
+ * Creates a YANG leaf.
*/
public YangLeaf() {
}
/**
- * Get the name of leaf.
+ * Returns the name of leaf.
*
* @return the leaf name
*/
@@ -115,7 +114,7 @@
}
/**
- * Set the name of leaf.
+ * Sets the name of leaf.
*
* @param leafName the leaf name to set
*/
@@ -124,7 +123,7 @@
}
/**
- * Get the config flag.
+ * Returns the config flag.
*
* @return if config flag
*/
@@ -133,7 +132,7 @@
}
/**
- * Set the config flag.
+ * Sets the config flag.
*
* @param isCfg the flag value to set
*/
@@ -142,7 +141,7 @@
}
/**
- * Get the description.
+ * Returns the description.
*
* @return the description
*/
@@ -152,7 +151,7 @@
}
/**
- * Set the description.
+ * Sets the description.
*
* @param description set the description
*/
@@ -162,7 +161,7 @@
}
/**
- * Get if the leaf is mandatory.
+ * Returns if the leaf is mandatory.
*
* @return if leaf is mandatory
*/
@@ -171,7 +170,7 @@
}
/**
- * Set if the leaf is mandatory.
+ * Sets if the leaf is mandatory.
*
* @param isReq if the leaf is mandatory
*/
@@ -180,7 +179,7 @@
}
/**
- * Get the textual reference.
+ * Returns the textual reference.
*
* @return the reference
*/
@@ -190,7 +189,7 @@
}
/**
- * Set the textual reference.
+ * Sets the textual reference.
*
* @param reference the reference to set
*/
@@ -200,7 +199,7 @@
}
/**
- * Get the status.
+ * Returns the status.
*
* @return the status
*/
@@ -210,7 +209,7 @@
}
/**
- * Set the status.
+ * Sets the status.
*
* @param status the status to set
*/
@@ -220,7 +219,7 @@
}
/**
- * Get the units.
+ * Returns the units.
*
* @return the units
*/
@@ -229,7 +228,7 @@
}
/**
- * Set the units.
+ * Sets the units.
*
* @param units the units to set
*/
@@ -238,7 +237,7 @@
}
/**
- * Get the data type.
+ * Returns the data type.
*
* @return the data type
*/
@@ -247,7 +246,7 @@
}
/**
- * Set the data type.
+ * Sets the data type.
*
* @param dataType the data type to set
*/
@@ -266,7 +265,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -277,7 +276,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangLeafList.java b/src/main/java/org/onosproject/yangutils/datamodel/YangLeafList.java
index 8ad2cfc..809bb8c 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangLeafList.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangLeafList.java
@@ -50,7 +50,7 @@
* +--------------+---------+-------------+------------------+
*/
/**
- * Leaf-list data represented in YANG.
+ * Represents leaf-list data represented in YANG.
*/
public class YangLeafList implements YangCommonInfo, Parsable {
@@ -122,13 +122,13 @@
private YangType<?> dataType;
/**
- * Default Constructor to create a YANG leaf-list.
+ * Creates a YANG leaf-list.
*/
public YangLeafList() {
}
/**
- * Get the leaf-list name.
+ * Returns the leaf-list name.
*
* @return the leaf-list name
*/
@@ -137,7 +137,7 @@
}
/**
- * Set the leaf-list name.
+ * Sets the leaf-list name.
*
* @param leafListName the leaf-list name to set
*/
@@ -146,7 +146,7 @@
}
/**
- * Get the config flag.
+ * Returns the config flag.
*
* @return the config flag
*/
@@ -155,7 +155,7 @@
}
/**
- * Set the config flag.
+ * Sets the config flag.
*
* @param isCfg the config flag
*/
@@ -164,7 +164,7 @@
}
/**
- * Get the description.
+ * Returns the description.
*
* @return the description
*/
@@ -174,7 +174,7 @@
}
/**
- * Set the description.
+ * Sets the description.
*
* @param description set the description
*/
@@ -184,7 +184,7 @@
}
/**
- * Get the max elements no.
+ * Returns the max elements no.
*
* @return the max elements no
*/
@@ -193,7 +193,7 @@
}
/**
- * Set the max elements no.
+ * Sets the max elements no.
*
* @param maxElelements max elements no
*/
@@ -202,7 +202,7 @@
}
/**
- * Get the min elements no.
+ * Returns the min elements no.
*
* @return the min elements no
*/
@@ -211,7 +211,7 @@
}
/**
- * Set the min elements no.
+ * Sets the min elements no.
*
* @param minElements the min elements no
*/
@@ -220,7 +220,7 @@
}
/**
- * Get the textual reference.
+ * Returns the textual reference.
*
* @return the reference
*/
@@ -230,7 +230,7 @@
}
/**
- * Set the textual reference.
+ * Sets the textual reference.
*
* @param reference the reference to set
*/
@@ -240,7 +240,7 @@
}
/**
- * Get the status.
+ * Returns the status.
*
* @return the status
*/
@@ -250,7 +250,7 @@
}
/**
- * Set the status.
+ * Sets the status.
*
* @param status the status to set
*/
@@ -260,7 +260,7 @@
}
/**
- * Get the units.
+ * Returns the units.
*
* @return the units
*/
@@ -269,7 +269,7 @@
}
/**
- * Set the units.
+ * Sets the units.
*
* @param units the units to set
*/
@@ -278,7 +278,7 @@
}
/**
- * Get the data type.
+ * Returns the data type.
*
* @return the data type
*/
@@ -287,7 +287,7 @@
}
/**
- * Set the data type.
+ * Sets the data type.
*
* @param dataType the data type to set
*/
@@ -306,7 +306,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -317,7 +317,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangLeavesHolder.java b/src/main/java/org/onosproject/yangutils/datamodel/YangLeavesHolder.java
index f8fc6b6..fd22a99 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangLeavesHolder.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangLeavesHolder.java
@@ -1,16 +1,19 @@
-/*Copyright 2016.year Open Networking Laboratory
+/*
+ * Copyright 2016 Open Networking Laboratory
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.*/
package org.onosproject.yangutils.datamodel;
import java.util.List;
@@ -23,7 +26,7 @@
public interface YangLeavesHolder {
/**
- * Get the list of leaves from data holder like container / list.
+ * Returns the list of leaves from data holder like container / list.
*
* @return the list of leaves.
*/
@@ -37,7 +40,7 @@
void addLeaf(YangLeaf leaf);
/**
- * Get the list of leaf-list from data holder like container / list.
+ * Returns the list of leaf-list from data holder like container / list.
*
* @return the list of leaf-list.
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangList.java b/src/main/java/org/onosproject/yangutils/datamodel/YangList.java
index 4593939..f743f42 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangList.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangList.java
@@ -65,7 +65,7 @@
*/
/**
- * List data represented in YANG.
+ * Represents list data represented in YANG.
*/
public class YangList extends YangNode
implements YangLeavesHolder, YangCommonInfo, Parsable, CollisionDetector {
@@ -166,14 +166,14 @@
private YangStatusType status = YangStatusType.CURRENT;
/**
- * Constructor.
+ * Creates a YANG list object.
*/
public YangList() {
super(YangNodeType.LIST_NODE);
}
/**
- * Get the YANG list name.
+ * Returns the YANG list name.
*
* @return YANG list name
*/
@@ -183,7 +183,7 @@
}
/**
- * Set the YANG list name.
+ * Sets the YANG list name.
*
* @param name YANG list name
*/
@@ -193,7 +193,7 @@
}
/**
- * Get the config flag.
+ * Returns the config flag.
*
* @return the isConfig
*/
@@ -202,7 +202,7 @@
}
/**
- * Set the config flag.
+ * Sets the config flag.
*
* @param isCfg the config flag
*/
@@ -211,7 +211,7 @@
}
/**
- * Get the description.
+ * Returns the description.
*
* @return the description
*/
@@ -221,7 +221,7 @@
}
/**
- * Set the description.
+ * Sets the description.
*
* @param description set the description
*/
@@ -231,7 +231,7 @@
}
/**
- * Get the list of key field names.
+ * Returns the list of key field names.
*
* @return the list of key field names
*/
@@ -240,7 +240,7 @@
}
/**
- * Set the list of key field names.
+ * Sets the list of key field names.
*
* @param keyList the list of key field names
*/
@@ -249,7 +249,7 @@
}
/**
- * Add a key field name.
+ * Adds a key field name.
*
* @param key key field name.
* @throws DataModelException a violation of data model rules
@@ -268,7 +268,7 @@
}
/**
- * Get the list of leaves.
+ * Returns the list of leaves.
*
* @return the list of leaves
*/
@@ -278,7 +278,7 @@
}
/**
- * Set the list of leaves.
+ * Sets the list of leaves.
*
* @param leafsList the list of leaf to set
*/
@@ -287,7 +287,7 @@
}
/**
- * Add a leaf.
+ * Adds a leaf.
*
* @param leaf the leaf to be added
*/
@@ -301,7 +301,7 @@
}
/**
- * Get the list of leaf-list.
+ * Returns the list of leaf-list.
*
* @return the list of leaf-list
*/
@@ -311,7 +311,7 @@
}
/**
- * Set the list of leaf-list.
+ * Sets the list of leaf-list.
*
* @param listOfLeafList the list of leaf-list to set
*/
@@ -320,7 +320,7 @@
}
/**
- * Add a leaf-list.
+ * Adds a leaf-list.
*
* @param leafList the leaf-list to be added
*/
@@ -334,7 +334,7 @@
}
/**
- * Get the max elements.
+ * Returns the max elements.
*
* @return the max elements
*/
@@ -343,7 +343,7 @@
}
/**
- * Set the max elements.
+ * Sets the max elements.
*
* @param max the max elements
*/
@@ -352,7 +352,7 @@
}
/**
- * Get the minimum elements.
+ * Returns the minimum elements.
*
* @return the minimum elements
*/
@@ -361,7 +361,7 @@
}
/**
- * Set the minimum elements.
+ * Sets the minimum elements.
*
* @param minElements the minimum elements
*/
@@ -370,7 +370,7 @@
}
/**
- * Get the textual reference.
+ * Returns the textual reference.
*
* @return the reference
*/
@@ -380,7 +380,7 @@
}
/**
- * Set the textual reference.
+ * Sets the textual reference.
*
* @param reference the reference to set
*/
@@ -390,7 +390,7 @@
}
/**
- * Get the status.
+ * Returns the status.
*
* @return the status
*/
@@ -400,7 +400,7 @@
}
/**
- * Set the status.
+ * Sets the status.
*
* @param status the status to set
*/
@@ -420,7 +420,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -430,7 +430,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangModule.java b/src/main/java/org/onosproject/yangutils/datamodel/YangModule.java
index 3072cad..0c4ec87 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangModule.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangModule.java
@@ -17,6 +17,7 @@
import java.util.LinkedList;
import java.util.List;
+
import org.onosproject.yangutils.datamodel.exceptions.DataModelException;
import org.onosproject.yangutils.parser.Parsable;
import org.onosproject.yangutils.utils.YangConstructType;
@@ -65,7 +66,7 @@
*/
/**
- * Data model node to maintain information defined in YANG module.
+ * Represents data model node to maintain information defined in YANG module.
*/
public class YangModule extends YangNode
implements YangLeavesHolder, YangDesc, YangReference, Parsable, CollisionDetector, HasResolutionInfo {
@@ -188,7 +189,7 @@
private List<YangResolutionInfo> unresolvedResolutionList;
/**
- * Create a YANG node of module type.
+ * Creates a YANG node of module type.
*/
public YangModule() {
@@ -201,7 +202,7 @@
}
/**
- * Get name of the module.
+ * Returns name of the module.
*
* @return module name
*/
@@ -211,7 +212,7 @@
}
/**
- * Set module name.
+ * Sets module name.
*
* @param moduleName module name
*/
@@ -221,7 +222,7 @@
}
/**
- * Get the contact details of the module owner.
+ * Returns the contact details of the module owner.
*
* @return the contact details of YANG owner
*/
@@ -230,7 +231,7 @@
}
/**
- * Set the contact details of the module owner.
+ * Sets the contact details of the module owner.
*
* @param contact the contact details of YANG owner
*/
@@ -239,7 +240,7 @@
}
/**
- * Get the description of module.
+ * Returns the description of module.
*
* @return the description of YANG module
*/
@@ -249,7 +250,7 @@
}
/**
- * Set the description of module.
+ * Sets the description of module.
*
* @param description set the description of YANG module
*/
@@ -259,7 +260,7 @@
}
/**
- * Get the list of imported modules.
+ * Returns the list of imported modules.
*
* @return the list of imported modules
*/
@@ -268,7 +269,7 @@
}
/**
- * Add the imported module information to the import list.
+ * Adds the imported module information to the import list.
*
* @param importedModule module being imported
*/
@@ -282,7 +283,7 @@
}
/**
- * Get the list of included sub modules.
+ * Returns the list of included sub modules.
*
* @return the included list of sub modules
*/
@@ -291,7 +292,7 @@
}
/**
- * Add the included sub module information to the include list.
+ * Adds the included sub module information to the include list.
*
* @param includeModule submodule being included
*/
@@ -305,7 +306,7 @@
}
/**
- * Get the list of leaves in module.
+ * Returns the list of leaves in module.
*
* @return the list of leaves
*/
@@ -315,7 +316,7 @@
}
/**
- * Add a leaf in module.
+ * Adds a leaf in module.
*
* @param leaf the leaf to be added
*/
@@ -325,7 +326,7 @@
}
/**
- * Get the list of leaf-list from module.
+ * Returns the list of leaf-list from module.
*
* @return the list of leaf-list
*/
@@ -335,7 +336,7 @@
}
/**
- * Add a leaf-list in module.
+ * Adds a leaf-list in module.
*
* @param leafList the leaf-list to be added
*/
@@ -345,7 +346,7 @@
}
/**
- * Get the name space of module elements.
+ * Returns the name space of module elements.
*
* @return the nameSpace
*/
@@ -354,7 +355,7 @@
}
/**
- * Set the name space of module elements.
+ * Sets the name space of module elements.
*
* @param nameSpace the nameSpace to set
*/
@@ -363,7 +364,7 @@
}
/**
- * Get the modules organization.
+ * Returns the modules organization.
*
* @return the organization
*/
@@ -372,7 +373,7 @@
}
/**
- * Set the modules organization.
+ * Sets the modules organization.
*
* @param org the organization to set
*/
@@ -381,7 +382,7 @@
}
/**
- * Get the prefix.
+ * Returns the prefix.
*
* @return the prefix
*/
@@ -390,7 +391,7 @@
}
/**
- * Set the prefix.
+ * Sets the prefix.
*
* @param prefix the prefix to set
*/
@@ -407,7 +408,7 @@
}
/**
- * Get the textual reference.
+ * Returns the textual reference.
*
* @return the reference
*/
@@ -417,7 +418,7 @@
}
/**
- * Set the textual reference.
+ * Sets the textual reference.
*
* @param reference the reference to set
*/
@@ -427,7 +428,7 @@
}
/**
- * Get the revision.
+ * Returns the revision.
*
* @return the revision
*/
@@ -436,7 +437,7 @@
}
/**
- * Set the revision.
+ * Sets the revision.
*
* @param revision the revision to set
*/
@@ -445,7 +446,7 @@
}
/**
- * Get the version.
+ * Returns the version.
*
* @return the version
*/
@@ -454,7 +455,7 @@
}
/**
- * Set the version.
+ * Sets the version.
*
* @param version the version to set
*/
@@ -473,7 +474,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -486,7 +487,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangMust.java b/src/main/java/org/onosproject/yangutils/datamodel/YangMust.java
index 28ccb8e..597a36c 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangMust.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangMust.java
@@ -44,7 +44,7 @@
*/
/**
- * Maintain information defined in YANG must.
+ * Represents information defined in YANG must.
*/
public class YangMust implements YangDesc, YangReference, Parsable {
@@ -64,13 +64,13 @@
private String reference;
/**
- * Create a YANG must restriction.
+ * Creates a YANG must restriction.
*/
public YangMust() {
}
/**
- * Get the constraint.
+ * Returns the constraint.
*
* @return the constraint
*/
@@ -79,7 +79,7 @@
}
/**
- * Set the constraint.
+ * Sets the constraint.
*
* @param constratint the constraint to set
*/
@@ -88,7 +88,7 @@
}
/**
- * Get the description.
+ * Returns the description.
*
* @return the description
*/
@@ -98,7 +98,7 @@
}
/**
- * Set the description.
+ * Sets the description.
*
* @param description set the description
*/
@@ -108,7 +108,7 @@
}
/**
- * Get the textual reference.
+ * Returns the textual reference.
*
* @return the reference
*/
@@ -118,7 +118,7 @@
}
/**
- * Set the textual reference.
+ * Sets the textual reference.
*
* @param reference the reference to set
*/
@@ -138,7 +138,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -148,7 +148,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangNameSpace.java b/src/main/java/org/onosproject/yangutils/datamodel/YangNameSpace.java
index 3111773..c27737a 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangNameSpace.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangNameSpace.java
@@ -30,20 +30,20 @@
*/
/**
- * Name space to be used for the XML data tree.
+ * Represents name space to be used for the XML data tree.
*/
public class YangNameSpace implements Parsable {
private String uri;
/**
- * Default constructor.
+ * Creats a YANG name space object.
*/
public YangNameSpace() {
}
/**
- * Get the name space URI.
+ * Returns the name space URI.
*
* @return the URI
*/
@@ -52,7 +52,7 @@
}
/**
- * Set the name space URI.
+ * Sets the name space URI.
*
* @param uri the URI to set
*/
@@ -71,24 +71,22 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@Override
public void validateDataOnEntry() throws DataModelException {
// TODO auto-generated method stub, to be implemented by parser
-
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@Override
public void validateDataOnExit() throws DataModelException {
// TODO auto-generated method stub, to be implemented by parser
-
}
}
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangNode.java b/src/main/java/org/onosproject/yangutils/datamodel/YangNode.java
index 46c2318..beb8aa6 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangNode.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangNode.java
@@ -18,7 +18,7 @@
import org.onosproject.yangutils.datamodel.exceptions.DataModelException;
/**
- * Base class of a node in data model tree.
+ * Represents base class of a node in data model tree.
*/
public abstract class YangNode {
@@ -48,21 +48,21 @@
private YangNode previousSibling;
/**
- * Get the nodes name.
+ * Returns the nodes name.
*
* @return nodes name
*/
public abstract String getName();
/**
- * Set the nodes name.
+ * Sets the nodes name.
*
* @param name nodes name
*/
public abstract void setName(String name);
/**
- * Default constructor is made private to ensure node type is always set.
+ * Creates a YANG node object.
*/
@SuppressWarnings("unused")
private YangNode() {
@@ -70,7 +70,7 @@
}
/**
- * Create a specific type of node.
+ * Creates a specific type of node.
*
* @param type of YANG node
*/
@@ -79,7 +79,7 @@
}
/**
- * Get the node type.
+ * Returns the node type.
*
* @return node type
*/
@@ -88,7 +88,7 @@
}
/**
- * Set the node type.
+ * Sets the node type.
*
* @param nodeType type of node
*/
@@ -97,7 +97,7 @@
}
/**
- * Get the parent of node.
+ * Returns the parent of node.
*
* @return parent of node
*/
@@ -106,7 +106,7 @@
}
/**
- * Set the parent of node.
+ * Sets the parent of node.
*
* @param parent node
*/
@@ -115,7 +115,7 @@
}
/**
- * Get the first child of node.
+ * Returns the first child of node.
*
* @return first child of node
*/
@@ -124,7 +124,7 @@
}
/**
- * Set the first instance of a child node.
+ * Sets the first instance of a child node.
*
* @param child is only child to be set
*/
@@ -133,7 +133,7 @@
}
/**
- * Get the next sibling of node.
+ * Returns the next sibling of node.
*
* @return next sibling of node
*/
@@ -142,7 +142,7 @@
}
/**
- * Set the next sibling of node.
+ * Sets the next sibling of node.
*
* @param sibling YANG node
*/
@@ -151,7 +151,7 @@
}
/**
- * Get the previous sibling.
+ * Returns the previous sibling.
*
* @return previous sibling node
*/
@@ -160,7 +160,7 @@
}
/**
- * Set the previous sibling.
+ * Sets the previous sibling.
*
* @param previousSibling points to predecessor sibling
*/
@@ -169,7 +169,7 @@
}
/**
- * Add a child node, the children sibling list will be sorted based on node
+ * Adds a child node, the children sibling list will be sorted based on node
* type.
*
* @param newChild refers to a child to be added
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangNodeIdentifier.java b/src/main/java/org/onosproject/yangutils/datamodel/YangNodeIdentifier.java
index e5d56fc..871b683 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangNodeIdentifier.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangNodeIdentifier.java
@@ -17,7 +17,7 @@
package org.onosproject.yangutils.datamodel;
/**
- * YANG node identifier which is a combination of prefix and name.
+ * Represents YANG node identifier which is a combination of prefix and name.
*/
public class YangNodeIdentifier {
@@ -43,7 +43,7 @@
}
/**
- * Set name of the node identifier.
+ * Sets name of the node identifier.
*
* @param name name of the node identifier
*/
@@ -61,7 +61,7 @@
}
/**
- * Set prefix of the node identifier.
+ * Sets prefix of the node identifier.
*
* @param prefix prefix of the node identifier
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangNodeType.java b/src/main/java/org/onosproject/yangutils/datamodel/YangNodeType.java
index 991f2be..174ca39 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangNodeType.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangNodeType.java
@@ -16,7 +16,7 @@
package org.onosproject.yangutils.datamodel;
/**
- * Node type in data model tree corresponding to YANG schema.
+ * Represents node type in data model tree corresponding to YANG schema.
*/
public enum YangNodeType {
/**
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangNotification.java b/src/main/java/org/onosproject/yangutils/datamodel/YangNotification.java
index 8a43b07..e7b0241 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangNotification.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangNotification.java
@@ -18,6 +18,7 @@
import java.util.LinkedList;
import java.util.List;
+
import org.onosproject.yangutils.datamodel.exceptions.DataModelException;
import org.onosproject.yangutils.parser.Parsable;
import org.onosproject.yangutils.utils.YangConstructType;
@@ -71,10 +72,10 @@
*/
/**
- * Data model node to maintain information defined in YANG notification.
+ * Represents data model node to maintain information defined in YANG notification.
*/
public class YangNotification extends YangNode implements YangLeavesHolder, YangCommonInfo, Parsable,
- CollisionDetector {
+ CollisionDetector {
/**
* Name of the notification.
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangOutput.java b/src/main/java/org/onosproject/yangutils/datamodel/YangOutput.java
index d3aedaf..e9fa9c3 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangOutput.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangOutput.java
@@ -18,6 +18,7 @@
import java.util.LinkedList;
import java.util.List;
+
import org.onosproject.yangutils.datamodel.exceptions.DataModelException;
import org.onosproject.yangutils.parser.Parsable;
import org.onosproject.yangutils.utils.YangConstructType;
@@ -64,7 +65,7 @@
*/
/**
- * Data model node to maintain information defined in YANG output.
+ * Represents data model node to maintain information defined in YANG output.
*/
public class YangOutput extends YangNode implements YangLeavesHolder, Parsable, CollisionDetector {
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangPatternRestriction.java b/src/main/java/org/onosproject/yangutils/datamodel/YangPatternRestriction.java
index 2d111cb..1233b08 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangPatternRestriction.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangPatternRestriction.java
@@ -47,7 +47,7 @@
* +---------------+---------+-------------+
*/
/**
- * Pattern restriction information. The regular expression restriction on string
+ * Represents pattern restriction information. The regular expression restriction on string
* data type.
*/
public class YangPatternRestriction {
@@ -63,14 +63,14 @@
private List<String> basePattern;
/**
- * Default constructor.
+ * Creates a YANG pattern restriction object.
*/
public YangPatternRestriction() {
setPatternList(new LinkedList<String>());
}
/**
- * Get the pattern restriction defined for the current type.
+ * Returns the pattern restriction defined for the current type.
*
* @return pattern restriction defined for the current type.
*/
@@ -79,7 +79,7 @@
}
/**
- * Set the pattern restriction defined for the current type.
+ * Sets the pattern restriction defined for the current type.
*
* @param pattern pattern restriction defined for the current type..
*/
@@ -88,7 +88,7 @@
}
/**
- * Add a new pattern to the list of pattern restriction.
+ * Adds a new pattern to the list of pattern restriction.
*
* @param newPattern pattern restriction.
*/
@@ -97,7 +97,7 @@
}
/**
- * Get the pattern restriction defined in base type.
+ * Returns the pattern restriction defined in base type.
*
* @return pattern restriction defined in base type.
*/
@@ -106,7 +106,7 @@
}
/**
- * Set the pattern restriction defined in base type.
+ * Sets the pattern restriction defined in base type.
*
* @param basePattern pattern restriction defined in base type.
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangRangeInterval.java b/src/main/java/org/onosproject/yangutils/datamodel/YangRangeInterval.java
index d3061a7..442cda0 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangRangeInterval.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangRangeInterval.java
@@ -14,7 +14,7 @@
package org.onosproject.yangutils.datamodel;
/**
- * Single interval information of a range.
+ * Represents single interval information of a range.
*
* @param <T> range type based on the data type.
*/
@@ -31,13 +31,13 @@
private T endValue;
/**
- * Default constructor.
+ * Creates YANG range interval object.
*/
public YangRangeInterval() {
}
/**
- * Get the starting value of the range interval.
+ * Returns the starting value of the range interval.
*
* @return the starting value of the range interval.
*/
@@ -46,7 +46,7 @@
}
/**
- * Set the starting value of the range interval.
+ * Sets the starting value of the range interval.
*
* @param startValue the starting value of the range interval.
*/
@@ -55,7 +55,7 @@
}
/**
- * Get the last value of the range interval.
+ * Returns the last value of the range interval.
*
* @return last value of the range interval.
*/
@@ -64,7 +64,7 @@
}
/**
- * Set the last value of the range interval.
+ * Sets the last value of the range interval.
*
* @param endValue last value of the range interval.
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangRangeRestriction.java b/src/main/java/org/onosproject/yangutils/datamodel/YangRangeRestriction.java
index bca548e..09eb796 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangRangeRestriction.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangRangeRestriction.java
@@ -48,7 +48,7 @@
* for the type being restricted, respectively.
*/
/**
- * Ascending range restriction information.
+ * Represents ascending range restriction information.
*
* @param <T> range type (data type)
*/
@@ -81,35 +81,34 @@
private String description;
/**
- * Default constructor.
+ * Creates YANG range restriction object.
*/
public YangRangeRestriction() {
}
/**
- * Get the list of range interval restriction in ascending order.
+ * Returns the list of range interval restriction in ascending order.
*
- * @return list of range interval restriction in ascending order.
+ * @return list of range interval restriction in ascending order
*/
public List<YangRangeInterval<T>> getAscendingRangeIntervals() {
return ascendingRangeIntervals;
}
/**
- * Set the list of range interval restriction in ascending order.
+ * Sets the list of range interval restriction in ascending order.
*
- * @param rangeList list of range interval restriction in ascending order.
+ * @param rangeList list of range interval restriction in ascending order
*/
private void setAscendingRangeIntervals(List<YangRangeInterval<T>> rangeList) {
ascendingRangeIntervals = rangeList;
}
/**
- * Get the minimum valid value as per the restriction.
+ * Returns the minimum valid value as per the restriction.
*
- * @throws DataModelException data model exception for minimum restriction.
- *
- * @return minimum restricted value.
+ * @throws DataModelException data model exception for minimum restriction
+ * @return minimum restricted value
*/
public T getMinRestrictedvalue() throws DataModelException {
if (getAscendingRangeIntervals() == null) {
@@ -122,11 +121,10 @@
}
/**
- * Get the maximum valid value as per the restriction.
+ * Returns the maximum valid value as per the restriction.
*
- * @throws DataModelException data model exception for maximum restriction.
- *
- * @return minimum maximum value.
+ * @throws DataModelException data model exception for maximum restriction
+ * @return minimum maximum value
*/
public T getMaxRestrictedvalue() throws DataModelException {
if (getAscendingRangeIntervals() == null) {
@@ -140,11 +138,11 @@
}
/**
- * Add new interval to extend its range in the last. i.e. newly added
+ * Adds new interval to extend its range in the last. i.e. newly added
* interval needs to be bigger than the biggest interval in the list.
*
- * @param newInterval restricted length interval.
- * @throws DataModelException data model exception for range restriction.
+ * @param newInterval restricted length interval
+ * @throws DataModelException data model exception for range restriction
*/
public void addRangeRestrictionInterval(YangRangeInterval<T> newInterval) throws DataModelException {
@@ -173,9 +171,9 @@
}
/**
- * Get the textual reference of the length restriction.
+ * Returns the textual reference of the length restriction.
*
- * @return textual reference of the length restriction.
+ * @return textual reference of the length restriction
*/
@Override
public String getReference() {
@@ -183,9 +181,9 @@
}
/**
- * Set the textual reference of the length restriction.
+ * Sets the textual reference of the length restriction.
*
- * @param ref textual reference of the length restriction.
+ * @param ref textual reference of the length restriction
*/
@Override
public void setReference(String ref) {
@@ -193,9 +191,9 @@
}
/**
- * Get the description of the length restriction.
+ * Returns the description of the length restriction.
*
- * @return description of the length restriction.
+ * @return description of the length restriction
*/
@Override
public String getDescription() {
@@ -203,9 +201,9 @@
}
/**
- * Set the description of the length restriction.
+ * Sets the description of the length restriction.
*
- * @param desc description of the length restriction.
+ * @param desc description of the length restriction
*/
@Override
public void setDescription(String desc) {
@@ -214,9 +212,9 @@
}
/**
- * Get application's error message, to be used for data error.
+ * Returns application's error message, to be used for data error.
*
- * @return Application's error message, to be used for data error.
+ * @return Application's error message, to be used for data error
*/
@Override
public String getGetErrorMessage() {
@@ -224,9 +222,9 @@
}
/**
- * Set Application's error message, to be used for data error.
+ * Sets Application's error message, to be used for data error.
*
- * @param errMsg Application's error message, to be used for data error.
+ * @param errMsg Application's error message, to be used for data error
*/
@Override
public void setErrorMessage(String errMsg) {
@@ -235,9 +233,9 @@
}
/**
- * Get application's error tag, to be used for data error.
+ * Returns application's error tag, to be used for data error.
*
- * @return application's error tag, to be used for data error.
+ * @return application's error tag, to be used for data error
*/
@Override
public String getGetErrorAppTag() {
@@ -245,7 +243,7 @@
}
/**
- * Set application's error tag, to be used for data error.
+ * Sets application's error tag, to be used for data error.
*
* @param errTag application's error tag, to be used for data error.
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangReference.java b/src/main/java/org/onosproject/yangutils/datamodel/YangReference.java
index 8003f60..44397a3 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangReference.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangReference.java
@@ -20,17 +20,18 @@
* parsing and translator processing of reference.
*/
public interface YangReference {
+
/**
- * Get the textual reference.
+ * Returns the textual reference.
*
- * @return the reference.
+ * @return the reference
*/
String getReference();
/**
- * Set the textual reference.
+ * Sets the textual reference.
*
- * @param reference the reference to set.
+ * @param reference the reference to set
*/
void setReference(String reference);
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangResolutionInfo.java b/src/main/java/org/onosproject/yangutils/datamodel/YangResolutionInfo.java
index c9355f7..b6c2f7c 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangResolutionInfo.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangResolutionInfo.java
@@ -17,10 +17,11 @@
package org.onosproject.yangutils.datamodel;
import java.util.Stack;
+
import org.onosproject.yangutils.datamodel.exceptions.DataModelException;
/**
- * Resolution object which will be resolved by linker.
+ * Represents resolution object which will be resolved by linker.
*/
public class YangResolutionInfo<T> {
@@ -43,8 +44,8 @@
private boolean isResolved;
/*
- * Stack for type/uses is maintained for hierarchical references, this
- * is used during resolution.
+ * Stack for type/uses is maintained for hierarchical references, this is
+ * used during resolution.
*/
private Stack<T> partialResolvedStack;
@@ -72,8 +73,8 @@
* @param charPositionInLine error character position in line
*/
public YangResolutionInfo(T dataNode, ResolutionType resolutionType,
- YangNode holderNode, String prefix, int lineNumber,
- int charPositionInLine) {
+ YangNode holderNode, String prefix, int lineNumber,
+ int charPositionInLine) {
this.setHolderOfEntityToResolve(holderNode);
this.setEntityToResolve(dataNode);
this.setPrefix(prefix);
@@ -92,8 +93,8 @@
* @param charPositionInLine error character position in line
*/
public YangResolutionInfo(T dataNode, ResolutionType resolutionType,
- YangNode holderNode, int lineNumber,
- int charPositionInLine) {
+ YangNode holderNode, int lineNumber,
+ int charPositionInLine) {
this.setHolderOfEntityToResolve(holderNode);
this.setEntityToResolve(dataNode);
this.setLineNumber(lineNumber);
@@ -106,7 +107,7 @@
* @param resolutionInfoNodePrefix module/sub-module prefix
* @throws DataModelException DataModelException a violation of data model rules
*/
- public void resolveLinkingForResolutionInfo(String resolutionInfoNodePrefix) throws DataModelException {
+ public void resolveLinkingForResolutionInfo(String resolutionInfoNodePrefix) throws DataModelException {
this.resolutionInfoRootNodePrefix = resolutionInfoNodePrefix;
@@ -177,8 +178,8 @@
}
if (isMoreReferenceDetected) {
/*
- * If more reference are present, tree traversal must start
- * from first child again, to check the availability of
+ * If more reference are present, tree traversal must start from
+ * first child again, to check the availability of
* typedef/grouping.
*/
node = parentNode.getChild();
@@ -197,14 +198,14 @@
* @return flag to indicate whether resolution is done
* @throws DataModelException a violation of data model rules
*/
- private boolean resolveLinkingForNode(YangNode node, YangNode parentNode) throws
- DataModelException {
+ private boolean resolveLinkingForNode(YangNode node, YangNode parentNode) throws DataModelException {
+
/*
- * Check if name of node name matches with the entity name
- * under resolution.
+ * Check if name of node name matches with the entity name under
+ * resolution.
*/
if (isNodeNameSameAsResolutionInfoName(node)) {
- // Add reference of entity to the node under resolution.
+ // Adds reference of entity to the node under resolution.
addReferredEntityLink(node);
// Check if referred entity has further reference to uses/type.
if (!(isMoreReferencePresent(node))) {
@@ -212,7 +213,7 @@
resolveStackAndAddToStack(node);
return true;
} else {
- // Add referred type/uses to the stack.
+ // Adds referred type/uses to the stack.
addToPartialResolvedStack(node);
/*
* Check whether referred type is resolved, partially resolved
@@ -230,25 +231,25 @@
updateResolutionTypeToPartial();
return true;
} else {
- /*
- * Check if prefix is present to find that the derived
- * reference is for intra file or inter file, if it's
- * inter-file return and stop further processing.
- */
+ /*
+ * Check if prefix is present to find that the derived
+ * reference is for intra file or inter file, if it's
+ * inter-file return and stop further processing.
+ */
if (isExternalPrefixPresent(node)) {
/*
- * Update the resolution type to partially resolved for all
- * type/uses in stack
+ * Update the resolution type to partially resolved for
+ * all type/uses in stack
*/
updateResolutionTypeToPartial();
return true;
} else {
- /*
- * If prefix is not present it indicates intra-file
- * dependency in this case set the node back to first
- * child, as referred entity may appear in any order
- * and continue with the resolution.
- */
+ /*
+ * If prefix is not present it indicates intra-file
+ * dependency in this case set the node back to first
+ * child, as referred entity may appear in any order and
+ * continue with the resolution.
+ */
isMoreReferenceDetected = true;
return false;
}
@@ -265,26 +266,26 @@
*/
private void updateResolutionTypeToPartial() throws DataModelException {
// For all entries in stack calls for the resolution in type/uses.
- for (T entity:getPartialResolvedStack()) {
+ for (T entity : getPartialResolvedStack()) {
if (!(entity instanceof Resolvable)) {
throw new DataModelException("Data Model Exception: Entity to resolved is other than type/uses");
}
if (((Resolvable) entity).getResolvableStatus() == ResolvableStatus.UNRESOLVED) {
- // Set the resolution status in inside the type/uses.
+ // Sets the resolution status in inside the type/uses.
((Resolvable) entity).setResolvableStatus(ResolvableStatus.PARTIALLY_RESOLVED);
}
}
}
/**
- * Add referred type/uses to the stack and resolve the stack.
+ * Adds referred type/uses to the stack and resolve the stack.
*
* @param node typedef/grouping node
* @throws DataModelException a violation of data model rules
*/
private void resolveStackAndAddToStack(YangNode node) throws DataModelException {
if (getEntityToResolve() instanceof YangType) {
- // Add to the stack only for YANG typedef.
+ // Adds to the stack only for YANG typedef.
getPartialResolvedStack().push((T) ((YangTypeDef) node).getDataType());
}
// Don't add to stack in case of YANG grouping.
@@ -303,13 +304,13 @@
/*
* Checks if type is partially resolved.
*/
- if (((YangType) getPartialResolvedStack().peek()).getResolvableStatus() ==
- ResolvableStatus.PARTIALLY_RESOLVED) {
+ if (((YangType) getPartialResolvedStack().peek())
+ .getResolvableStatus() == ResolvableStatus.PARTIALLY_RESOLVED) {
return true;
}
} else if (getPartialResolvedStack().peek() instanceof YangUses) {
- if (((YangUses) getPartialResolvedStack().peek()).getResolvableStatus() ==
- ResolvableStatus.PARTIALLY_RESOLVED) {
+ if (((YangUses) getPartialResolvedStack().peek())
+ .getResolvableStatus() == ResolvableStatus.PARTIALLY_RESOLVED) {
return true;
}
}
@@ -326,13 +327,11 @@
/*
* Checks if type is partially resolved.
*/
- if (((YangType) getPartialResolvedStack().peek()).getResolvableStatus() ==
- ResolvableStatus.RESOLVED) {
+ if (((YangType) getPartialResolvedStack().peek()).getResolvableStatus() == ResolvableStatus.RESOLVED) {
return true;
}
} else if (getPartialResolvedStack().peek() instanceof YangUses) {
- if (((YangUses) getPartialResolvedStack().peek()).getResolvableStatus() ==
- ResolvableStatus.RESOLVED) {
+ if (((YangUses) getPartialResolvedStack().peek()).getResolvableStatus() == ResolvableStatus.RESOLVED) {
return true;
}
}
@@ -361,7 +360,6 @@
return false;
}
-
/**
* Check if node name is same as name in resolution info, i.e. name of
* typedef/grouping is same as name of type/uses.
@@ -387,7 +385,7 @@
}
/**
- * Add reference of grouping/typedef in uses/type.
+ * Adds reference of grouping/typedef in uses/type.
*
* @param node grouping/typedef node
* @throws DataModelException a violation of data model rules
@@ -457,30 +455,30 @@
*/
private void resolveCompleteStack() throws DataModelException {
// For all entries in stack calls for the resolution in type/uses.
- for (T entity:getPartialResolvedStack()) {
+ for (T entity : getPartialResolvedStack()) {
if (!(entity instanceof Resolvable)) {
throw new DataModelException("Data Model Exception: Entity to resolved is other than type/uses");
}
((Resolvable) entity).resolve();
- // Set the resolution status in inside the type/uses.
+ // Sets the resolution status in inside the type/uses.
((Resolvable) entity).setResolvableStatus(ResolvableStatus.RESOLVED);
}
/*
- * Set the resolution status in resolution info present in resolution
+ * Sets the resolution status in resolution info present in resolution
* list.
*/
setIsResolved(true);
}
/**
- * Add to partial resolved stack.
+ * Adds to partial resolved stack.
*
* @param node grouping/typedef node
* @throws DataModelException a violation of data model rules
*/
private void addToPartialResolvedStack(YangNode node) throws DataModelException {
if (getPartialResolvedStack().peek() instanceof YangType) {
- // Add to the stack only for YANG typedef.
+ // Adds to the stack only for YANG typedef.
getPartialResolvedStack().push((T) ((YangTypeDef) node).getDataType());
} else if (getPartialResolvedStack().peek() instanceof YangUses) {
getPartialResolvedStack().push((T) getUsesInGrouping(node));
@@ -522,7 +520,7 @@
}
/**
- * Set prefix of imported module.
+ * Sets prefix of imported module.
*
* @param prefix of imported module
*/
@@ -540,7 +538,7 @@
}
/**
- * Set parsable entity to be resolved.
+ * Sets parsable entity to be resolved.
*
* @param entityToResolve YANG entity to be resolved
*/
@@ -558,7 +556,7 @@
}
/**
- * Set parent YANG node holder for the entity to be resolved.
+ * Sets parent YANG node holder for the entity to be resolved.
*
* @param holderOfEntityToResolve parent YANG node holder
*/
@@ -576,7 +574,7 @@
}
/**
- * Set error position.
+ * Sets error position.
*
* @param charPosition position of error
*/
@@ -594,7 +592,7 @@
}
/**
- * Set error character position in line.
+ * Sets error character position in line.
*
* @param lineNumber error character position in line
*/
@@ -612,7 +610,7 @@
}
/**
- * Set status of resolution.
+ * Sets status of resolution.
*
* @param isResolved resolution status
*/
@@ -630,7 +628,7 @@
}
/**
- * Set stack of YANG type with partially resolved YANG construct hierarchy.
+ * Sets stack of YANG type with partially resolved YANG construct hierarchy.
*
* @param partialResolvedStack partial resolved YANG construct stack
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangRevision.java b/src/main/java/org/onosproject/yangutils/datamodel/YangRevision.java
index 511f751..26932f4 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangRevision.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangRevision.java
@@ -40,7 +40,7 @@
* +--------------+---------+-------------+------------------+
*/
/**
- * Maintains the information about the revision.
+ * Represents the information about the revision.
*/
public class YangRevision implements YangDesc, YangReference, Parsable {
@@ -60,13 +60,13 @@
private String reference;
/**
- * Default constructor.
+ * Creates a YANG revision object.
*/
public YangRevision() {
}
/**
- * Get the revision date.
+ * Returns the revision date.
*
* @return the revision date
*/
@@ -75,7 +75,7 @@
}
/**
- * Set the revision date.
+ * Sets the revision date.
*
* @param revDate the revision date to set
*/
@@ -84,7 +84,7 @@
}
/**
- * Get the description.
+ * Returns the description.
*
* @return the description
*/
@@ -94,7 +94,7 @@
}
/**
- * Set the description.
+ * Sets the description.
*
* @param description set the description
*/
@@ -104,7 +104,7 @@
}
/**
- * Get the textual reference.
+ * Returns the textual reference.
*
* @return the reference
*/
@@ -114,7 +114,7 @@
}
/**
- * Set the textual reference.
+ * Sets the textual reference.
*
* @param reference the reference to set
*/
@@ -134,7 +134,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -145,7 +145,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangRpc.java b/src/main/java/org/onosproject/yangutils/datamodel/YangRpc.java
index ff32eff..15a6626 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangRpc.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangRpc.java
@@ -54,10 +54,10 @@
*/
/**
- * Data model node to maintain information defined in YANG rpc.
+ * Represents data model node to maintain information defined in YANG rpc.
*/
public class YangRpc extends YangNode implements YangCommonInfo, Parsable,
- CollisionDetector {
+ CollisionDetector {
/**
* Name of the rpc.
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangStatus.java b/src/main/java/org/onosproject/yangutils/datamodel/YangStatus.java
index 6ff3b55..2b3c626 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangStatus.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangStatus.java
@@ -18,15 +18,16 @@
* translator processing of status.
*/
public interface YangStatus {
+
/**
- * Get the status.
+ * Returns the status.
*
* @return the status
*/
YangStatusType getStatus();
/**
- * Set the status.
+ * Sets the status.
*
* @param status the status to set
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangStringRestriction.java b/src/main/java/org/onosproject/yangutils/datamodel/YangStringRestriction.java
index 1cdfa15..50a1f83 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangStringRestriction.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangStringRestriction.java
@@ -25,7 +25,7 @@
*
*/
/**
- * The restriction for string data type.
+ * Represents the restriction for string data type.
*/
public class YangStringRestriction {
@@ -75,51 +75,51 @@
private YangPatternRestriction patternRestriction;
/**
- * Default constructor.
+ * Creates a YANG string restriction object.
*/
public YangStringRestriction() {
}
/**
- * Get the length restriction on the string data.
+ * Returns the length restriction on the string data.
*
- * @return length restriction on the string data.
+ * @return length restriction on the string data
*/
public YangRangeRestriction<BigInteger> getLengthRestriction() {
return lengthRestriction;
}
/**
- * Set the length restriction on the string data.
+ * Sets the length restriction on the string data.
*
- * @param lengthRestriction length restriction on the string data.
+ * @param lengthRestriction length restriction on the string data
*/
public void setLengthRestriction(YangRangeRestriction<BigInteger> lengthRestriction) {
this.lengthRestriction = lengthRestriction;
}
/**
- * Get the pattern restriction for the type.
+ * Returns the pattern restriction for the type.
*
- * @return pattern restriction for the type.
+ * @return pattern restriction for the type
*/
public YangPatternRestriction getPatternRestriction() {
return patternRestriction;
}
/**
- * Set the pattern restriction for the type.
+ * Sets the pattern restriction for the type.
*
- * @param patternRestriction pattern restriction for the type.
+ * @param patternRestriction pattern restriction for the type
*/
private void setPatternRestriction(YangPatternRestriction patternRestriction) {
this.patternRestriction = patternRestriction;
}
/**
- * Add a new pattern restriction for the type.
+ * Adds a new pattern restriction for the type.
*
- * @param newPattern new pattern restriction for the type.
+ * @param newPattern new pattern restriction for the type
*/
public void addPattern(String newPattern) {
if (getPatternRestriction() == null) {
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangSubModule.java b/src/main/java/org/onosproject/yangutils/datamodel/YangSubModule.java
index 04da5e4..68c2ea4 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangSubModule.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangSubModule.java
@@ -17,6 +17,7 @@
import java.util.LinkedList;
import java.util.List;
+
import org.onosproject.yangutils.datamodel.exceptions.DataModelException;
import org.onosproject.yangutils.parser.Parsable;
import org.onosproject.yangutils.utils.YangConstructType;
@@ -72,7 +73,7 @@
* +--------------+---------+-------------+------------------+
*/
/**
- * Data model node to maintain information defined in YANG sub-module.
+ * Represents data model node to maintain information defined in YANG sub-module.
*/
public class YangSubModule extends YangNode
implements YangLeavesHolder, YangDesc, YangReference, Parsable, CollisionDetector, HasResolutionInfo {
@@ -183,7 +184,7 @@
*/
private List<YangResolutionInfo> unresolvedResolutionList;
/**
- * Create a sub module node.
+ * Creates a sub module node.
*/
public YangSubModule() {
super(YangNodeType.SUB_MODULE_NODE);
@@ -195,7 +196,7 @@
}
/**
- * Get the YANG name of the sub module.
+ * Returns the YANG name of the sub module.
*
* @return YANG name of the sub module
*/
@@ -205,7 +206,7 @@
}
/**
- * Set YANG name of the sub module.
+ * Sets YANG name of the sub module.
*
* @param subModuleName YANG name of the sub module
*/
@@ -215,7 +216,7 @@
}
/**
- * Get the module info.
+ * Returns the module info.
*
* @return the belongs to info
*/
@@ -224,7 +225,7 @@
}
/**
- * Set the module info.
+ * Sets the module info.
*
* @param belongsTo module info to set
*/
@@ -233,7 +234,7 @@
}
/**
- * Get the contact.
+ * Returns the contact.
*
* @return the contact
*/
@@ -242,7 +243,7 @@
}
/**
- * Set the contact.
+ * Sets the contact.
*
* @param contact the contact to set
*/
@@ -251,7 +252,7 @@
}
/**
- * Get the description.
+ * Returns the description.
*
* @return the description
*/
@@ -261,7 +262,7 @@
}
/**
- * Set the description.
+ * Sets the description.
*
* @param description set the description
*/
@@ -271,7 +272,7 @@
}
/**
- * Get the list of imported modules.
+ * Returns the list of imported modules.
*
* @return the list of imported modules
*/
@@ -280,7 +281,7 @@
}
/**
- * Add the imported module information to the import list.
+ * Adds the imported module information to the import list.
*
* @param importedModule module being imported
*/
@@ -294,7 +295,7 @@
}
/**
- * Get the list of included sub modules.
+ * Returns the list of included sub modules.
*
* @return the included list of sub modules
*/
@@ -303,7 +304,7 @@
}
/**
- * Add the included sub module information to the include list.
+ * Returns the included sub module information to the include list.
*
* @param includeModule submodule being included
*/
@@ -335,7 +336,7 @@
}
/**
- * Get the list of leaves.
+ * Returns the list of leaves.
*
* @return the list of leaves
*/
@@ -345,7 +346,7 @@
}
/**
- * Add a leaf.
+ * Adds a leaf.
*
* @param leaf the leaf to be added
*/
@@ -355,7 +356,7 @@
}
/**
- * Get the list of leaf-list.
+ * Returns the list of leaf-list.
*
* @return the list of leaf-list
*/
@@ -365,7 +366,7 @@
}
/**
- * Add a leaf-list.
+ * Adds a leaf-list.
*
* @param leafList the leaf-list to be added
*/
@@ -375,7 +376,7 @@
}
/**
- * Get the sub-modules organization.
+ * Returns the sub-modules organization.
*
* @return the organization
*/
@@ -384,7 +385,7 @@
}
/**
- * Set the sub-modules organization.
+ * Sets the sub-modules organization.
*
* @param org the organization to set
*/
@@ -393,7 +394,7 @@
}
/**
- * Get the textual reference.
+ * Returns the textual reference.
*
* @return the reference
*/
@@ -403,7 +404,7 @@
}
/**
- * Set the textual reference.
+ * Sets the textual reference.
*
* @param reference the reference to set
*/
@@ -413,7 +414,7 @@
}
/**
- * Get the revision.
+ * Returns the revision.
*
* @return the revision
*/
@@ -422,7 +423,7 @@
}
/**
- * Set the revision.
+ * Sets the revision.
*
* @param revision the revision to set
*/
@@ -431,7 +432,7 @@
}
/**
- * Get the version.
+ * Returns the version.
*
* @return the version
*/
@@ -440,7 +441,7 @@
}
/**
- * Set the version.
+ * Sets the version.
*
* @param version the version to set
*/
@@ -459,7 +460,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -469,7 +470,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangType.java b/src/main/java/org/onosproject/yangutils/datamodel/YangType.java
index 222cad5..37d8a05 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangType.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangType.java
@@ -45,7 +45,7 @@
*/
/**
- * Maintains the data type information.
+ * Represents the data type information.
*
* @param <T> YANG data type info
*/
@@ -94,7 +94,7 @@
private ResolvableStatus resolvableStatus;
/**
- * Default constructor.
+ * Creates a YANG type object.
*/
public YangType() {
@@ -112,7 +112,7 @@
}
/**
- * Set prefix associated with data type name.
+ * Sets prefix associated with data type name.
*
* @param prefix prefix associated with data type name
*/
@@ -121,7 +121,7 @@
}
/**
- * Get the name of data type.
+ * Returns the name of data type.
*
* @return the name of data type
*/
@@ -130,7 +130,7 @@
}
/**
- * Set the name of the data type.
+ * Sets the name of the data type.
*
* @param typeName the name to set
*/
@@ -139,7 +139,7 @@
}
/**
- * Get the Java package where the type is defined.
+ * Returns the Java package where the type is defined.
*
* @return Java package where the type is defined
*/
@@ -148,7 +148,7 @@
}
/**
- * Set Java package where the type is defined.
+ * Sets Java package where the type is defined.
*
* @param javaPackage Java package where the type is defined
*/
@@ -157,7 +157,7 @@
}
/**
- * Get the type of data.
+ * Returns the type of data.
*
* @return the data type
*/
@@ -166,7 +166,7 @@
}
/**
- * Set the type of data.
+ * Sets the type of data.
*
* @param dataType data type
*/
@@ -175,7 +175,7 @@
}
/**
- * Get the data type meta data.
+ * Returns the data type meta data.
*
* @return the data type meta data
*/
@@ -184,7 +184,7 @@
}
/**
- * Set the data type meta data.
+ * Sets the data type meta data.
*
* @param dataTypeInfo the meta data to set
*/
@@ -202,7 +202,7 @@
}
/**
- * Set node identifier.
+ * Sets node identifier.
*
* @param nodeIdentifier the node identifier
*/
@@ -220,7 +220,7 @@
}
/**
- * Set effective built-in type.
+ * Sets effective built-in type.
*
* @param effectiveBuiltInType effective built-in type
*/
@@ -238,7 +238,7 @@
}
/**
- * Set effective pattern restriction.
+ * Sets effective pattern restriction.
*
* @param effectivePatternRestriction effective pattern restriction
*/
@@ -257,7 +257,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -268,7 +268,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangTypeDef.java b/src/main/java/org/onosproject/yangutils/datamodel/YangTypeDef.java
index 8cd80c3..7b0204c 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangTypeDef.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangTypeDef.java
@@ -49,7 +49,7 @@
* +--------------+---------+-------------+------------------+
*/
/**
- * Data model node to maintain information defined in YANG typedef.
+ * Represents data model node to maintain information defined in YANG typedef.
*/
public class YangTypeDef extends YangNode implements YangCommonInfo, Parsable {
@@ -90,7 +90,7 @@
private String units;
/**
- * Create a typedef node.
+ * Creates a typedef node.
*/
public YangTypeDef() {
super(YangNodeType.TYPEDEF_NODE);
@@ -106,7 +106,7 @@
}
/**
- * Set the default value.
+ * Sets the default value.
*
* @param defaultValueInString the default value
*/
@@ -125,7 +125,7 @@
}
/**
- * Set the description.
+ * Sets the description.
*
* @param description set the description
*/
@@ -145,7 +145,7 @@
}
/**
- * Set the textual reference.
+ * Sets the textual reference.
*
* @param reference the reference to set
*/
@@ -165,7 +165,7 @@
}
/**
- * Set the status.
+ * Sets the status.
*
* @param status the status to set
*/
@@ -184,7 +184,7 @@
}
/**
- * Set the data type.
+ * Sets the data type.
*
* @param dataType the data type
*/
@@ -202,7 +202,7 @@
}
/**
- * Set the unit.
+ * Sets the unit.
*
* @param units the units to set
*/
@@ -221,7 +221,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -231,7 +231,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -251,7 +251,7 @@
}
/**
- * Set YANG name of the typedef.
+ * Sets YANG name of the typedef.
*
* @param name YANG name of the typedef
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangUnion.java b/src/main/java/org/onosproject/yangutils/datamodel/YangUnion.java
index f280bde..5170871 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangUnion.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangUnion.java
@@ -16,13 +16,13 @@
package org.onosproject.yangutils.datamodel;
+import java.util.LinkedList;
+import java.util.List;
+
import org.onosproject.yangutils.datamodel.exceptions.DataModelException;
import org.onosproject.yangutils.parser.Parsable;
import org.onosproject.yangutils.utils.YangConstructType;
-import java.util.LinkedList;
-import java.util.List;
-
/*
* Reference RFC 6020.
*
@@ -46,7 +46,7 @@
*/
/**
- * Data model node to maintain information defined in YANG union.
+ * Represents data model node to maintain information defined in YANG union.
*/
public class YangUnion implements Parsable {
@@ -57,7 +57,7 @@
private String unionName;
/**
- * Create a YANG union node.
+ * Creates a YANG union node.
*/
public YangUnion() {
typeList = new LinkedList<>();
@@ -82,7 +82,7 @@
}
/**
- * Set the list of YANG type.
+ * Sets the list of YANG type.
*
* @param typeList list of YANG type.
*/
@@ -91,7 +91,7 @@
}
/**
- * Add YANG type to type list.
+ * Adds YANG type to type list.
*
* @param yangType YANG type to be added to list
* @throws DataModelException union member type must not be one of the
@@ -106,7 +106,7 @@
}
/**
- * Set the union name.
+ * Sets the union name.
*
* @param unionName name of the union.
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/YangUses.java b/src/main/java/org/onosproject/yangutils/datamodel/YangUses.java
index 7d0e7ea..c4025b6 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/YangUses.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/YangUses.java
@@ -49,8 +49,7 @@
* +--------------+---------+-------------+------------------+
*/
/**
- * Data model node to maintain information defined in YANG uses.
- *
+ * Represents data model node to maintain information defined in YANG uses.
*/
public class YangUses extends YangNode implements YangCommonInfo, Parsable, Resolvable {
@@ -88,7 +87,7 @@
private ResolvableStatus resolvableStatus;
/**
- * Create an YANG uses node.
+ * Creates an YANG uses node.
*/
public YangUses() {
super(YangNodeType.USES_NODE);
@@ -106,7 +105,7 @@
}
/**
- * Set the referred group.
+ * Sets the referred group.
*
* @param refGroup the referred group
*/
@@ -125,7 +124,7 @@
}
/**
- * Set the description.
+ * Sets the description.
*
* @param description set the description
*/
@@ -145,7 +144,7 @@
}
/**
- * Set the textual reference.
+ * Sets the textual reference.
*
* @param reference the reference to set
*/
@@ -165,7 +164,7 @@
}
/**
- * Set the status.
+ * Sets the status.
*
* @param status the status to set
*/
@@ -185,7 +184,7 @@
}
/**
- * Validate the data on entering the corresponding parse tree node.
+ * Validates the data on entering the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -195,7 +194,7 @@
}
/**
- * Validate the data on exiting the corresponding parse tree node.
+ * Validates the data on exiting the corresponding parse tree node.
*
* @throws DataModelException a violation of data model rules
*/
@@ -224,7 +223,7 @@
}
/**
- * Set node identifier.
+ * Sets node identifier.
*
* @param nodeIdentifier the node identifier
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/exceptions/DataModelException.java b/src/main/java/org/onosproject/yangutils/datamodel/exceptions/DataModelException.java
index 79f6764..b1375a7 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/exceptions/DataModelException.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/exceptions/DataModelException.java
@@ -16,7 +16,7 @@
package org.onosproject.yangutils.datamodel.exceptions;
/**
- * Base class for exceptions in data model operations.
+ * Represents base class for exceptions in data model operations.
*/
public class DataModelException extends Exception {
@@ -25,7 +25,7 @@
private int charPositionInLine;
/**
- * Constructor to create a data model exception with message.
+ * Creates a data model exception with message.
*
* @param message the detail of exception in string
*/
@@ -34,7 +34,7 @@
}
/**
- * Constructor to create exception from message and cause.
+ * Creates exception from message and cause.
*
* @param message the detail of exception in string
* @param cause underlying cause of the error
@@ -44,7 +44,7 @@
}
/**
- * Constructor to create exception from cause.
+ * Creates exception from cause.
*
* @param cause underlying cause of the error
*/
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/utils/DataModelUtils.java b/src/main/java/org/onosproject/yangutils/datamodel/utils/DataModelUtils.java
index 9c3e5ec..76e8f36 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/utils/DataModelUtils.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/utils/DataModelUtils.java
@@ -17,6 +17,7 @@
package org.onosproject.yangutils.datamodel.utils;
import java.util.List;
+
import org.onosproject.yangutils.datamodel.CollisionDetector;
import org.onosproject.yangutils.datamodel.HasResolutionInfo;
import org.onosproject.yangutils.datamodel.YangLeaf;
@@ -28,7 +29,7 @@
import org.onosproject.yangutils.utils.YangConstructType;
/**
- * Utilities for data model tree.
+ * Represents utilities for data model tree.
*/
public final class DataModelUtils {
@@ -49,6 +50,7 @@
*/
public static void detectCollidingChildUtil(String identifierName, YangConstructType dataType, YangNode node)
throws DataModelException {
+
if (dataType == YangConstructType.LEAF_DATA) {
YangLeavesHolder leavesHolder = (YangLeavesHolder) node;
if (leavesHolder.getListOfLeaf() != null) {
@@ -78,8 +80,9 @@
* checked
* @throws DataModelException a violation of data model rules
*/
- private static void detectCollidingLeaf(YangLeavesHolder leavesHolder, String identifierName) throws
- DataModelException {
+ private static void detectCollidingLeaf(YangLeavesHolder leavesHolder, String identifierName)
+ throws DataModelException {
+
for (YangLeaf leaf : leavesHolder.getListOfLeaf()) {
if (leaf.getLeafName().equals(identifierName)) {
throw new DataModelException("YANG file error: Duplicate input identifier detected, same as leaf \""
@@ -96,8 +99,9 @@
* checked
* @throws DataModelException a violation of data model rules
*/
- private static void detectCollidingLeafList(YangLeavesHolder leavesHolder, String identifierName) throws
- DataModelException {
+ private static void detectCollidingLeafList(YangLeavesHolder leavesHolder, String identifierName)
+ throws DataModelException {
+
for (YangLeafList leafList : leavesHolder.getListOfLeafList()) {
if (leafList.getLeafName().equals(identifierName)) {
throw new DataModelException("YANG file error: Duplicate input identifier detected, same as leaf " +
@@ -114,6 +118,7 @@
* @throws DataModelException a violation of data model rules
*/
public static void addResolutionInfo(YangResolutionInfo resolutionInfo) throws DataModelException {
+
/* get the module node to add maintain the list of nested reference */
YangNode curNode = resolutionInfo.getHolderOfEntityToResolve();
while (!(curNode instanceof HasResolutionInfo)) {
@@ -134,8 +139,9 @@
* @throws DataModelException a violation of data model rules
*/
public static void resolveLinkingForResolutionList(List<YangResolutionInfo> resolutionList,
- HasResolutionInfo resolutionInfoNode)
+ HasResolutionInfo resolutionInfoNode)
throws DataModelException {
+
for (YangResolutionInfo resolutionInfo : resolutionList) {
if (resolutionInfo.getPrefix() == null ||
resolutionInfo.getPrefix().equals(resolutionInfoNode.getPrefix())) {
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/utils/GeneratedLanguage.java b/src/main/java/org/onosproject/yangutils/datamodel/utils/GeneratedLanguage.java
index 96fcbc0..e2471cd 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/utils/GeneratedLanguage.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/utils/GeneratedLanguage.java
@@ -16,7 +16,7 @@
package org.onosproject.yangutils.datamodel.utils;
/**
- * The target language in which the YANG information is modeled.
+ * Represents the target language in which the YANG information is modeled.
*/
public enum GeneratedLanguage {
/**
diff --git a/src/main/java/org/onosproject/yangutils/datamodel/utils/YangDataModelFactory.java b/src/main/java/org/onosproject/yangutils/datamodel/utils/YangDataModelFactory.java
index 2f24bf3..6edd6a6 100644
--- a/src/main/java/org/onosproject/yangutils/datamodel/utils/YangDataModelFactory.java
+++ b/src/main/java/org/onosproject/yangutils/datamodel/utils/YangDataModelFactory.java
@@ -46,12 +46,12 @@
import org.onosproject.yangutils.translator.exception.TranslatorException;
/**
- * Factory to create data model objects based on the target file type.
+ *Represents factory to create data model objects based on the target file type.
*/
public final class YangDataModelFactory {
/**
- * Utility class, hence private to prevent creating objects.
+ * Creates a YANG data model factory object.
*/
private YangDataModelFactory() {
}
@@ -75,7 +75,7 @@
}
/**
- * Based on the target language generate the inherited data model node.
+ * Returns based on the target language generate the inherited data model node.
*
* @param targetLanguage target language in which YANG mapping needs to be
* generated
@@ -93,7 +93,7 @@
}
/**
- * Based on the target language generate the inherited data model node.
+ * Returns based on the target language generate the inherited data model node.
*
* @param targetLanguage target language in which YANG mapping needs to be
* generated
@@ -111,7 +111,7 @@
}
/**
- * Based on the target language generate the inherited data model node.
+ * Returns based on the target language generate the inherited data model node.
*
* @param targetLanguage target language in which YANG mapping needs to be
* generated
@@ -129,7 +129,7 @@
}
/**
- * Based on the target language generate the inherited data model node.
+ * Returns based on the target language generate the inherited data model node.
*
* @param targetLanguage target language in which YANG mapping needs to be
* generated
@@ -147,7 +147,7 @@
}
/**
- * Based on the target language generate the inherited data model node.
+ * Returns based on the target language generate the inherited data model node.
*
* @param targetLanguage target language in which YANG mapping needs to be
* generated
@@ -165,7 +165,7 @@
}
/**
- * Based on the target language generate the inherited data model node.
+ * Returns based on the target language generate the inherited data model node.
*
* @param targetLanguage target language in which YANG mapping needs to be
* generated
@@ -183,7 +183,7 @@
}
/**
- * Based on the target language generate the inherited data model node.
+ * Returns based on the target language generate the inherited data model node.
*
* @param targetLanguage target language in which YANG mapping needs to be
* generated
@@ -201,7 +201,7 @@
}
/**
- * Based on the target language generate the inherited data model node.
+ * Returns based on the target language generate the inherited data model node.
*
* @param targetLanguage target language in which YANG mapping needs to be
* generated
@@ -219,7 +219,7 @@
}
/**
- * Based on the target language generate the inherited data model node.
+ * Returns based on the target language generate the inherited data model node.
*
* @param targetLanguage target language in which YANG mapping needs to be
* generated
@@ -237,7 +237,7 @@
}
/**
- * Based on the target language generate the inherited data model node.
+ * Returns based on the target language generate the inherited data model node.
*
* @param targetLanguage target language in which YANG mapping needs to be
* generated
@@ -255,7 +255,7 @@
}
/**
- * Based on the target language generate the inherited data model node.
+ * Returns based on the target language generate the inherited data model node.
*
* @param targetLanguage target language in which YANG mapping needs to be
* generated
@@ -273,7 +273,7 @@
}
/**
- * Based on the target language generate the inherited data model node.
+ * Returns based on the target language generate the inherited data model node.
*
* @param targetLanguage target language in which YANG mapping needs to be
* generated
@@ -291,7 +291,7 @@
}
/**
- * Based on the target language generate the inherited data model node.
+ * Returns based on the target language generate the inherited data model node.
*
* @param targetLanguage target language in which YANG mapping needs to be
* generated