diff --git a/utils/yangutils/src/main/java/org/onosproject/yangutils/datamodel/ResolvableStatus.java b/utils/yangutils/src/main/java/org/onosproject/yangutils/datamodel/ResolvableStatus.java
index 2514441..d1cacb4 100644
--- a/utils/yangutils/src/main/java/org/onosproject/yangutils/datamodel/ResolvableStatus.java
+++ b/utils/yangutils/src/main/java/org/onosproject/yangutils/datamodel/ResolvableStatus.java
@@ -40,6 +40,6 @@
     /**
      * Identifies that resolvable entity is resolved.
      */
-    RESOLVED;
+    RESOLVED
 
 }
diff --git a/utils/yangutils/src/main/java/org/onosproject/yangutils/datamodel/YangLeavesHolder.java b/utils/yangutils/src/main/java/org/onosproject/yangutils/datamodel/YangLeavesHolder.java
index fd22a99..37ecc8f 100644
--- a/utils/yangutils/src/main/java/org/onosproject/yangutils/datamodel/YangLeavesHolder.java
+++ b/utils/yangutils/src/main/java/org/onosproject/yangutils/datamodel/YangLeavesHolder.java
@@ -1,5 +1,5 @@
 /*
- * Copyright 2016 Open Networking Laboratory
+ * Copyright 2016-present 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.
@@ -28,28 +28,28 @@
     /**
      * Returns the list of leaves from data holder like container / list.
      *
-     * @return the list of leaves.
+     * @return the list of leaves
      */
-    public List<YangLeaf> getListOfLeaf();
+    List<YangLeaf> getListOfLeaf();
 
     /**
-     * Add a leaf in data holder like container / list.
+     * Adds leaf in data holder like container / list.
      *
-     * @param leaf the leaf to be added.
+     * @param leaf the leaf to be added
      */
     void addLeaf(YangLeaf leaf);
 
     /**
      * Returns the list of leaf-list from data holder like container / list.
      *
-     * @return the list of leaf-list.
+     * @return the list of leaf-list
      */
     List<YangLeafList> getListOfLeafList();
 
     /**
-     * Add a leaf-list in data holder like container / list.
+     * Adds leaf-list in data holder like container / list.
      *
-     * @param leafList the leaf-list to be added.
+     * @param leafList the leaf-list to be added
      */
     void addLeafList(YangLeafList leafList);
 }
diff --git a/utils/yangutils/src/main/java/org/onosproject/yangutils/datamodel/utils/GeneratedLanguage.java b/utils/yangutils/src/main/java/org/onosproject/yangutils/datamodel/utils/GeneratedLanguage.java
index e2471cd..37d2161 100644
--- a/utils/yangutils/src/main/java/org/onosproject/yangutils/datamodel/utils/GeneratedLanguage.java
+++ b/utils/yangutils/src/main/java/org/onosproject/yangutils/datamodel/utils/GeneratedLanguage.java
@@ -20,7 +20,7 @@
  */
 public enum GeneratedLanguage {
     /**
-     * Java.
+     * Target language is java.
      */
-    JAVA_GENERATION;
+    JAVA_GENERATION
 }
diff --git a/utils/yangutils/src/main/java/org/onosproject/yangutils/parser/impl/YangUtilsParserManager.java b/utils/yangutils/src/main/java/org/onosproject/yangutils/parser/impl/YangUtilsParserManager.java
index a1fffb8..6a5b1d2 100644
--- a/utils/yangutils/src/main/java/org/onosproject/yangutils/parser/impl/YangUtilsParserManager.java
+++ b/utils/yangutils/src/main/java/org/onosproject/yangutils/parser/impl/YangUtilsParserManager.java
@@ -43,12 +43,11 @@
          * Create a char stream that reads from YANG file. Throws an exception
          * in case input YANG file is either null or non existent.
          */
-        ANTLRInputStream input = null;
+        ANTLRInputStream input;
         try {
             input = new ANTLRFileStream(yangFile);
         } catch (IOException e) {
-            e.printStackTrace();
-            throw e;
+            throw new ParserException("YANG file error : YANG file does not exist.");
         }
 
         // Create a lexer that feeds off of input char stream.
