Ray Milkey

Revert "Review comments fix for the code in master"

This patch set currently does not build with maven

This reverts commit cbdf0f2b.

Change-Id: Ib49e29bbef1d3592ac1fbbb782ffceb29c0aad83
......@@ -76,8 +76,7 @@ import static org.onosproject.yangutils.datamodel.utils.DataModelUtils.resolveLi
/**
* Represents data model node to maintain information defined in YANG sub-module.
*/
public class YangSubModule
extends YangNode
public class YangSubModule extends YangNode
implements YangLeavesHolder, YangDesc, YangReference, Parsable, CollisionDetector, YangReferenceResolver,
RpcNotificationContainer {
......@@ -151,7 +150,6 @@ public class YangSubModule
* Prefix of parent module.
*/
private String prefix;
/*-
* Reference RFC 6020.
*
......@@ -333,8 +331,7 @@ public class YangSubModule
}
@Override
public void resolveSelfFileLinking()
throws DataModelException {
public void resolveSelfFileLinking() throws DataModelException {
// Get the list to be resolved.
List<YangResolutionInfo> resolutionList = getUnresolvedResolutionList();
// Resolve linking for a resolution list.
......@@ -471,8 +468,7 @@ public class YangSubModule
* @throws DataModelException a violation of data model rules
*/
@Override
public void validateDataOnEntry()
throws DataModelException {
public void validateDataOnEntry() throws DataModelException {
// TODO auto-generated method stub, to be implemented by parser
}
......@@ -482,21 +478,18 @@ public class YangSubModule
* @throws DataModelException a violation of data model rules
*/
@Override
public void validateDataOnExit()
throws DataModelException {
public void validateDataOnExit() throws DataModelException {
// TODO auto-generated method stub, to be implemented by parser
}
@Override
public void detectCollidingChild(String identifierName, YangConstructType dataType)
throws DataModelException {
public void detectCollidingChild(String identifierName, YangConstructType dataType) throws DataModelException {
// Asks helper to detect colliding child.
detectCollidingChildUtil(identifierName, dataType, this);
}
@Override
public void detectSelfCollision(String identifierName, YangConstructType dataType)
throws DataModelException {
public void detectSelfCollision(String identifierName, YangConstructType dataType) throws DataModelException {
// Not required as module doesn't have any parent.
}
......
......@@ -114,38 +114,31 @@ public class TempJavaFragmentFiles {
* Information about the java files being generated.
*/
private JavaFileInfo javaFileInfo;
/**
* Imported class info.
*/
private JavaImportData javaImportData;
/**
* The variable which guides the types of temporary files generated using
* the temporary generated file types mask.
*/
private int generatedTempFiles;
/**
* Absolute path where the target java file needs to be generated.
*/
private String absoluteDirPath;
/**
* Contains all the interface(s)/class name which will be extended by generated files.
*/
private List<String> extendsList = new ArrayList<>();
/**
* File type extension for java classes.
*/
private static final String JAVA_FILE_EXTENSION = ".java";
/**
* File type extension for temporary classes.
*/
private static final String TEMP_FILE_EXTENSION = ".tmp";
/**
* Folder suffix for temporary files folder.
*/
......@@ -175,17 +168,14 @@ public class TempJavaFragmentFiles {
* File name for attributes.
*/
private static final String ATTRIBUTE_FILE_NAME = "Attributes";
/**
* File name for to string method.
*/
private static final String TO_STRING_METHOD_FILE_NAME = "ToString";
/**
* File name for hash code method.
*/
private static final String HASH_CODE_METHOD_FILE_NAME = "HashCode";
/**
* File name for equals method.
*/
......@@ -200,17 +190,14 @@ public class TempJavaFragmentFiles {
* File name for interface java file name suffix.
*/
private static final String INTERFACE_FILE_NAME_SUFFIX = EMPTY_STRING;
/**
* File name for builder interface file name suffix.
*/
private static final String BUILDER_INTERFACE_FILE_NAME_SUFFIX = BUILDER + INTERFACE;
/**
* File name for builder class file name suffix.
*/
private static final String BUILDER_CLASS_FILE_NAME_SUFFIX = BUILDER;
/**
* File name for impl class file name suffix.
*/
......@@ -225,17 +212,14 @@ public class TempJavaFragmentFiles {
* Java file handle for interface file.
*/
private File interfaceJavaFileHandle;
/**
* Java file handle for builder interface file.
*/
private File builderInterfaceJavaFileHandle;
/**
* Java file handle for builder class file.
*/
private File builderClassJavaFileHandle;
/**
* Java file handle for impl class file.
*/
......@@ -270,17 +254,14 @@ public class TempJavaFragmentFiles {
* Temporary file handle for hash code method of class.
*/
private File hashCodeImplTempFileHandle;
/**
* Temporary file handle for equals method of class.
*/
private File equalsImplTempFileHandle;
/**
* Temporary file handle for to string method of class.
*/
private File toStringImplTempFileHandle;
/**
* Temporary file handle for enum class file.
*/
......@@ -295,17 +276,18 @@ public class TempJavaFragmentFiles {
* Is attribute added.
*/
private boolean isAttributePresent = false;
/**
* Current enum's value.
*/
private int enumValue;
/*
* Java file handle for enum class.
*/
private File enumClassJavaFileHandle;
public TempJavaFragmentFiles() {
}
/**
* Returns enum class java file handle.
*
......
......@@ -60,7 +60,6 @@ public class TempJavaTypeFragmentFiles
* File name for construction for special type like union, typedef.
*/
private static final String CONSTRUCTOR_FOR_TYPE_FILE_NAME = "ConstructorForType";
/**
* File name for from string method.
*/
......@@ -81,7 +80,6 @@ public class TempJavaTypeFragmentFiles
* Temporary file handle for of string method of class.
*/
private File ofStringImplTempFileHandle;
/**
* Temporary file handle for constructor for type class.
*/
......@@ -96,7 +94,6 @@ public class TempJavaTypeFragmentFiles
* Java file handle for typedef class file.
*/
private File typedefClassJavaFileHandle;
/**
* Java file handle for type class like union, typedef file.
*/
......
......@@ -113,7 +113,7 @@ public class YangJavaNotification
public void generateCodeEntry(YangPluginConfig yangPlugin)
throws IOException {
/*
/**
* As part of the notification support the following files needs to be generated.
* 1) Subject of the notification(event), this is simple interface with builder class.
* 2) Event class extending "AbstractEvent" and defining event type enum.
......@@ -121,18 +121,19 @@ public class YangJavaNotification
*
* The manager class needs to extend the ListenerRegistry.
*/
// Generate subject of the notification(event), this is simple interface with builder class.
generateCodeOfNode(this, yangPlugin);
}
/**
* Creates a java file using the YANG notification info.
*
* @throws IOException input output operation fail
*/
@Override
public void generateCodeExit()
throws IOException {
/*
/**
* As part of the notification support the following files needs to be generated.
* 1) Subject of the notification(event), this is simple interface with builder class.
* 2) Event class extending "AbstractEvent" and defining event type enum.
......