[ONOS-5757]&[ONOS-5758] add Restconf GET, POST and DELETE
operates to RestconfManager.java

Change-Id: I4edf183676b7d4fdf94f1f2c7da8c88891b9785b
diff --git a/apps/restconf/BUCK b/apps/restconf/BUCK
index 79f509b..c223871 100644
--- a/apps/restconf/BUCK
+++ b/apps/restconf/BUCK
@@ -1,12 +1,13 @@
 BUNDLES = [
     '//apps/restconf/api:onos-apps-restconf-api',
+    '//apps/restconf/utils:onos-apps-restconf-utils',
     '//apps/restconf/restconfmgr:onos-apps-restconf-restconfmgr',
 ]
 
 onos_app (
-  app_name = 'org.onosproject.restconf',
-  title = 'RESTCONF Application Module',
-  category = 'Utility',
-  url = 'http://onosproject.org',
-  included_bundles = BUNDLES,
+    app_name = 'org.onosproject.restconf',
+    title = 'RESTCONF Application Module',
+    category = 'Utility',
+    url = 'http://onosproject.org',
+    included_bundles = BUNDLES,
 )
diff --git a/apps/restconf/pom.xml b/apps/restconf/pom.xml
index e478c32..400b916 100644
--- a/apps/restconf/pom.xml
+++ b/apps/restconf/pom.xml
@@ -32,6 +32,7 @@
         <module>api</module>
         <module>restconfmgr</module>
         <module>app</module>
+        <module>utils</module>
     </modules>
 
     <description>RESTCONF Application Module</description>
diff --git a/apps/restconf/restconfmgr/BUCK b/apps/restconf/restconfmgr/BUCK
index d661d74..7bb7871 100644
--- a/apps/restconf/restconfmgr/BUCK
+++ b/apps/restconf/restconfmgr/BUCK
@@ -3,11 +3,14 @@
     '//lib:jersey-client',
     '//lib:jersey-server',
     '//lib:javax.ws.rs-api',
-    '//utils/rest:onlab-rest',
+    '//incubator/api:onos-incubator-api',
+    '//lib:COMPILE',
     '//core/store/serializers:onos-core-serializers',
     '//apps/restconf/api:onos-apps-restconf-api',
+    '//apps/restconf/utils:onos-apps-restconf-utils',
+    '//apps/config:onos-apps-config',
 ]
 
 osgi_jar_with_tests (
     deps = COMPILE_DEPS,
-)
+)
\ No newline at end of file
diff --git a/apps/restconf/restconfmgr/pom.xml b/apps/restconf/restconfmgr/pom.xml
index c79d6d1..1f00826 100644
--- a/apps/restconf/restconfmgr/pom.xml
+++ b/apps/restconf/restconfmgr/pom.xml
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!--
-  ~ Copyright 2016-present Open Networking Laboratory
+  ~ Copyright 2017-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.
@@ -17,14 +17,13 @@
 <project xmlns="http://maven.apache.org/POM/4.0.0"
          xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
          xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
-    <modelVersion>4.0.0</modelVersion>
-
     <parent>
         <groupId>org.onosproject</groupId>
         <artifactId>onos-restconf-parent</artifactId>
         <version>1.10.0-SNAPSHOT</version>
         <relativePath>../pom.xml</relativePath>
     </parent>
+    <modelVersion>4.0.0</modelVersion>
 
     <artifactId>onos-app-restconf-restconfmanager</artifactId>
     <packaging>bundle</packaging>
@@ -32,6 +31,21 @@
     <dependencies>
         <dependency>
             <groupId>org.onosproject</groupId>
+            <artifactId>onos-yang-model</artifactId>
+            <version>1.12.0-b5</version>
+        </dependency>
+        <dependency>
+            <groupId>org.onosproject</groupId>
+            <artifactId>onos-app-restconf-utils</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.onosproject</groupId>
+            <artifactId>onos-app-config</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.onosproject</groupId>
             <artifactId>onos-app-restconf-api</artifactId>
             <version>${project.version}</version>
         </dependency>