diff --git a/utils/yangutils/src/main/java/org/onosproject/yangutils/parser/impl/listeners/StatusListener.java b/utils/yangutils/src/main/java/org/onosproject/yangutils/parser/impl/listeners/StatusListener.java
index b91003b..4c2abf9 100644
--- a/utils/yangutils/src/main/java/org/onosproject/yangutils/parser/impl/listeners/StatusListener.java
+++ b/utils/yangutils/src/main/java/org/onosproject/yangutils/parser/impl/listeners/StatusListener.java
@@ -22,10 +22,10 @@
 import org.onosproject.yangutils.parser.antlrgencode.GeneratedYangParser;
 import org.onosproject.yangutils.parser.exceptions.ParserException;
 import org.onosproject.yangutils.parser.impl.TreeWalkListener;
+import org.onosproject.yangutils.utils.YangConstructType;
 
 import static org.onosproject.yangutils.parser.impl.parserutils.ListenerErrorLocation.ENTRY;
 import static org.onosproject.yangutils.parser.impl.parserutils.ListenerErrorMessageConstruction.constructListenerErrorMessage;
-import static org.onosproject.yangutils.parser.impl.parserutils.ListenerErrorType.INVALID_CONTENT;
 import static org.onosproject.yangutils.parser.impl.parserutils.ListenerErrorType.INVALID_HOLDER;
 import static org.onosproject.yangutils.parser.impl.parserutils.ListenerErrorType.MISSING_HOLDER;
 import static org.onosproject.yangutils.parser.impl.parserutils.ListenerUtil.removeQuotesAndHandleConcat;
@@ -44,7 +44,7 @@
  *                        deprecated-keyword
  *
  * ANTLR grammar rule
- * statusStatement : STATUS_KEYWORD (CURRENT_KEYWORD | OBSOLETE_KEYWORD | DEPRECATED_KEYWORD) STMTEND;
+ * statusStatement : STATUS_KEYWORD status STMTEND;
  */
 
 /**
@@ -99,14 +99,27 @@
         YangStatusType status;
 
         String value = removeQuotesAndHandleConcat(ctx.status().getText());
-        if (value.equals(CURRENT_KEYWORD)) {
-            status = YangStatusType.CURRENT;
-        } else if (value.equals(DEPRECATED_KEYWORD)) {
-            status = YangStatusType.DEPRECATED;
-        } else if (value.equals(OBSOLETE_KEYWORD)) {
-            status = YangStatusType.OBSOLETE;
-        } else {
-            throw new ParserException(constructListenerErrorMessage(INVALID_CONTENT, STATUS_DATA, value, ENTRY));
+        switch (value) {
+            case CURRENT_KEYWORD: {
+                status = YangStatusType.CURRENT;
+                break;
+            }
+            case DEPRECATED_KEYWORD: {
+                status = YangStatusType.DEPRECATED;
+                break;
+            }
+            case OBSOLETE_KEYWORD: {
+                status = YangStatusType.OBSOLETE;
+                break;
+            }
+            default: {
+                ParserException parserException = new ParserException("YANG file error : " +
+                        YangConstructType.getYangConstructType(STATUS_DATA) + " " + ctx.status().getText() +
+                        " is not valid.");
+                parserException.setLine(ctx.getStart().getLine());
+                parserException.setCharPosition(ctx.getStart().getCharPositionInLine());
+                throw parserException;
+            }
         }
 
         return status;
diff --git a/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/HasJavaFileInfo.java b/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/HasJavaFileInfo.java
index c73258e..efd4be8 100644
--- a/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/HasJavaFileInfo.java
+++ b/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/HasJavaFileInfo.java
@@ -26,12 +26,12 @@
      *
      * @return generated java file information
      */
-    public JavaFileInfo getJavaFileInfo();
+    JavaFileInfo getJavaFileInfo();
 
     /**
      * Sets the java file info object.
      *
      * @param javaInfo java file info object
      */