diff --git a/apps/restconf/restconfmgr/src/main/java/org/onosproject/restconf/restconfmanager/RestconfManager.java b/apps/restconf/restconfmgr/src/main/java/org/onosproject/restconf/restconfmanager/RestconfManager.java
index 45c1a4c..6397cba 100644
--- a/apps/restconf/restconfmgr/src/main/java/org/onosproject/restconf/restconfmanager/RestconfManager.java
+++ b/apps/restconf/restconfmgr/src/main/java/org/onosproject/restconf/restconfmanager/RestconfManager.java
@@ -1,5 +1,5 @@
 /*
- * Copyright 2016-present Open Networking Laboratory
+ * Copyright 2017-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.
@@ -13,6 +13,7 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
+
 package org.onosproject.restconf.restconfmanager;
 
 import com.fasterxml.jackson.databind.node.ObjectNode;
@@ -20,15 +21,17 @@
 import org.apache.felix.scr.annotations.Activate;
 import org.apache.felix.scr.annotations.Component;
 import org.apache.felix.scr.annotations.Deactivate;
+import org.apache.felix.scr.annotations.Reference;
+import org.apache.felix.scr.annotations.ReferenceCardinality;
 import org.apache.felix.scr.annotations.Service;
 import org.glassfish.jersey.server.ChunkedOutput;
+import org.onlab.osgi.DefaultServiceDirectory;
 import org.onosproject.event.ListenerTracker;
-import org.onosproject.restconf.api.RestconfException;
-import org.onosproject.restconf.api.RestconfService;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
 import java.io.IOException;
+import java.util.List;
 import java.util.concurrent.BlockingQueue;
 import java.util.concurrent.ConcurrentHashMap;
 import java.util.concurrent.ConcurrentMap;
@@ -36,25 +39,30 @@
 import java.util.concurrent.Executors;
 import java.util.concurrent.LinkedBlockingQueue;
 import java.util.concurrent.ThreadPoolExecutor;
-
 import static java.util.concurrent.TimeUnit.SECONDS;
 import static javax.ws.rs.core.Response.Status.INTERNAL_SERVER_ERROR;
 
+import org.onosproject.config.FailedException;
+import org.onosproject.config.DynamicConfigService;
+import org.onosproject.config.Filter;
+import org.onosproject.restconf.api.RestconfException;
+import org.onosproject.restconf.api.RestconfService;
+import org.onosproject.yang.model.ResourceData;
+import org.onosproject.yang.model.ResourceId;
+import org.onosproject.yang.model.DataNode;
+import static org.onosproject.restconf.utils.RestconfUtils.convertUriToRid;
+import static org.onosproject.restconf.utils.RestconfUtils.convertJsonToDataNode;
+import static org.onosproject.restconf.utils.RestconfUtils.convertDataNodeToJson;
+
 /*
- * Skeletal ONOS RESTCONF Server application. The RESTCONF Manager
- * implements the main logic of the RESTCONF Server.
+ * ONOS RESTCONF application. The RESTCONF Manager
+ * implements the main logic of the RESTCONF application.
  *
  * The design of the RESTCONF subsystem contains 2 major bundles:
- *
- * 1. RESTCONF Protocol Proxy (RPP). This bundle is implemented as a
- *    JAX-RS application. It acts as the frond-end of the RESTCONF server.
- *    It intercepts/handles HTTP requests that are sent to the RESTCONF
- *    Root Path. It then calls the RESTCONF Manager to process the requests.
- *
- * 2. RESTCONF Manager. This bundle module is the back-end of the server.
+ *    This bundle module is the back-end of the server.
  *    It provides the main logic of the RESTCONF server. It interacts with
- *    the YMS (YANG Management System) to run operations on the YANG data
- *    objects (i.e., data resources).
+ *    the Dynamic Config Service and yang runtime service to run operations
+ *    on the YANG data objects (i.e., resource id, yang data node).
  */
 
 /**
@@ -78,6 +86,11 @@
 
     private final Logger log = LoggerFactory.getLogger(getClass());
 
+    @Reference(cardinality = ReferenceCardinality.MANDATORY_UNARY)
+
+    private static final DynamicConfigService  DYNAMIC_CONFIG_SERVICE =
+            DefaultServiceDirectory.getService(DynamicConfigService.class);
+
     private ListenerTracker listeners;
 
     private ConcurrentMap<String, BlockingQueue<ObjectNode>> eventQueueList =
@@ -104,23 +117,58 @@
     @Override
     public ObjectNode runGetOperationOnDataResource(String uri)
             throws RestconfException {
-
-        return null;
+        ResourceId rid = convertUriToRid(uri);
+        // TODO: define Filter (if there is any requirement).
+        Filter filter = new Filter();
+        DataNode dataNode;
+        try {
+            dataNode = DYNAMIC_CONFIG_SERVICE.readNode(rid, filter);
+        } catch (FailedException e) {
+            log.error("ERROR: DynamicConfigService: ", e);
+            throw new RestconfException("ERROR: DynamicConfigService",
+                                        INTERNAL_SERVER_ERROR);
+        }
+        ObjectNode rootNode = convertDataNodeToJson(rid, dataNode);
+        return rootNode;
     }
 
     @Override
     public void runPostOperationOnDataResource(String uri, ObjectNode rootNode)
             throws RestconfException {
+        ResourceData resourceData = convertJsonToDataNode(uri, rootNode);
+        ResourceId rid = resourceData.resourceId();
+        List<DataNode> dataNodeList = resourceData.dataNodes();
+        // TODO: Error message needs to be fixed
+        if (dataNodeList.size() > 1) {
+            log.warn("ERROR: There are more than one Data Node can be proceed");
+        }
+        DataNode dataNode = dataNodeList.get(0);
+        try {
+            DYNAMIC_CONFIG_SERVICE.createNode(rid, dataNode);
+        } catch (FailedException e) {
+            log.error("ERROR: DynamicConfigService: ", e);
+            throw new RestconfException("ERROR: DynamicConfigService",
+                                        INTERNAL_SERVER_ERROR);
+        }
     }
 
     @Override
     public void runPutOperationOnDataResource(String uri, ObjectNode rootNode)
             throws RestconfException {
+        runPostOperationOnDataResource(uri, rootNode);
     }
 
     @Override
     public void runDeleteOperationOnDataResource(String uri)
             throws RestconfException {
+        ResourceId rid = convertUriToRid(uri);
+        try {
+            DYNAMIC_CONFIG_SERVICE.deleteNode(rid);
+        } catch (FailedException e) {
+            log.error("ERROR: DynamicConfigService: ", e);
+            throw new RestconfException("ERROR: DynamicConfigService",
+                                        INTERNAL_SERVER_ERROR);
+        }
     }
 
     @Override
diff --git a/apps/restconf/utils/BUCK b/apps/restconf/utils/BUCK
new file mode 100644
index 0000000..760082d
--- /dev/null
+++ b/apps/restconf/utils/BUCK
@@ -0,0 +1,16 @@
+COMPILE_DEPS = [
+    '//lib:CORE_DEPS',
+    '//lib:jersey-client',
+    '//lib:jersey-server',
+    '//lib:javax.ws.rs-api',
+    '//lib:easymock',
+    '//utils/rest:onlab-rest',
+    '//apps/restconf/api:onos-apps-restconf-api',
+    '//lib:onos-yang-model',
+    '//lib:onos-yang-compiler-api',
+    '//lib:onos-yang-runtime',
+]
+
+osgi_jar_with_tests (
+    deps = COMPILE_DEPS,
+)
diff --git a/apps/restconf/utils/pom.xml b/apps/restconf/utils/pom.xml
new file mode 100644
index 0000000..28c868b
--- /dev/null
+++ b/apps/restconf/utils/pom.xml
@@ -0,0 +1,73 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  ~ Copyright 2017-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.
+  ~ 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.
+  -->
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+    <parent>
+        <artifactId>onos-restconf-parent</artifactId>
+        <groupId>org.onosproject</groupId>
+        <version>1.10.0-SNAPSHOT</version>
+        <relativePath>../pom.xml</relativePath>
+    </parent>
+    <modelVersion>4.0.0</modelVersion>
+
+    <artifactId>onos-app-restconf-utils</artifactId>
+    <packaging>bundle</packaging>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.onosproject</groupId>
+            <artifactId>onos-yang-runtime</artifactId>
+            <version>1.12.0-b5</version>
+        </dependency>
+        <dependency>
+            <groupId>org.onosproject</groupId>
+            <artifactId>onos-yang-model</artifactId>
+            <version>1.12.0-b5</version>
+        </dependency>
+        <dependency>
+            <groupId>org.onosproject</groupId>
+            <artifactId>onos-app-restconf-api</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.onosproject</groupId>
+            <artifactId>onos-app-config</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.onosproject</groupId>
+            <artifactId>onos-app-yms-api</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.onosproject</groupId>
+            <artifactId>onos-app-yms</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.easymock</groupId>
+            <artifactId>easymock</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.onosproject</groupId>
+            <artifactId>onlab-junit</artifactId>
+            <scope>test</scope>
+        </dependency>
+    </dependencies>
+</project>
diff --git a/apps/restconf/utils/src/main/java/org/onosproject/restconf/utils/RestconfUtils.java b/apps/restconf/utils/src/main/java/org/onosproject/restconf/utils/RestconfUtils.java
new file mode 100644
index 0000000..2150e1d
--- /dev/null
+++ b/apps/restconf/utils/src/main/java/org/onosproject/restconf/utils/RestconfUtils.java
@@ -0,0 +1,155 @@
+/*
+ * Copyright 2017-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.
+ * 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.restconf.utils;
+
+import com.fasterxml.jackson.databind.ObjectMapper;
+import com.fasterxml.jackson.databind.node.ObjectNode;
+import org.apache.commons.io.IOUtils;
+import org.onlab.osgi.DefaultServiceDirectory;
+import java.io.IOException;
+import java.io.InputStream;
+
+import org.onosproject.restconf.utils.exceptions.RestconfUtilsException;
+import org.onosproject.restconf.api.RestconfException;
+import org.onosproject.yang.runtime.CompositeStream;
+import org.onosproject.yang.runtime.CompositeData;
+import org.onosproject.yang.runtime.YangRuntimeService;
+import org.onosproject.yang.runtime.DefaultCompositeStream;
+import org.onosproject.yang.runtime.DefaultCompositeData;
+import org.onosproject.yang.runtime.DefaultResourceData;
+import org.onosproject.yang.runtime.RuntimeContext;
+import org.onosproject.yang.model.ResourceData;
+import org.onosproject.yang.model.ResourceId;
+import org.onosproject.yang.model.DataNode;
+
+import static javax.ws.rs.core.Response.Status.INTERNAL_SERVER_ERROR;
+
+/**
+ * Utilities used by the RESTCONF app.
+ */
+public final class RestconfUtils {
+    /**
+     * No instantiation.
+     */
+    private RestconfUtils() {
+    }
+
+    /**
+     * Data format required by YangRuntime Service.
+     */
+    private static final String JSON_FORMAT = "json";
+
+    private static final YangRuntimeService YANG_RUNTIME =
+            DefaultServiceDirectory.getService(YangRuntimeService.class);
+
+    /**
+     * Converts an input stream to JSON objectNode.
+     *
+     * @param  inputStream the InputStream from Resource Data
+     * @return JSON representation of the data resource
+     */
+    public static ObjectNode convertInputStreamToObjectNode(InputStream inputStream) {
+        ObjectNode rootNode;
+        ObjectMapper mapper = new ObjectMapper();
+        try {
+            rootNode = (ObjectNode) mapper.readTree(inputStream);
+        } catch (IOException e) {
+            throw new RestconfUtilsException("ERROR: InputStream failed to parse");
+        }
+        return rootNode;
+    }
+
+    /**
+     * Convert ObjectNode to InputStream.
+     *
+     * @param  rootNode JSON representation of the data resource
+     * @return the InputStream from Resource Data
+     */
+    public static InputStream convertObjectNodeToInputStream(ObjectNode rootNode) {
+        String json = rootNode.asText();
+        InputStream inputStream;
+        try {
+            inputStream = IOUtils.toInputStream(json);
+        } catch (Exception e) {
+            throw new RestconfUtilsException("ERROR: Json Node failed to parse");
+        }
+        return inputStream;
+    }
+
+    /**
+     * Convert URI to ResourceId.
+     *
+     * @param  uri URI of the data resource
+     * @return resource identifier
+     */
+    public static ResourceId convertUriToRid(String uri) {
+        ResourceData resourceData = convertJsonToDataNode(uri, null);
+        return resourceData.resourceId();
+    }
+
+    /**
+     * Convert URI and ObjectNode to ResourceData.
+     *
+     * @param  uri URI of the data resource
+     * @param  rootNode JSON representation of the data resource
+     * @return represents type of node in data store
+     */
+    public static ResourceData convertJsonToDataNode(String uri,
+                                                    ObjectNode rootNode) {
+        RuntimeContext.Builder runtimeContextBuilder = null;
+        runtimeContextBuilder.setDataFormat(JSON_FORMAT);
+        RuntimeContext context = runtimeContextBuilder.build();
+        InputStream jsonData = null;
+        if (rootNode != null) {
+            jsonData = convertObjectNodeToInputStream(rootNode);
+        }
+        CompositeStream compositeStream = new DefaultCompositeStream(uri, jsonData);
+        // CompositeStream --- YangRuntimeService ---> CompositeData.
+        CompositeData compositeData = YANG_RUNTIME.decode(compositeStream, context);
+        ResourceData resourceData = compositeData.resourceData();
+        return resourceData;
+    }
+
+    /**
+     * Convert Resource Id and Data Node to Json ObjectNode.
+     *
+     * @param  rid resource identifier
+     * @param  dataNode represents type of node in data store
+     * @return JSON representation of the data resource
+     */
+    public static ObjectNode convertDataNodeToJson(ResourceId rid, DataNode dataNode) {
+        RuntimeContext.Builder runtimeContextBuilder = null;
+        runtimeContextBuilder.setDataFormat(JSON_FORMAT);
+        RuntimeContext context = runtimeContextBuilder.build();
+        DefaultResourceData.Builder resourceDataBuilder = DefaultResourceData.builder();
+        resourceDataBuilder.addDataNode(dataNode);
+        resourceDataBuilder.resourceId(rid);
+        ResourceData resourceData = resourceDataBuilder.build();
+        DefaultCompositeData.Builder compositeDataBuilder = DefaultCompositeData.builder();
+        compositeDataBuilder.resourceData(resourceData);
+        CompositeData compositeData = compositeDataBuilder.build();
+        // CompositeData --- YangRuntimeService ---> CompositeStream.
+        CompositeStream compositeStream = YANG_RUNTIME.encode(compositeData, context);
+        InputStream inputStream = compositeStream.resourceData();
+        ObjectNode rootNode = convertInputStreamToObjectNode(inputStream);
+        if (rootNode == null) {
+            throw new RestconfException("ERROR: InputStream can not be convert to ObjectNode",
+                                        INTERNAL_SERVER_ERROR);
+        }
+        return rootNode;
+    }
+}
diff --git a/apps/restconf/utils/src/main/java/org/onosproject/restconf/utils/exceptions/RestconfUtilsException.java b/apps/restconf/utils/src/main/java/org/onosproject/restconf/utils/exceptions/RestconfUtilsException.java
new file mode 100644
index 0000000..c8d0791
--- /dev/null
+++ b/apps/restconf/utils/src/main/java/org/onosproject/restconf/utils/exceptions/RestconfUtilsException.java
@@ -0,0 +1,42 @@
+/*
+ * Copyright 2017-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.
+ * 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.restconf.utils.exceptions;
+
+/**
+ * Represents class of errors related to RESTCONF utilities.
+ */
+public class RestconfUtilsException extends RuntimeException {
+
+    /**
+     * Constructs an exception with the specified message.
+     *
+     * @param message the message describing the specific nature of the error
+     */
+    public RestconfUtilsException(String message) {
+        super(message);
+    }
+
+    /**
+     * Constructs an exception with the specified message and the underlying
+     * cause.
+     *
+     * @param message the message describing the specific nature of the error
+     * @param cause   the underlying cause of this error
+     */
+    public RestconfUtilsException(String message, Throwable cause) {
+        super(message, cause);
+    }
+}
diff --git a/apps/restconf/utils/src/main/java/org/onosproject/restconf/utils/exceptions/package-info.java b/apps/restconf/utils/src/main/java/org/onosproject/restconf/utils/exceptions/package-info.java
new file mode 100644
index 0000000..4ae7122
--- /dev/null
+++ b/apps/restconf/utils/src/main/java/org/onosproject/restconf/utils/exceptions/package-info.java
@@ -0,0 +1,20 @@
+/*
+ * Copyright 2017-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.
+ * 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.
+ */
+
+/**
+ * Parse utils custom exceptions.
+ */
+package org.onosproject.restconf.utils.exceptions;
\ No newline at end of file
diff --git a/apps/restconf/utils/src/main/java/org/onosproject/restconf/utils/package-info.java b/apps/restconf/utils/src/main/java/org/onosproject/restconf/utils/package-info.java
new file mode 100644
index 0000000..a3149ab
--- /dev/null
+++ b/apps/restconf/utils/src/main/java/org/onosproject/restconf/utils/package-info.java
@@ -0,0 +1,23 @@
+/*
+ * Copyright 2017-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.
+ * 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.
+ */
+
+/**
+ * Parser Utilities for:
+ * 1. input stream and object node conversion.
+ * 2. uri and resource id conversion.
+ * 3. object node and data node conversion.
+ */
+package org.onosproject.restconf.utils;
\ No newline at end of file