-    public void setJavaFileInfo(JavaFileInfo javaInfo);
+    void setJavaFileInfo(JavaFileInfo javaInfo);
 }
diff --git a/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/HasJavaImportData.java b/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/HasJavaImportData.java
index 4ae28dd..7251b7f 100644
--- a/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/HasJavaImportData.java
+++ b/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/HasJavaImportData.java
@@ -25,7 +25,7 @@
      *
      * @return data of java imports to be included in generated file
      */
-    public JavaImportData getJavaImportData();
+    JavaImportData getJavaImportData();
 
     /**
      * Sets the data of java imports to be included in generated file.
@@ -33,5 +33,5 @@
      * @param javaImportData data of java imports to be included in generated
      *            file
      */
-    public void setJavaImportData(JavaImportData javaImportData);
+    void setJavaImportData(JavaImportData javaImportData);
 }
diff --git a/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/JavaCodeGeneratorUtil.java b/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/JavaCodeGeneratorUtil.java
index 577a3ba..7e010db 100644
--- a/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/JavaCodeGeneratorUtil.java
+++ b/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/JavaCodeGeneratorUtil.java
@@ -29,7 +29,7 @@
 import static org.onosproject.yangutils.translator.tojava.TraversalType.SIBILING;
 
 /**
- * Representation of Java code generator based on application schema.
+ * Representation of java code generator based on application schema.
  */
 public final class JavaCodeGeneratorUtil {
 
@@ -75,7 +75,7 @@
         YangNode curNode = rootNode;
         TraversalType curTraversal = ROOT;
 
-        while (!(curNode == null)) {
+        while (curNode != null) {
             if (curTraversal != PARENT) {
                 setCurNode(curNode);
                 generateCodeEntry(curNode, yangPlugin);
@@ -166,9 +166,8 @@
      * Free the current node.
      *
      * @param node YANG node
-     * @throws DataModelException when fails to do datamodel operations
      */
-    private static void free(YangNode node) throws DataModelException {
+    private static void free(YangNode node) {
 
         YangNode parent = node.getParent();
         parent.setChild(null);
@@ -202,7 +201,7 @@
         setCurNode(curNode.getChild());
         TraversalType curTraversal = ROOT;
 
-        while (!(curNode == null)) {
+        while (curNode != null) {
 
             if (curTraversal != PARENT) {
                 close(curNode);
@@ -220,7 +219,6 @@
         }
 
         freeRestResources();
-        curNode = null;
     }
 
     /**
diff --git a/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/JavaImportData.java b/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/JavaImportData.java
index 469e416..2c2ce05 100644
--- a/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/JavaImportData.java
+++ b/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/JavaImportData.java
@@ -19,6 +19,7 @@
 import java.util.List;
 import java.util.SortedSet;
 import java.util.TreeSet;
+import static java.util.Collections.sort;
 
 import org.onosproject.yangutils.datamodel.YangNode;
 import org.onosproject.yangutils.translator.exception.TranslatorException;
@@ -62,7 +63,7 @@
     /**
      * Returns if the list needs to be imported.
      *
-     * @return true if any of the attribute needs to be maintained as a list.
+     * @return true if any of the attribute needs to be maintained as a list
      */
     public boolean getIfListImported() {
         return isListToImport;
@@ -71,7 +72,7 @@
     /**
      * Sets the status of importing list.
      *
-     * @param isList status to mention list is bing imported.
+     * @param isList status to mention list is bing imported
      */
     public void setIfListImported(boolean isList) {
         isListToImport = isList;
@@ -138,10 +139,9 @@
         List<String> imports = new ArrayList<>();
 
         for (JavaQualifiedTypeInfo importInfo : getImportSet()) {
-            importString = IMPORT;
-            if (importInfo.getPkgInfo() != EMPTY_STRING && importInfo.getClassInfo() != null
-                    && importInfo.getPkgInfo() != JAVA_LANG) {
-                importString = importString + importInfo.getPkgInfo() + PERIOD + importInfo.getClassInfo() + SEMI_COLAN
+            if (!importInfo.getPkgInfo().equals(EMPTY_STRING) && importInfo.getClassInfo() != null
+                    && !importInfo.getPkgInfo().equals(JAVA_LANG)) {
+                importString = IMPORT + importInfo.getPkgInfo() + PERIOD + importInfo.getClassInfo() + SEMI_COLAN
                         + NEW_LINE;
 
                 imports.add(importString);
@@ -152,7 +152,7 @@
             imports.add(getImportForList());
         }
 
-        java.util.Collections.sort(imports);
+        sort(imports);
         return imports;
     }
 
diff --git a/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/TempJavaCodeFragmentFiles.java b/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/TempJavaCodeFragmentFiles.java
index c815c95..205990f 100644
--- a/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/TempJavaCodeFragmentFiles.java
+++ b/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/TempJavaCodeFragmentFiles.java
@@ -1108,7 +1108,6 @@
                 addToStringMethod(newAttrInfo);
             }
         }
-        return;
     }
 
     /**
diff --git a/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/javamodel/YangJavaModule.java b/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/javamodel/YangJavaModule.java
index d6ba066..8895da2 100644
--- a/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/javamodel/YangJavaModule.java
+++ b/utils/yangutils/src/main/java/org/onosproject/yangutils/translator/tojava/javamodel/YangJavaModule.java
@@ -136,9 +136,11 @@
         YangJavaModelUtils.generateCodeOfRootNode(this, yangPlugin, modulePkg);
     }
 
+    /**
+     * Creates a java file using the YANG module info.
+     */
     @Override
     public void generateCodeExit() throws IOException {
         getTempJavaCodeFragmentFiles().generateJavaFile(GENERATE_INTERFACE_WITH_BUILDER, this);
-        return;
     }
 }
diff --git a/utils/yangutils/src/main/java/org/onosproject/yangutils/utils/io/impl/FileSystemUtil.java b/utils/yangutils/src/main/java/org/onosproject/yangutils/utils/io/impl/FileSystemUtil.java
index 3765f71..ffc36f7 100644
--- a/utils/yangutils/src/main/java/org/onosproject/yangutils/utils/io/impl/FileSystemUtil.java
+++ b/utils/yangutils/src/main/java/org/onosproject/yangutils/utils/io/impl/FileSystemUtil.java
@@ -53,7 +53,6 @@
      * @return existence status of package
      */
     public static boolean doesPackageExist(String pkg) {
-
         File pkgDir = new File(getPackageDirPathFromJavaJPackage(pkg));
         File pkgWithFile = new File(pkgDir + SLASH + "package-info.java");
         if (pkgDir.exists() && pkgWithFile.isFile()) {
@@ -70,7 +69,6 @@
      * @throws IOException any IO exception
      */
     public static void createPackage(String pkg, String pkgInfo) throws IOException {
-
         if (!doesPackageExist(pkg)) {
             try {
                 File pack = createDirectories(pkg);
@@ -92,9 +90,7 @@
      * @throws IOException any IO errors
      */
     public static void appendFileContents(File toAppend, File srcFile) throws IOException {
-
         updateFileHandle(srcFile, NEW_LINE + readAppendFile(toAppend.toString(), FOUR_SPACE_INDENTATION), false);
-        return;
     }
 
     /**
@@ -106,7 +102,6 @@
      * @throws IOException when fails to convert to string
      */
     public static String readAppendFile(String toAppend, String spaces) throws IOException {
-
         FileReader fileReader = new FileReader(toAppend);
         BufferedReader bufferReader = new BufferedReader(fileReader);
         try {
@@ -114,8 +109,8 @@
             String line = bufferReader.readLine();
 
             while (line != null) {
-                if (line.equals(SPACE) | line.equals(EMPTY_STRING) | line.equals(EIGHT_SPACE_INDENTATION)
-                        | line.equals(MULTIPLE_NEW_LINE)) {
+                if (line.equals(SPACE) || line.equals(EMPTY_STRING) || line.equals(EIGHT_SPACE_INDENTATION)
+                        || line.equals(MULTIPLE_NEW_LINE)) {
                     stringBuilder.append(NEW_LINE);
                 } else if (line.equals(FOUR_SPACE_INDENTATION)) {
                     stringBuilder.append(EMPTY_STRING);
@@ -142,7 +137,6 @@
      * does not exist but cannot be created, or cannot be opened for any other reason
      */
     public static void updateFileHandle(File inputFile, String contentTobeAdded, boolean isClose) throws IOException {
-
         FileWriter fileWriter = new FileWriter(inputFile, true);
         PrintWriter outputPrintWriter = new PrintWriter(fileWriter, true);
         if (!isClose) {
diff --git a/utils/yangutils/src/main/java/org/onosproject/yangutils/utils/io/impl/JavaDocGen.java b/utils/yangutils/src/main/java/org/onosproject/yangutils/utils/io/impl/JavaDocGen.java
index 982cbc4..c76ecad 100644
--- a/utils/yangutils/src/main/java/org/onosproject/yangutils/utils/io/impl/JavaDocGen.java
+++ b/utils/yangutils/src/main/java/org/onosproject/yangutils/utils/io/impl/JavaDocGen.java
@@ -17,7 +17,6 @@
 package org.onosproject.yangutils.utils.io.impl;
 
 import org.onosproject.yangutils.translator.tojava.utils.JavaIdentifierSyntax;
-import org.onosproject.yangutils.utils.UtilConstants;
 
 import static org.onosproject.yangutils.utils.UtilConstants.BUILDER;
 import static org.onosproject.yangutils.utils.UtilConstants.BUILDER_CLASS_JAVA_DOC;
@@ -62,7 +61,7 @@
     /**
      * JavaDocs types.
      */
-    public static enum JavaDocType {
+    public enum JavaDocType {
 
         /**
          * For class.
@@ -141,7 +140,7 @@
     public static String getJavaDoc(JavaDocType type, String name, boolean isList) {
 
         name = JavaIdentifierSyntax.getSmallCase(JavaIdentifierSyntax.getCamelCase(name, null));
-        String javaDoc = UtilConstants.EMPTY_STRING;
+        String javaDoc;
         if (type.equals(JavaDocType.IMPL_CLASS)) {
             javaDoc = generateForImplClass(name);
         } else if (type.equals(JavaDocType.BUILDER_CLASS)) {
diff --git a/utils/yangutils/src/test/java/org/onosproject/yangutils/parser/impl/YangUtilsParserManagerTest.java b/utils/yangutils/src/test/java/org/onosproject/yangutils/parser/impl/YangUtilsParserManagerTest.java
index 6924849..9b3effc 100644
--- a/utils/yangutils/src/test/java/org/onosproject/yangutils/parser/impl/YangUtilsParserManagerTest.java
+++ b/utils/yangutils/src/test/java/org/onosproject/yangutils/parser/impl/YangUtilsParserManagerTest.java
@@ -60,7 +60,7 @@
      * This test case checks whether the io exception is generated
      * when the input YANG file is non existent.
      */
-    @Test(expected = IOException.class)
+    @Test(expected = ParserException.class)
     public void getDataModelNonExistentFileTest() throws IOException, ParserException {
 
         YangUtilsParserManager manager = new YangUtilsParserManager();
diff --git a/utils/yangutils/src/test/java/org/onosproject/yangutils/parser/impl/listeners/StatusListenerTest.java b/utils/yangutils/src/test/java/org/onosproject/yangutils/parser/impl/listeners/StatusListenerTest.java
index d4fc841..8e44429 100644
--- a/utils/yangutils/src/test/java/org/onosproject/yangutils/parser/impl/listeners/StatusListenerTest.java
+++ b/utils/yangutils/src/test/java/org/onosproject/yangutils/parser/impl/listeners/StatusListenerTest.java
@@ -140,7 +140,7 @@
     @Test
     public void processStatusInvalidValue() throws IOException, ParserException {
         thrown.expect(ParserException.class);
-        thrown.expectMessage("Invalid content in status \"invalid\" before processing.");
+        thrown.expectMessage("YANG file error : status invalid is not valid.");
         YangNode node = manager.getDataModel("src/test/resources/StatusInvalidValue.yang");
     }
 
