Interfaces added for PCEP messages and PCEP Controller

Change-Id: Id678b6832b42bcf4a437322996244d224c4052d0
diff --git a/pcep/api/pom.xml b/pcep/api/pom.xml
new file mode 100755
index 0000000..a315079
--- /dev/null
+++ b/pcep/api/pom.xml
@@ -0,0 +1,95 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  ~ Copyright 2014 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/maven-v4_0_0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>org.onosproject</groupId>
+        <artifactId>onos-pcep-controller</artifactId>
+        <version>1.3.0-SNAPSHOT</version>
+        <relativePath>../pom.xml</relativePath>
+    </parent>
+
+    <artifactId>onos-pcep-controller-api</artifactId>
+    <packaging>bundle</packaging>
+
+    <description>ONOS Pcep controller subsystem API</description>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.onosproject</groupId>
+            <artifactId>onos-pcepio</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>io.netty</groupId>
+            <artifactId>netty</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.onosproject</groupId>
+            <artifactId>onos-api</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.onosproject</groupId>
+            <artifactId>onlab-misc</artifactId>
+        </dependency>
+
+    </dependencies>
+
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-shade-plugin</artifactId>
+                <version>2.3</version>
+                <configuration>
+                    <artifactSet>
+                        <excludes>
+                            <exclude>io.netty:netty</exclude>
+                            <exclude>com.google.guava:guava</exclude>
+                            <exclude>org.slf4j:slfj-api</exclude>
+                            <exclude>ch.qos.logback:logback-core</exclude>
+                            <exclude>ch.qos.logback:logback-classic</exclude>
+                            <exclude>com.google.code.findbugs:annotations</exclude>
+                        </excludes>
+                    </artifactSet>
+                </configuration>
+                <executions>
+                    <execution>
+                        <phase>package</phase>
+                        <goals>
+                            <goal>shade</goal>
+                        </goals>
+                    </execution>
+                </executions>
+            </plugin>
+            <plugin>
+                <groupId>org.apache.felix</groupId>
+                <artifactId>maven-bundle-plugin</artifactId>
+                <configuration>
+                    <instructions>
+                        <Export-Package>
+                            org.onosproject.pcep.*,org.onosproject.pcepio.*
+                        </Export-Package>
+                    </instructions>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
+
+</project>
diff --git a/pcep/api/src/main/java/org/onosproject/pcep/controller/PccId.java b/pcep/api/src/main/java/org/onosproject/pcep/controller/PccId.java
new file mode 100755
index 0000000..3ff622b
--- /dev/null
+++ b/pcep/api/src/main/java/org/onosproject/pcep/controller/PccId.java
@@ -0,0 +1,120 @@
+/*
+ * Copyright 2015 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.pcep.controller;
+
+import static com.google.common.base.Preconditions.checkArgument;
+import java.net.URI;
+import java.net.URISyntaxException;
+import java.util.Objects;
+
+import org.onlab.packet.IpAddress;
+
+/**
+ * The class representing a network client pc ip.
+ * This class is immutable.
+ */
+public final class PccId {
+
+    private static final String SCHEME = "pcep";
+    private static final long UNKNOWN = 0;
+    private final IpAddress ipAddress;
+
+    /**
+     * Private constructor.
+     */
+    private PccId(IpAddress ipAddress) {
+        this.ipAddress = ipAddress;
+    }
+
+    /**
+     * Create a PccId from ip address.
+     *
+     * @param ipAddress IP address
+     * @return ipAddress
+     */
+    public static PccId pccId(IpAddress ipAddress) {
+        return new PccId(ipAddress);
+    }
+
+    /**
+     * Returns the ip address.
+     *
+     * @return ipAddress
+     */
+    public IpAddress ipAddress() {
+        return ipAddress;
+    }
+
+    /**
+     * Convert the PccId value to a ':' separated hexadecimal string.
+     *
+     * @return the PccId value as a ':' separated hexadecimal string.
+     */
+    @Override
+    public String toString() {
+        return ipAddress.toString();
+    }
+
+    @Override
+    public boolean equals(Object other) {
+        if (!(other instanceof PccId)) {
+            return false;
+        }
+
+        PccId otherPccid = (PccId) other;
+        return Objects.equals(ipAddress, otherPccid.ipAddress);
+    }
+
+    @Override
+    public int hashCode() {
+        return Objects.hash(ipAddress);
+    }
+
+    /**
+     * Returns PccId created from the given client URI.
+     *
+     * @param uri device URI
+     * @return pccid
+     */
+    public static PccId pccid(URI uri) {
+        checkArgument(uri.getScheme().equals(SCHEME), "Unsupported URI scheme");
+        return new PccId(IpAddress.valueOf(uri.getSchemeSpecificPart()));
+    }
+
+    /**
+     * Produces client URI from the given DPID.
+     *
+     * @param pccid client pccid
+     * @return client URI
+     */
+    public static URI uri(PccId pccid) {
+        return uri(pccid.ipAddress());
+    }
+
+    /**
+     * Produces client URI from the given ip address.
+     *
+     * @param ipAddress ip of client
+     * @return client URI
+     */
+    public static URI uri(IpAddress ipAddress) {
+        try {
+            return new URI(SCHEME, ipAddress.toString(), null);
+        } catch (URISyntaxException e) {
+            return null;
+        }
+    }
+}
diff --git a/pcep/api/src/main/java/org/onosproject/pcep/controller/PcepClient.java b/pcep/api/src/main/java/org/onosproject/pcep/controller/PcepClient.java
new file mode 100755
index 0000000..2c478ec
--- /dev/null
+++ b/pcep/api/src/main/java/org/onosproject/pcep/controller/PcepClient.java
@@ -0,0 +1,110 @@
+/*
+ * Copyright 2015 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.pcep.controller;
+
+import java.util.List;
+
+import org.onosproject.pcepio.protocol.PcepFactory;
+import org.onosproject.pcepio.protocol.PcepMessage;
+
+/**
+ * Represents to provider facing side of a path computation client(pcc).
+ */
+public interface PcepClient {
+
+    /**
+     * Writes the message to the driver.
+     *
+     * @param msg the message to write
+     */
+    public void sendMessage(PcepMessage msg);
+
+    /**
+     * Writes the PcepMessage list to the driver.
+     *
+     * @param msgs the messages to be written
+     */
+    public void sendMessage(List<PcepMessage> msgs);
+
+    /**
+     * Handle a message from the pcc.
+     *
+     * @param fromClient the message to handle
+     */
+    public void handleMessage(PcepMessage fromClient);
+
+    /**
+     * Provides the factory for this PCEP version.
+     *
+     * @return PCEP version specific factory.
+     */
+    public PcepFactory factory();
+
+    /**
+     * Gets a string version of the ID for this pcc.
+     *
+     * @return string version of the ID
+     */
+    public String getStringId();
+
+    /**
+     * Gets the ipAddress of the client.
+     *
+     * @return the client pccId in IPAddress format
+     */
+    public PccId getPccId();
+
+    /**
+     * Checks if the pcc is still connected.
+     *
+     * @return true if client is connected, false otherwise
+     */
+    public boolean isConnected();
+
+    /**
+     * Disconnects the pcc by closing the TCP connection. Results in a call
+     * to the channel handler's channelDisconnected method for cleanup.
+     */
+    public void disconnectClient();
+
+    /**
+     * Indicates if this pcc is optical.
+     *
+     * @return true if optical
+     */
+    public boolean isOptical();
+
+    /**
+     * Identifies the channel used to communicate with the pcc.
+     *
+     * @return string representation of the connection to the client
+     */
+    public String channelId();
+
+    /**
+     * To set the status of state synchronization.
+     *
+     * @param value to set the synchronization status
+     */
+    public void setIsSyncComplete(boolean value);
+
+    /**
+     * Indicates the state synchronization status of this pcc.
+     *
+     * @return true/false if the synchronization is completed/not completed
+     */
+    public boolean isSyncComplete();
+}
diff --git a/pcep/api/src/main/java/org/onosproject/pcep/controller/PcepClientController.java b/pcep/api/src/main/java/org/onosproject/pcep/controller/PcepClientController.java
new file mode 100755
index 0000000..1a7cd39
--- /dev/null
+++ b/pcep/api/src/main/java/org/onosproject/pcep/controller/PcepClientController.java
@@ -0,0 +1,93 @@
+/*
+ * Copyright 2015 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.pcep.controller;
+
+import java.util.List;
+
+import org.onosproject.pcepio.protocol.PcepMessage;
+
+/**
+ * Abstraction of an Pcep controller. Serves as a one stop
+ * shop for obtaining Pcep devices and (un)register listeners
+ * on pcep events
+ */
+public interface PcepClientController {
+
+    /**
+     * Returns list of pcc clients connected to this Pcep controller.
+     *
+     * @return list of PcepClient elements
+     */
+    public List<PcepClient> getClients();
+
+    /**
+     * Returns the actual pcc client for the given ip address.
+     *
+     * @param pccId the id of the pcc client to fetch
+     * @return the interface to this pcc client
+     */
+    public PcepClient getClient(PccId pccId);
+
+    /**
+     * Register a listener for meta events that occur to pcep
+     * devices.
+     *
+     * @param listener the listener to notify
+     */
+    public void addListener(PcepClientListener listener);
+
+    /**
+     * Unregister a listener.
+     *
+     * @param listener the listener to unregister
+     */
+    public void removeListener(PcepClientListener listener);
+
+    /**
+     * Register a listener for OF msg events.
+     *
+     * @param listener the listener to notify
+     */
+    public void addEventListener(PcepEventListener listener);
+
+    /**
+     * Unregister a listener.
+     *
+     * @param listener the listener to unregister
+     */
+    public void removeEventListener(PcepEventListener listener);
+
+    /**
+     * Send a message to a particular pcc client.
+     *
+     * @param pccId the id of the client to send message.
+     * @param msg the message to send
+     */
+    public void writeMessage(PccId pccId, PcepMessage msg);
+
+    /**
+     * Process a message and notify the appropriate listeners.
+     *
+     * @param pccId id of the client the message arrived on
+     * @param msg the message to process.
+     */
+    public void processClientMessage(PccId pccId, PcepMessage msg);
+
+    /**
+     * Close all connected PCC clients.
+     */
+    public void closeConnectedClients();
+}
diff --git a/pcep/api/src/main/java/org/onosproject/pcep/controller/PcepClientListener.java b/pcep/api/src/main/java/org/onosproject/pcep/controller/PcepClientListener.java
new file mode 100755
index 0000000..3f7e0f0
--- /dev/null
+++ b/pcep/api/src/main/java/org/onosproject/pcep/controller/PcepClientListener.java
@@ -0,0 +1,36 @@
+/*
+ * Copyright 2015 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.pcep.controller;
+
+/**
+ * Allows for providers interested in PCC client events to be notified.
+ */
+public interface PcepClientListener {
+
+    /**
+     * Notify that the PCC was connected.
+     *
+     * @param pccId the id of the client that connected
+     */
+    public void clientConnected(PccId pccId);
+
+    /**
+     * Notify that the PCC was disconnected.
+     *
+     * @param pccId the id of the client that disconnected.
+     */
+    public void clientDisconnected(PccId pccId);
+}
diff --git a/pcep/api/src/main/java/org/onosproject/pcep/controller/PcepEventListener.java b/pcep/api/src/main/java/org/onosproject/pcep/controller/PcepEventListener.java
new file mode 100755
index 0000000..905749b
--- /dev/null
+++ b/pcep/api/src/main/java/org/onosproject/pcep/controller/PcepEventListener.java
@@ -0,0 +1,31 @@
+/*
+ * Copyright 2015 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.pcep.controller;
+
+import org.onosproject.pcepio.protocol.PcepMessage;
+/**
+ * Notifies providers about pcep msg events.
+ */
+public interface PcepEventListener {
+
+    /**
+     * Handles the message event.
+     *
+     * @param pccId id of the pcc
+     * @param msg the message
+     */
+    public void handleMessage(PccId pccId, PcepMessage msg);
+}
diff --git a/pcep/api/src/main/java/org/onosproject/pcep/controller/PcepPacketStats.java b/pcep/api/src/main/java/org/onosproject/pcep/controller/PcepPacketStats.java
new file mode 100755
index 0000000..92bb2db
--- /dev/null
+++ b/pcep/api/src/main/java/org/onosproject/pcep/controller/PcepPacketStats.java
@@ -0,0 +1,58 @@
+/*
+ * Copyright 2015 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.pcep.controller;
+
+/**
+ * The representation for PCEP packet statistics.
+ */
+public interface PcepPacketStats {
+
+    /**
+     * Returns the count for no of packets sent out.
+     *
+     * @return int value of no of packets sent
+     */
+    public int outPacketCount();
+
+    /**
+     * Returns the count for no of packets received.
+     *
+     * @return int value of no of packets sent
+     */
+    public int inPacketCount();
+
+    /**
+     * Returns the count for no of wrong packets received.
+     *
+     * @return int value of no of wrong packets received
+     */
+    public int wrongPacketCount();
+
+    /**
+     * Returns the time value.
+     *
+     * @return long value of time
+     */
+    public long getTime();
+
+    /**
+     * Sets the time value.
+     *
+     * @param time long value of time
+     */
+    public void setTime(long time);
+
+}
diff --git a/pcep/api/src/main/java/org/onosproject/pcep/controller/driver/PcepAgent.java b/pcep/api/src/main/java/org/onosproject/pcep/controller/driver/PcepAgent.java
new file mode 100755
index 0000000..71ed834
--- /dev/null
+++ b/pcep/api/src/main/java/org/onosproject/pcep/controller/driver/PcepAgent.java
@@ -0,0 +1,63 @@
+/*
+ * Copyright 2015 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.pcep.controller.driver;
+
+import org.onosproject.pcep.controller.PccId;
+import org.onosproject.pcep.controller.PcepClient;
+import org.onosproject.pcepio.protocol.PcepMessage;
+
+/**
+ * Responsible for keeping track of the current set Pcep clients
+ * connected to the system.
+ *
+ */
+public interface PcepAgent {
+
+    /**
+     * Add a pcc client that has just connected to the system.
+     *
+     * @param pccId the id of pcc client to add
+     * @param pc the actual pce client object.
+     * @return true if added, false otherwise.
+     */
+    public boolean addConnectedClient(PccId pccId, PcepClient pc);
+
+    /**
+     * Checks if the activation for this pcc client is valid.
+     *
+     * @param pccId the id of pcc client to check
+     * @return true if valid, false otherwise
+     */
+    public boolean validActivation(PccId pccId);
+
+    /**
+     * Clear all state in controller client maps for a pcc client that has
+     * disconnected from the local controller. Also release control for
+     * that pccIds client from the global repository. Notify client listeners.
+     *
+     * @param pccIds the id of pcc client to remove.
+     */
+    public void removeConnectedClient(PccId pccIds);
+
+    /**
+     * Process a message coming from a pcc client.
+     *
+     * @param pccId the id of pcc client the message was received.
+     * @param m the message to process
+     */
+    public void processPcepMessage(PccId pccId, PcepMessage m);
+
+}
diff --git a/pcep/api/src/main/java/org/onosproject/pcep/controller/driver/PcepClientDriver.java b/pcep/api/src/main/java/org/onosproject/pcep/controller/driver/PcepClientDriver.java
new file mode 100755
index 0000000..16d0b0b
--- /dev/null
+++ b/pcep/api/src/main/java/org/onosproject/pcep/controller/driver/PcepClientDriver.java
@@ -0,0 +1,110 @@
+/*
+ * Copyright 2015 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.pcep.controller.driver;
+
+import org.jboss.netty.channel.Channel;
+import org.onosproject.pcep.controller.PccId;
+import org.onosproject.pcep.controller.PcepClient;
+import org.onosproject.pcep.controller.PcepPacketStats;
+import org.onosproject.pcepio.protocol.PcepVersion;
+
+
+/**
+ * Represents the driver side of an Path computation client(pcc).
+ *
+ */
+public interface PcepClientDriver extends PcepClient {
+
+    /**
+     * Sets the Pcep agent to be used. This method
+     * can only be called once.
+     *
+     * @param agent the agent to set.
+     */
+    public void setAgent(PcepAgent agent);
+
+    /**
+     * Announce to the Pcep agent that this pcc client has connected.
+     *
+     * @return true if successful, false if duplicate switch.
+     */
+    public boolean connectClient();
+
+    /**
+     * Remove this pcc client from the Pcep agent.
+     */
+    public void removeConnectedClient();
+
+    /**
+     * Sets the PCEP version for this pcc.
+     *
+     * @param pcepVersion the version to set.
+     */
+    public void setPcVersion(PcepVersion pcepVersion);
+
+    /**
+     * Sets the associated Netty channel for this pcc.
+     *
+     * @param channel the Netty channel
+     */
+    public void setChannel(Channel channel);
+
+
+    /**
+     * Sets the keep alive time for this pcc.
+     *
+     * @param keepAliveTime the keep alive time to set.
+     */
+    public void setPcKeepAliveTime(byte keepAliveTime);
+
+    /**
+     * Sets the dead time for this pcc.
+     *
+     * @param deadTime the dead timer value to set.
+     */
+    public void setPcDeadTime(byte deadTime);
+
+    /**
+     * Sets the session id for this pcc.
+     *
+     * @param sessionId the session id value to set.
+     */
+    public void setPcSessionId(byte sessionId);
+
+    /**
+     * Sets whether the pcc is connected.
+     *
+     * @param connected whether the pcc is connected
+     */
+    public void setConnected(boolean connected);
+
+    /**
+     * Initializes the behavior.
+     *
+     * @param pccId id of pcc
+     * @param pcepVersion Pcep version
+     * @param pktStats Pcep Packet Stats
+     */
+    void init(PccId pccId, PcepVersion pcepVersion, PcepPacketStats pktStats);
+
+    /**
+     * Checks whether the handshake is complete.
+     *
+     * @return true is finished, false if not.
+     */
+    boolean isHandshakeComplete();
+
+}
diff --git a/pcep/api/src/main/java/org/onosproject/pcep/controller/driver/PcepClientDriverFactory.java b/pcep/api/src/main/java/org/onosproject/pcep/controller/driver/PcepClientDriverFactory.java
new file mode 100755
index 0000000..d1e4733
--- /dev/null
+++ b/pcep/api/src/main/java/org/onosproject/pcep/controller/driver/PcepClientDriverFactory.java
@@ -0,0 +1,38 @@
+/*
+ * Copyright 2015 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.pcep.controller.driver;
+
+import org.onlab.packet.IpAddress;
+import org.onosproject.pcepio.protocol.PcepVersion;
+
+/**
+ * Pcc Client factory which returns concrete pcc client objects for the
+ * physical pcc client in use.
+ *
+ */
+public interface PcepClientDriverFactory {
+
+
+    /**
+     * Constructs the real Pcep Client representation.
+     *
+     * @param pccIpAddress the ip address for this pcc client.
+     * @param pcepVersion the Pcep version in use
+     * @return the Pcep client representation.
+     */
+    public PcepClientDriver getPcepClientImpl(IpAddress pccIpAddress,
+            PcepVersion pcepVersion);
+}
diff --git a/pcep/api/src/main/java/org/onosproject/pcep/controller/driver/package-info.java b/pcep/api/src/main/java/org/onosproject/pcep/controller/driver/package-info.java
new file mode 100755
index 0000000..2748ecc
--- /dev/null
+++ b/pcep/api/src/main/java/org/onosproject/pcep/controller/driver/package-info.java
@@ -0,0 +1,20 @@
+/*
+ * Copyright 2015 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.
+ */
+
+/**
+ * PCEP controller driver API.
+ */
+package org.onosproject.pcep.controller.driver;
diff --git a/pcep/api/src/main/java/org/onosproject/pcep/controller/package-info.java b/pcep/api/src/main/java/org/onosproject/pcep/controller/package-info.java
new file mode 100755
index 0000000..547b68d
--- /dev/null
+++ b/pcep/api/src/main/java/org/onosproject/pcep/controller/package-info.java
@@ -0,0 +1,20 @@
+/*
+ * Copyright 2015 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.
+ */
+
+/**
+ * PCEP controller API.
+ */
+package org.onosproject.pcep.controller;
diff --git a/pcep/pcepio/pom.xml b/pcep/pcepio/pom.xml
new file mode 100755
index 0000000..ef25d40
--- /dev/null
+++ b/pcep/pcepio/pom.xml
@@ -0,0 +1,77 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  ~ Copyright 2014 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/maven-v4_0_0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>org.onosproject</groupId>
+        <artifactId>onos-pcep-controller</artifactId>
+        <version>1.3.0-SNAPSHOT</version>
+        <relativePath>../pom.xml</relativePath>
+    </parent>
+
+    <artifactId>onos-pcepio</artifactId>
+    <packaging>bundle</packaging>
+
+    <description>ONOS Pcepio Protocol subsystem</description>
+   
+
+    <dependencies>
+        <dependency>
+            <groupId>org.onosproject</groupId>
+            <artifactId>onos-api</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.onosproject</groupId>
+            <artifactId>onlab-osgi</artifactId>
+        </dependency>
+
+        <dependency>
+            <groupId>com.fasterxml.jackson.core</groupId>
+            <artifactId>jackson-databind</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>com.fasterxml.jackson.core</groupId>
+            <artifactId>jackson-annotations</artifactId>
+        </dependency>
+
+        <dependency>
+            <groupId>org.osgi</groupId>
+            <artifactId>org.osgi.core</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.karaf.shell</groupId>
+            <artifactId>org.apache.karaf.shell.console</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.felix</groupId>
+            <artifactId>org.apache.felix.scr.annotations</artifactId>
+        </dependency>
+    </dependencies>
+
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.felix</groupId>
+                <artifactId>maven-bundle-plugin</artifactId>
+            </plugin>            
+        </plugins>
+    </build>
+
+</project>
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/exceptions/PcepParseException.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/exceptions/PcepParseException.java
new file mode 100755
index 0000000..85bc33f
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/exceptions/PcepParseException.java
@@ -0,0 +1,92 @@
+/*
+ * Copyright 2015 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.pcepio.exceptions;
+
+/**
+ * Custom Exception for PCEP IO.
+ */
+public class PcepParseException extends Exception {
+
+    private static final long serialVersionUID = 7960991379951448423L;
+    private byte errType = 0;
+    private byte errValue = 0;
+
+    /**
+     * Default constructor to create a new exception.
+     */
+    public PcepParseException() {
+        super();
+    }
+
+    /**
+     * Constructor to create exception from message and cause.
+     *
+     * @param message the detail of exception in string
+     * @param cause underlying cause of the error
+     */
+    public PcepParseException(final String message, final Throwable cause) {
+        super(message, cause);
+    }
+
+    /**
+     * Constructor to create exception from message.
+     *
+     * @param message the detail of exception in string
+     */
+    public PcepParseException(final String message) {
+        super(message);
+    }
+
+    /**
+     * Constructor to create exception from error type and error value.
+     *
+     * @param errType error type of pcep
+     * @param errValue error value of pcep
+     */
+    public PcepParseException(final byte errType, final byte errValue) {
+        super();
+        this.errType = errType;
+        this.errValue = errValue;
+    }
+
+    /**
+     * Constructor to create exception from cause.
+     *
+     * @param cause underlying cause of the error
+     */
+    public PcepParseException(final Throwable cause) {
+        super(cause);
+    }
+
+    /**
+     * Returns error type for this exception.
+     *
+     * @return ErrorType
+     */
+    public byte getErrorType() {
+        return this.errType;
+    }
+
+    /**
+     * Returns error value for this exception.
+     *
+     * @return ErrorValue
+     */
+    public byte getErrorValue() {
+        return this.errValue;
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/exceptions/PcepTunnelAttributeException.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/exceptions/PcepTunnelAttributeException.java
new file mode 100755
index 0000000..25bdf5b
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/exceptions/PcepTunnelAttributeException.java
@@ -0,0 +1,60 @@
+/*
+ * Copyright 2015 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.pcepio.exceptions;
+
+/**
+ * Custom exception for Tunnel Attributes.
+ */
+public class PcepTunnelAttributeException extends Exception {
+
+    private static final long serialVersionUID = 7860981378961458434L;
+
+    /**
+     * Default constructor to create a new exception.
+     */
+    public PcepTunnelAttributeException() {
+        super();
+    }
+
+    /**
+     * Constructor to create exception from message and cause.
+     *
+     * @param message the detail of exception in string
+     * @param cause underlying cause of the error
+     */
+    public PcepTunnelAttributeException(final String message, final Throwable cause) {
+        super(message, cause);
+    }
+
+    /**
+     * Constructor to create exception from message.
+     *
+     * @param message the detail of exception in string
+     */
+    public PcepTunnelAttributeException(final String message) {
+        super(message);
+    }
+
+    /**
+     * Constructor to create exception from cause.
+     *
+     * @param cause underlying cause of the error
+     */
+    public PcepTunnelAttributeException(final Throwable cause) {
+        super(cause);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcInitiatedLspRequest.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcInitiatedLspRequest.java
new file mode 100755
index 0000000..990ee69
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcInitiatedLspRequest.java
@@ -0,0 +1,190 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+import org.onosproject.pcepio.exceptions.PcepParseException;

+

+/**

+ * Abstraction of an entity Provides PcInitiatedLspRequest for PCEP Initiate message.

+ * Reference : PCE initiated tunnel setup draft-ietf-pce-pce-initiated-lsp-03.

+ */

+public interface PcInitiatedLspRequest {

+

+    /**

+     * Returns object of PcepSrpObject.

+     *

+     * @return srpObject PCEP SRP object

+     */

+    PcepSrpObject getSrpObject();

+

+    /**

+     * Returns object of PcepLspObject.

+     *

+     * @return lspObject PCEP LSP object

+     */

+    PcepLspObject getLspObject();

+

+    /**

+     * Returns object of PcepEndPointsObject.

+     *

+     * @return endPointsObject PCEP EndPoints object

+     */

+    PcepEndPointsObject getEndPointsObject();

+

+    /**

+     * Returns object of PcepEroObject.

+     *

+     * @return eroObject PCEP ERO object

+     */

+    PcepEroObject getEroObject();

+

+    /**

+     * Returns object of PcepAttribute.

+     *

+     * @return pcepAttribute PCEP Attributes

+     */

+    PcepAttribute getPcepAttribute();

+

+    /**

+     * Sets PcepSrpObject.

+     *

+     * @param srpobj PCEP SRP object

+     */

+    void setSrpObject(PcepSrpObject srpobj);

+

+    /**

+     * Sets PcepLspObject.

+     *

+     * @param lspObject PCEP LSP object

+     */

+    void setLspObject(PcepLspObject lspObject);

+

+    /**

+     * Sets PcepEndPointsObject.

+     *

+     * @param endPointsObject PCEP EndPoints object

+     */

+    void setEndPointsObject(PcepEndPointsObject endPointsObject);

+

+    /**

+     * Sets PcepEroObject.

+     *

+     * @param eroObject PCEP ERO object

+     */

+    void setEroObject(PcepEroObject eroObject);

+

+    /**

+     * Sets PcepAttribute.

+     *

+     * @param pcepAttribute PCEP Attributes

+     */

+    void setPcepAttribute(PcepAttribute pcepAttribute);

+

+    /**

+     * Prints the attribute of PC-INITIATED LSP INITIATION REQUEST.

+     */

+    void print();

+

+    /**

+     * Builder interface with get and set functions to build PcInitiatedLspRequest.

+     */

+    public interface Builder {

+

+        /**

+         * Builds PcInitiatedLspRequest.

+         *

+         * @return PcInitiatedLspRequest

+         * @throws PcepParseException when mandatory object is not set

+         */

+        PcInitiatedLspRequest build() throws PcepParseException;

+

+        /**

+         * Returns object of PcepSrpObject.

+         *

+         * @return srpObject

+         */

+        PcepSrpObject getSrpObject();

+

+        /**

+         * Returns object of PcepLspObject.

+         *

+         * @return lspObject

+         */

+        PcepLspObject getLspObject();

+

+        /**

+         * Returns object of PcepEndPointsObject.

+         *

+         * @return endPointsObject

+         */

+        PcepEndPointsObject getEndPointsObject();

+

+        /**

+         * Returns object of PcepEroObject.

+         *

+         * @return eroObject

+         */

+        PcepEroObject getEroObject();

+

+        /**

+         * Returns object of PcepAttribute.

+         *

+         * @return pcepAttribute

+         */

+        PcepAttribute getPcepAttribute();

+

+        /**

+         * Sets PcepSrpObject.

+         *

+         * @param srpobj PCEP SRP Object

+         * @return builder by setting PcepSrpObject

+         */

+        Builder setSrpObject(PcepSrpObject srpobj);

+

+        /**

+         * Sets PcepLspObject.

+         *

+         * @param lspObject PCEP LSP Object

+         * @return builder by setting PcepLspObject

+         */

+        Builder setLspObject(PcepLspObject lspObject);

+

+        /**

+         * Sets PcepEndPointsObject.

+         *

+         * @param endPointsObject EndPoints Object

+         * @return builder by setting PcepEndPointsObject

+         */

+        Builder setEndPointsObject(PcepEndPointsObject endPointsObject);

+

+        /**

+         * Sets PcepEroObject.

+         *

+         * @param eroObject PCEP ERO Object

+         * @return builder by setting PcepEroObject

+         */

+        Builder setEroObject(PcepEroObject eroObject);

+

+        /**

+         * Sets PcepAttribute.

+         *

+         * @param pcepAttribute PCEP Attributes

+         * @return builder by setting PcepAttribute

+         */

+        Builder setPcepAttribute(PcepAttribute pcepAttribute);

+    }

+}

diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepAttribute.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepAttribute.java
new file mode 100755
index 0000000..cba9a53
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepAttribute.java
@@ -0,0 +1,172 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+/**

+ * Abstraction of an entity which Provides List of PCEP Attributes.

+ */

+import java.util.LinkedList;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+

+public interface PcepAttribute {

+

+    /**

+     * writes lspa , bandwidth , Metriclist and Iro objects to the channel.

+     *

+     * @param bb of type channel buffer.

+     * @return object length index.

+     * @throws PcepParseException while writing objects to channel buffer

+     */

+    public int write(ChannelBuffer bb) throws PcepParseException;

+

+    /**

+     * Returns PcepLspaObject.

+     *

+     * @return LspaObject

+     */

+    PcepLspaObject getLspaObject();

+

+    /**

+     * Returns PcepBandwidthObject.

+     *

+     * @return BandwidthObject

+     */

+    PcepBandwidthObject getBandwidthObject();

+

+    /**

+     * Returns PcepIroObject.

+     *

+     * @return iroObject

+     */

+    PcepIroObject getIroObject();

+

+    /**

+     * Sets the PcepBandwidthObject.

+     *

+     * @param bandwidthObject bandwidth object

+     */

+    void setBandwidthObject(PcepBandwidthObject bandwidthObject);

+

+    /**

+     * Sets the PcepLspaObject.

+     *

+     * @param lspaObject lspa object

+     */

+    void setLspaObject(PcepLspaObject lspaObject);

+

+    /**

+     * Sets the PcepIroObject.

+     *

+     * @param iroObject iro object

+     */

+    void setIroObject(PcepIroObject iroObject);

+

+    /**

+     * Returns PcepMetricObject List.

+     *

+     * @return list of metric objects

+     */

+    LinkedList<PcepMetricObject> getMetricObjectList();

+

+    /**

+     * Sets PcepMetricObject List.

+     *

+     * @param llMetricList list of metric objects

+     */

+    void setMetricObjectList(LinkedList<PcepMetricObject> llMetricList);

+

+    /**

+     * Prints the attributes of AttributeList.

+     */

+

+    public void print();

+

+    /**

+     * Builder interface with get and set functions to build PcepAttribute.

+     */

+    public interface Builder {

+

+        /**

+         * Builds PcepAttribute.

+         *

+         * @return PcepAttribute

+         */

+        PcepAttribute build();

+

+        /**

+         * Returns PcepLspaObject.

+         *

+         * @return LspaObject

+         */

+        PcepLspaObject getLspaObject();

+

+        /**

+         * Returns PcepBandwidthObject.

+         *

+         * @return BandwidthObject

+         */

+        PcepBandwidthObject getBandwidthObject();

+

+        /**

+         * Returns PcepIroObject.

+         *

+         * @return iroObject

+         */

+        PcepIroObject getIroObject();

+

+        /**

+         * Sets the PcepBandwidthObject.

+         *

+         * @param bandwidthObject bandwidth object

+         * @return Builder object for PcepAttrubute

+         */

+        Builder setBandwidthObject(PcepBandwidthObject bandwidthObject);

+

+        /**

+         * Sets the PcepLspaObject.

+         *

+         * @param lspaObject lspa object

+         * @return Builder object for PcepAttrubute

+         */

+        Builder setLspaObject(PcepLspaObject lspaObject);

+

+        /**

+         * Sets the PcepIroObject.

+         *

+         * @param iroObject iro object

+         * @return Builder object for PcepAttrubute

+         */

+        Builder setIroObject(PcepIroObject iroObject);

+

+        /**

+         * Returns PcepMetricObject List.

+         *

+         * @return list of metric objects

+         */

+        LinkedList<PcepMetricObject> getMetricObjectList();

+

+        /**

+         * Sets PcepMetricObject List.

+         *

+         * @param llMetricList list of metric objects

+         * @return Builder object for PcepAttrubute

+         */

+        Builder setMetricObjectList(LinkedList<PcepMetricObject> llMetricList);

+    }

+}
\ No newline at end of file
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepBandwidthObject.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepBandwidthObject.java
new file mode 100755
index 0000000..323889d
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepBandwidthObject.java
@@ -0,0 +1,114 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+import org.onosproject.pcepio.types.PcepObjectHeader;

+

+/**

+ * Abstraction of an entity providing PCEP Bandwidth Object.

+ */

+public interface PcepBandwidthObject {

+

+    /**

+     * Returns bandwidth value.

+     *

+     * @return bandwidth value

+     */

+    int getBandwidth();

+

+    /**

+     * Sets bandwidth with specified value.

+     *

+     * @param iBandwidth Bandwidth's value

+     */

+    void setBandwidth(int iBandwidth);

+

+    /**

+     * Prints attributes of bandwidth object.

+     */

+    void print();

+

+    /**

+     * Writes the BandwidthObject into channel buffer.

+     *

+     * @param bb channel buffer

+     * @return Returns the writerIndex of this buffer

+     * @throws PcepParseException if bandwidth object header fails to write in channel buffer

+     */

+    public int write(ChannelBuffer bb) throws PcepParseException;

+

+    /**

+     * Builder interface with get and set functions to build bandwidth object.

+     */

+    public interface Builder {

+

+        /**

+         * Builds BandwidthObject.

+         *

+         * @return BandwidthObject

+         * @throws PcepParseException if build fails while creating PcepBandwidthObject

+         */

+        PcepBandwidthObject build() throws PcepParseException;

+

+        /**

+         * Returns bandwidth object header.

+         *

+         * @return bandwidth object header

+         */

+        PcepObjectHeader getBandwidthObjHeader();

+

+        /**

+         * Sets bandwidth object header and returns its builder.

+         *

+         * @param obj Bandwidth object header

+         * @return Builder by setting Bandwidth object header

+         */

+        Builder setBandwidthObjHeader(PcepObjectHeader obj);

+

+        /**

+         * Returns bandwidth value.

+         *

+         * @return bandwidth

+         */

+        int getBandwidth();

+

+        /**

+         * Sets bandwidth value and return its builder.

+         *

+         * @param iBandwidth bandwidth value

+         * @return Builder by setting bandwidth

+         */

+        Builder setBandwidth(int iBandwidth);

+

+        /**

+         * Sets P flag in Bandwidth object header and returns its builder.

+         *

+         * @param value boolean value to set P flag

+         * @return Builder by setting P flag

+         */

+        Builder setPFlag(boolean value);

+

+        /**

+         * Sets I flag in Bandwidth object header and returns its builder.

+         *

+         * @param value boolean value to set I flag

+         * @return Builder by setting I flag

+         */

+        Builder setIFlag(boolean value);

+    }

+}

diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepCloseMsg.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepCloseMsg.java
new file mode 100755
index 0000000..15295a4
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepCloseMsg.java
@@ -0,0 +1,142 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import java.util.LinkedList;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.types.PcepObjectHeader;
+import org.onosproject.pcepio.types.PcepValueType;
+
+/**
+ * Abstraction of an entity providing PCEP Close Message.
+ */
+public interface PcepCloseMsg extends PcepObject, PcepMessage {
+
+    @Override
+    PcepVersion getVersion();
+
+    @Override
+    PcepType getType();
+
+    /**
+     * Returns reason field in Close message.
+     *
+     * @return reason field
+     */
+    byte getReason();
+
+    /**
+     * Sets reason field in Close message with specified value.
+     *
+     * @param value of Reason field
+     */
+    void setReason(byte value);
+
+    /**
+     * Returns LinkedList of Optional Tlv in Close Message.
+     *
+     * @return list of optional tlv
+     */
+    LinkedList<PcepValueType> getOptionalTlv();
+
+    /**
+     * Sets LinkedList of Optional Tlvs in Close Message.
+     *
+     * @param llOptionalTlv LinkedList of type PcepValueType
+     */
+    void setOptionalTlv(LinkedList<PcepValueType> llOptionalTlv);
+
+    @Override
+    void writeTo(ChannelBuffer channelBuffer);
+
+    /**
+     * Builder interface with get and set functions to build Close message.
+     */
+    public interface Builder extends PcepMessage.Builder {
+
+        @Override
+        PcepCloseMsg build();
+
+        @Override
+        PcepVersion getVersion();
+
+        @Override
+        PcepType getType();
+
+        /**
+         * Returns Close Object header.
+         *
+         * @return Close Object header
+         */
+        PcepObjectHeader getCloseObjHeader();
+
+        /**
+         * Sets close object header and returns its builder.
+         *
+         * @param obj close object header
+         * @return Builder by setting Close object header
+         */
+        Builder setCloseObjHeader(PcepObjectHeader obj);
+
+        /**
+         * Returns reason field in Close message.
+         *
+         * @return reason field in Close message
+         */
+        byte getReason();
+
+        /**
+         * Sets reason field and return its builder.
+         *
+         * @param value of Reason field
+         * @return builder by setting reason field
+         */
+        Builder setReason(byte value);
+
+        /**
+         * Returns LinkedList of Optional Tlvs.
+         *
+         * @return list of optional tlv
+         */
+        LinkedList<PcepValueType> getOptionalTlv();
+
+        /**
+         * Sets LinkedList of Optional Tlvs in Close Message.
+         *
+         * @param llOptionalTlv list of optional tlv
+         * @return Builder by setting Optional Tlvs
+         */
+        Builder setOptionalTlv(LinkedList<PcepValueType> llOptionalTlv);
+
+        /**
+         * Sets P flag in Close object header and returns its builder.
+         *
+         * @param value boolean value to set P flag
+         * @return Builder by setting P flag
+         */
+        Builder setPFlag(boolean value);
+
+        /**
+         * Sets I flag in Close object header and returns its builder.
+         *
+         * @param value boolean value to set I flag
+         * @return Builder by setting I flag
+         */
+        Builder setIFlag(boolean value);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepEndPointsObject.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepEndPointsObject.java
new file mode 100755
index 0000000..8a486c3
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepEndPointsObject.java
@@ -0,0 +1,144 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+import org.onosproject.pcepio.types.PcepObjectHeader;
+
+/**
+ * Abstraction of an entity providing PCEP End Points Object.
+ */
+public interface PcepEndPointsObject {
+
+    /**
+     * Returns Source IpAddress from End Points Object.
+     *
+     * @return Source IpAddress from End Points Object
+     */
+    int getSourceIpAddress();
+
+    /**
+     * Sets Source IpAddress in End Points Object.
+     *
+     * @param sourceIpAddress Source IP Address
+     */
+    void setSourceIpAddress(int sourceIpAddress);
+
+    /**
+     * Returns Destination IpAddress from End Points Object.
+     *
+     * @return Destination IpAddress from End Points Object
+     */
+    int getDestIpAddress();
+
+    /**
+     * Sets Destination IpAddress in End Points Object.
+     *
+     * @param destIpAddress Destination IP Address
+     */
+    void setDestIpAddress(int destIpAddress);
+
+    /**
+     * Prints attributes of EndPoints object.
+     */
+    void print();
+
+    /**
+     * Writes the EndPointsObject into channel buffer.
+     *
+     * @param bb channel buffer
+     * @return Returns the writerIndex of this buffer
+     * @throws PcepParseException while writing EndPointObject into ChannelBuffer
+     */
+    int write(ChannelBuffer bb) throws PcepParseException;
+
+    /**
+     * Builder interface with get and set functions to build EndPoints object.
+     */
+    public interface Builder {
+
+        /**
+         * Builds End Points Object.
+         *
+         * @return End Points Object
+         * @throws PcepParseException while building EndPointObject
+         */
+        PcepEndPointsObject build() throws PcepParseException;
+
+        /**
+         * Returns End Points Object header.
+         *
+         * @return End Points Object header
+         */
+        PcepObjectHeader getEndPointsObjHeader();
+
+        /**
+         * Sets End Points Object header and returns its builder.
+         *
+         * @param obj End Points Object header
+         * @return Builder by setting End Points Object header
+         */
+        Builder setEndPointsObjHeader(PcepObjectHeader obj);
+
+        /**
+         * Returns Source IpAddress from End Points Object.
+         *
+         * @return Source IpAddress from End Points Object
+         */
+        int getSourceIpAddress();
+
+        /**
+         * Sets Source IpAddress in End Points Object and returns builder.
+         *
+         * @param sourceIpAddress Source IP Address
+         * @return Builder by setting Source IpAddress in End Points Object
+         */
+        Builder setSourceIpAddress(int sourceIpAddress);
+
+        /**
+         * Returns Destination IpAddress from End Points Object.
+         *
+         * @return Destination IpAddress from End Points Object
+         */
+        int getDestIpAddress();
+
+        /**
+         * Sets Destination IpAddress in End Points Object.
+         *
+         * @param destIpAddress Destination IP Address
+         * @return Builder by setting Destination IpAddress in End Points Object
+         */
+        Builder setDestIpAddress(int destIpAddress);
+
+        /**
+         * Sets P flag in Bandwidth object header and returns its builder.
+         *
+         * @param value boolean value to set P flag
+         * @return Builder by setting P flag
+         */
+        Builder setPFlag(boolean value);
+
+        /**
+         * Sets I flag in Bandwidth object header and returns its builder.
+         *
+         * @param value boolean value to set I flag
+         * @return Builder by setting I flag
+         */
+        Builder setIFlag(boolean value);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepEroObject.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepEroObject.java
new file mode 100755
index 0000000..7c3fb2d
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepEroObject.java
@@ -0,0 +1,117 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+import java.util.LinkedList;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+import org.onosproject.pcepio.types.PcepObjectHeader;

+import org.onosproject.pcepio.types.PcepValueType;

+

+/**

+ * Abstraction of an entity providing PCEP ERO Object.

+ */

+public interface PcepEroObject {

+

+    /**

+     * Return LinkedList of SubObjects of ERO Object.

+     *

+     * @return list of subobjects

+     */

+    LinkedList<PcepValueType> getSubObjects();

+

+    /**

+     * Sets LinkedList of SubObjects in ERO Object.

+     *

+     * @param llSubObjects list of subobjects

+     */

+    void setSubObjects(LinkedList<PcepValueType> llSubObjects);

+

+    /**

+     * Writes the ERO Object into channel buffer.

+     *

+     * @param bb channel buffer

+     * @return Returns the writerIndex of this buffer

+     * @throws PcepParseException while writing ERO Object into ChannelBuffer

+     */

+    public int write(ChannelBuffer bb) throws PcepParseException;

+

+    /**

+     * Prints attributes of ERO object.

+     */

+    void print();

+

+    /**

+     * Builder interface with get and set functions to build ERO object.

+     */

+    public interface Builder {

+

+        /**

+         * Builds ERO Object.

+         *

+         * @return ERO Object

+         */

+        PcepEroObject build();

+

+        /**

+         * Returns ERO Object Header.

+         *

+         * @return ERO Object Header

+         */

+        PcepObjectHeader getEroObjHeader();

+

+        /**

+         * Sets ERO Object header and returns its builder.

+         *

+         * @param obj ERO Object header

+         * @return Builder by setting ERO Object header

+         */

+        Builder setEroObjHeader(PcepObjectHeader obj);

+

+        /**

+         * Returns LinkedList of SubObjects in ERO Objects.

+         *

+         * @return list of subobjects

+         */

+        LinkedList<PcepValueType> getSubObjects();

+

+        /**

+         * Sets LinkedList of SubObjects and returns its builder.

+         *

+         * @param llSubObjects list of SubObjects

+         * @return Builder by setting list of SubObjects

+         */

+        Builder setSubObjects(LinkedList<PcepValueType> llSubObjects);

+

+        /**

+         * Sets P flag in ERO object header and returns its builder.

+         *

+         * @param value boolean value to set P flag

+         * @return Builder by setting P flag

+         */

+        Builder setPFlag(boolean value);

+

+        /**

+         * Sets I flag in ERO object header and returns its builder.

+         *

+         * @param value boolean value to set I flag

+         * @return Builder by setting I flag

+         */

+        Builder setIFlag(boolean value);

+    }

+}
\ No newline at end of file
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepError.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepError.java
new file mode 100755
index 0000000..acb3363
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepError.java
@@ -0,0 +1,141 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+import java.util.LinkedList;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+

+/**

+ * Abstraction of an entity which provides PCEP error for PCEP error message.

+ */

+public interface PcepError {

+

+    /**

+     * Returns the PcepRPObject List.

+     *

+     * @return list of type PcepRPObject

+     */

+    LinkedList<PcepRPObject> getRPObjList();

+

+    /**

+     * Sets the RP Objects lists.

+     *

+     * @param llRPObjList list of type PcepRPObject

+     */

+    void setRPObjList(LinkedList<PcepRPObject> llRPObjList);

+

+    /**

+     * Returns the PcepTEObject List.

+     *

+     * @return list of type PcepTEObject

+     */

+    LinkedList<PcepTEObject> getTEObjList();

+

+    /**

+     * Sets the TE Objects lists.

+     *

+     * @param llTEObjList list of type PcepTEObject

+     */

+    void setTEObjList(LinkedList<PcepTEObject> llTEObjList);

+

+    /**

+     * Returns the PcepErrorObject.

+     *

+     * @return list of type PcepErrorObject

+     */

+    LinkedList<PcepErrorObject> getErrorObjList();

+

+    /**

+     * Sets the Error Objects lists.

+     *

+     * @param llErrorObjList list of type PcepErrorObject

+     */

+    public void setErrorObjList(LinkedList<PcepErrorObject> llErrorObjList);

+

+    /**

+     * Writes the byte stream of PCEP error to the channel buffer.

+     *

+     * @param bb of type channel buffer

+     * @return object length index

+     * @throws PcepParseException while writing Error part into ChannelBuffer

+     */

+    public int write(ChannelBuffer bb) throws PcepParseException;

+

+    /**

+     * Prints the attributes of PCEP Error.

+     */

+    public void print();

+

+    /**

+     * Builder interface with get and set functions to build PcepError.

+     */

+    public interface Builder {

+

+        /**

+         * Builds PcepError Object.

+         *

+         * @return PcepError Object

+         */

+        PcepError build();

+

+        /**

+         * Returns the PcepRPObject.

+         *

+         * @return list of type PcepRPObject

+         */

+        LinkedList<PcepRPObject> getRPObjList();

+

+        /**

+         * Sets RP Object lists and returns its builder.

+         *

+         * @param llRPObjList list of type PcepRpObject

+         * @return builder by setting Linked list of RP Object

+         */

+        Builder setRPObjList(LinkedList<PcepRPObject> llRPObjList);

+

+        /**

+         * Returns the PcepTEObject.

+         *

+         * @return llTEObjList of type PcepTEObject

+         */

+        LinkedList<PcepTEObject> getTEObjList();

+

+        /**

+         * Sets TE Object lists and returns its builder.

+         *

+         * @param llTEObjList list of type PcepTEObject

+         * @return builder by setting list of type PcepTEObject

+         */

+        Builder setTEObjList(LinkedList<PcepTEObject> llTEObjList);

+

+        /**

+         * Returns the PcepErrorObject.

+         *

+         * @return list of type PcepErrorObject

+         */

+        LinkedList<PcepErrorObject> getErrorObjList();

+

+        /**

+         * Sets Error Object lists and returns its builder.

+         *

+         * @param llErrorObjList list of type PcepErrorObject

+         * @return builder by setting list of type PcepErrorObject

+         */

+        Builder setErrorObjList(LinkedList<PcepErrorObject> llErrorObjList);

+    }

+}

diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepErrorInfo.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepErrorInfo.java
new file mode 100755
index 0000000..6519631
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepErrorInfo.java
@@ -0,0 +1,98 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+import java.util.LinkedList;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+

+/**

+ * Abstraction of an entity which provides PCEP Error Info.

+ * Reference :PCEP Extension for Transporting TE Data draft-dhodylee-pce-pcep-te-data-extn-02.

+ */

+public interface PcepErrorInfo {

+

+    /**

+     * Returns whether error info list is present or not.

+     *

+     * @return true if error info present, false otherwise

+     */

+    public boolean isErrorInfoPresent();

+

+    /**

+     * Reads from channel buffer for TE and RP objects.

+     *

+     * @param bb of channel buffer

+     * @throws PcepParseException while parsing Error info part.

+     */

+    public void read(ChannelBuffer bb) throws PcepParseException;

+

+    /**

+     * Writes byte stream of PCEP error info to channel buffer.

+     *

+     * @param bb of type channel buffer

+     * @throws PcepParseException while writing Error info part into Channel Buffer.

+     */

+    public void write(ChannelBuffer bb) throws PcepParseException;

+

+    /**

+     * Prints the attributes of error info list.

+     */

+    public void print();

+

+    /**

+     * Returns Error Value in PCEP-ERROR Object.

+     *

+     * @return list of Error Value in PCEP-ERROR Object

+     */

+    public LinkedList<Integer> getErrorValue();

+

+    /**

+     * Returns Error Type in PCEP-ERROR Object.

+     *

+     * @return list of Error Type in PCEP-ERROR Object

+     */

+    public LinkedList<Integer> getErrorType();

+

+    /**

+     * Builder interface with get and set functions to build ErrorInfo.

+     */

+    public interface Builder {

+

+        /**

+         * Builds ErrorInfo Object.

+         *

+         * @return ErrorInfo Object.

+         */

+        PcepErrorInfo build();

+

+        /**

+         * Returns list of PcepError.

+         *

+         * @return list of PcepError

+         */

+        LinkedList<PcepError> getPcepErrorList();

+

+        /**

+         * Sets PcepError lists and returns its builder.

+         *

+         * @param llPcepErrorList list of PcepError

+         * @return builder by setting list of PcepError.

+         */

+        Builder setPcepErrorList(LinkedList<PcepError> llPcepErrorList);

+    }

+}

diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepErrorMsg.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepErrorMsg.java
new file mode 100755
index 0000000..9987d67
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepErrorMsg.java
@@ -0,0 +1,92 @@
+package org.onosproject.pcepio.protocol;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.types.ErrorObjListWithOpen;

+

+/**

+ * Abstraction of an entity providing PCEP Error Message.

+ */

+public interface PcepErrorMsg extends PcepMessage {

+

+    @Override

+    PcepVersion getVersion();

+

+    @Override

+    PcepType getType();

+

+    /**

+     * Returns Object of ErrorObjListWithOpen.

+     *

+     * @return Object of ErrorObjListWithOpen

+     */

+    public ErrorObjListWithOpen getErrorObjListWithOpen();

+

+    /**

+     * Sets errObjListWithOpen object.

+     *

+     * @param errObjListWithOpen error object List with open object

+     */

+    public void setErrorObjListWithOpen(ErrorObjListWithOpen errObjListWithOpen);

+

+    /**

+     * Returns Object of PcepErrorInfo.

+     *

+     * @return Object of PcepErrorInfo

+     */

+    public PcepErrorInfo getPcepErrorInfo();

+

+    /**

+     * Sets errInfo Object.

+     *

+     * @param errInfo error information

+     */

+    public void setPcepErrorInfo(PcepErrorInfo errInfo);

+

+    @Override

+    void writeTo(ChannelBuffer channelBuffer);

+

+    /**

+     * Builder interface with get and set functions to build PCEP Error message.

+     */

+    public interface Builder extends PcepMessage.Builder {

+

+        @Override

+        PcepErrorMsg build();

+

+        @Override

+        PcepVersion getVersion();

+

+        @Override

+        PcepType getType();

+

+        /**

+         * Returns Object of ErrorObjListWithOpen.

+         *

+         * @return Object of ErrorObjListWithOpen

+         */

+        public ErrorObjListWithOpen getErrorObjListWithOpen();

+

+        /**

+         * Sets errObjListWithOpen object.

+         *

+         * @param errObjListWithOpen error object with open object

+         * @return builder by setting Object of ErrorObjListWithOpen

+         */

+        public Builder setErrorObjListWithOpen(ErrorObjListWithOpen errObjListWithOpen);

+

+        /**

+         * Returns Object of PcepErrorInfo.

+         *

+         * @return Object of PcepErrorInfo

+         */

+        public PcepErrorInfo getPcepErrorInfo();

+

+        /**

+         * Sets errInfo Object.

+         *

+         * @param errInfo error information

+         * @return builder by getting Object of PcepErrorInfo

+         */

+        public Builder setPcepErrorInfo(PcepErrorInfo errInfo);

+    }

+}

diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepErrorObject.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepErrorObject.java
new file mode 100755
index 0000000..72fb0ce
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepErrorObject.java
@@ -0,0 +1,159 @@
+package org.onosproject.pcepio.protocol;

+

+import java.util.LinkedList;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+import org.onosproject.pcepio.types.PcepObjectHeader;

+import org.onosproject.pcepio.types.PcepValueType;

+

+/**

+ * Abstraction of an entity providing PCEP Error Object.

+ */

+public interface PcepErrorObject {

+

+    /**

+     * Returns Error Type in Error Object.

+     *

+     * @return Error Type in Error Object

+     */

+    int getErrorType();

+

+    /**

+     * Sets Error Type in Error Object.

+     *

+     * @param value Error Type

+     */

+    void setErrorType(byte value);

+

+    /**

+     * Returns Error Value in Error Object.

+     *

+     * @return Error Value

+     */

+    byte getErrorValue();

+

+    /**

+     * Sets Error Value in Error Object.

+     *

+     * @param value Error Value

+     */

+    void setErrorValue(byte value);

+

+    /**

+     * Returns Optional Tlvs in Error Object.

+     *

+     * @return list of Optional Tlvs in Error Object

+     */

+    LinkedList<PcepValueType> getOptionalTlv();

+

+    /**

+     * Sets Optional Tlvs in Error Object.

+     *

+     * @param llOptionalTlv list of Optional Tlvs

+     */

+    void setOptionalTlv(LinkedList<PcepValueType> llOptionalTlv);

+

+    /**

+     * Prints attributes of Error object.

+     */

+    void print();

+

+    /**

+     * Writes the Error Object into channel buffer.

+     *

+     * @param bb channel buffer

+     * @return Returns the writerIndex of this buffer

+     * @throws PcepParseException while writing Error Object into ChannelBuffer

+     */

+    int write(ChannelBuffer bb) throws PcepParseException;

+

+    /**

+     * Builder interface with get and set functions to build Error object.

+     */

+    public interface Builder {

+

+        /**

+         * Builds Error Object.

+         *

+         * @return Error Object.

+         */

+        PcepErrorObject build();

+

+        /**

+         * Returns Error Object header.

+         *

+         * @return Error Object header

+         */

+        PcepObjectHeader getErrorObjHeader();

+

+        /**

+         * Sets Error Object header and returns its Builder.

+         *

+         * @param obj Error Object header

+         * @return Builder by setting Error Object header

+         */

+        Builder setErrorObjHeader(PcepObjectHeader obj);

+

+        /**

+         * Returns Error Type in Error Object.

+         *

+         * @return Error Type in Error Object

+         */

+        int getErrorType();

+

+        /**

+         * Sets Error Type and returns its builder.

+         *

+         * @param value of Error-Type field

+         * @return builder by setting Error Type field.

+         */

+        Builder setErrorType(byte value);

+

+        /**

+         * Returns Error Value in Error Object.

+         *

+         * @return Error Value

+         */

+        byte getErrorValue();

+

+        /**

+         * Sets Error Value and returns its builder.

+         *

+         * @param value of Error-Value field

+         * @return Builder by setting Error Value field.

+         */

+        Builder setErrorValue(byte value);

+

+        /**

+         * Returns list of Optional Tlvs of Error Object.

+         *

+         * @return list of Optional Tlvs of Error Object

+         */

+        LinkedList<PcepValueType> getOptionalTlv();

+

+        /**

+         * Sets Optional Tlvs of Error Object and returns its Builder.

+         *

+         * @param llOptionalTlv Optional Tlvs of Error Object

+         * @return Builder by setting Optional Tlvs.

+         */

+        Builder setOptionalTlv(LinkedList<PcepValueType> llOptionalTlv);

+

+        /**

+         * Sets P flag in Error object header and returns its builder.

+         *

+         * @param value boolean value to set P flag

+         * @return Builder by setting P flag

+         */

+        Builder setPFlag(boolean value);

+

+        /**

+         * Sets I flag in Error object header and returns its builder.

+         *

+         * @param value boolean value to set I flag

+         * @return Builder by setting I flag

+         */

+        Builder setIFlag(boolean value);

+    }

+}

diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFactories.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFactories.java
new file mode 100755
index 0000000..f1eb3fe
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFactories.java
@@ -0,0 +1,96 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+import org.slf4j.Logger;

+import org.slf4j.LoggerFactory;

+

+public final class PcepFactories {

+

+    protected static final Logger log = LoggerFactory.getLogger(PcepFactories.class);

+

+    private static final GenericReader GENERIC_READER = new GenericReader();

+

+    public static final byte SHIFT_FLAG = 5;

+

+    private PcepFactories() {

+    }

+

+    /*

+     * Returns the instance of PCEP Version.

+     *

+     * @param version

+     * @return PCEP version

+     */

+    public static PcepFactory getFactory(PcepVersion version) {

+        switch (version) {

+        case PCEP_1:

+            // TODO :  to get the pcep version 1 factory

+        default:

+            throw new IllegalArgumentException("[PcepFactory:]Unknown version: " + version);

+        }

+    }

+

+    private static class GenericReader implements PcepMessageReader<PcepMessage> {

+

+        @Override

+        public PcepMessage readFrom(ChannelBuffer bb) throws PcepParseException {

+

+            if (!bb.readable()) {

+                log.debug("Empty message received");

+                throw new PcepParseException("Empty message received");

+            }

+

+            /*

+             * 0                   1                   2                   3

+             * 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1

+             * +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

+             * | Ver |  Flags  |                                               |

+             * +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

+             *

+             * Currently Version 1 is supported

+             * Currently no flags are used, it is all ignored

+             */

+

+            byte packetVersion = bb.getByte(bb.readerIndex());

+            packetVersion = (byte) (packetVersion >> SHIFT_FLAG);

+            PcepFactory factory;

+

+            switch (packetVersion) {

+

+            case 1:

+                // TODO : get the factory for version 1

+                break;

+            default:

+                throw new IllegalArgumentException("Unknown Packet version: " + packetVersion);

+            }

+            // TODO : Read the PCEP message from the factory

+            return null;

+        }

+    }

+

+    /*

+     * Returns GENERIC_READER.

+     *

+     * @return GENERIC_READER

+     */

+    public static PcepMessageReader<PcepMessage> getGenericReader() {

+        return GENERIC_READER;

+    }

+}

diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFactory.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFactory.java
new file mode 100755
index 0000000..e9eb125
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFactory.java
@@ -0,0 +1,241 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+/**
+ * Abstraction of an Message factory providing Builder functions to PCEP Messages and Objects.
+ *
+ */
+public interface PcepFactory {
+
+    /**
+     * To get Builder Object for Open Message.
+     *
+     * @return Builder Object for Open Message
+     */
+    PcepOpenMsg.Builder buildOpenMsg();
+
+    /**
+     * To get Builder Object for Open Object.
+     *
+     * @return Builder Object for Open Object
+     */
+    PcepOpenObject.Builder buildOpenObject();
+
+    /**
+     * To get Builder Object for Keepalive Message.
+     *
+     * @return Builder Object for Keepalive Message
+     */
+    PcepKeepaliveMsg.Builder buildKeepaliveMsg();
+
+    /**
+     * To get Builder Object for Close Message.
+     *
+     * @return Builder Object for Close Message
+     */
+    PcepCloseMsg.Builder buildCloseMsg();
+
+    /**
+     * To get Builder Object for Report Message.
+     *
+     * @return Builder Object for Report Message
+     */
+    PcepReportMsg.Builder buildReportMsg();
+
+    /**
+     * To get Builder Object for Update Message.
+     *
+     * @return Builder Object for Update Message
+     */
+    PcepUpdateMsg.Builder buildUpdateMsg();
+
+    /**
+     * To get Builder Object for Initiate Message.
+     *
+     * @return Builder Object for Initiate Message
+     */
+    PcepInitiateMsg.Builder buildPcepInitiateMsg();
+
+    /**
+     * To get Builder Object for LSP Object.
+     *
+     * @return Builder Object for LSP Object
+     */
+    PcepLspObject.Builder buildLspObject();
+
+    /**
+     * To get Builder Object for SRP Object.
+     *
+     * @return Builder Object for SRP Object
+     */
+    PcepSrpObject.Builder buildSrpObject();
+
+    /**
+     * To get Builder Object for EndPoints Object.
+     *
+     * @return Builder Object for EndPoints Object
+     */
+    PcepEndPointsObject.Builder buildEndPointsObject();
+
+    /**
+     * To get Builder Object for ERO Object.
+     *
+     * @return Builder Object for ERO Object
+     */
+    PcepEroObject.Builder buildEroObject();
+
+    /**
+     * To get Builder Object for RRO Object.
+     *
+     * @return Builder Object for RRO Object
+     */
+    PcepRroObject.Builder buildRroObject();
+
+    /**
+     * To get Builder Object for LSPA Object.
+     *
+     * @return Builder Object for LSPA Object
+     */
+    PcepLspaObject.Builder buildLspaObject();
+
+    /**
+     * To get Builder Object for IRO Object.
+     *
+     * @return Builder Object for IRO Object
+     */
+    PcepIroObject.Builder buildIroObject();
+
+    /**
+     * To get Builder Object for METRIC Object.
+     *
+     * @return Builder Object for METRIC Object
+     */
+    PcepMetricObject.Builder buildMetricObject();
+
+    /**
+     * To get Builder Object for Bandwidth Object.
+     *
+     * @return Builder Object for Bandwidth Object
+     */
+    PcepBandwidthObject.Builder buildBandwidthObject();
+
+    /**
+     * Returns PCEP Message Reader.
+     *
+     * @return PCEP Message Reader
+     */
+    PcepMessageReader<PcepMessage> getReader();
+
+    /**
+     * Returns PCEP version.
+     *
+     * @return PCEP version
+     */
+    PcepVersion getVersion();
+
+    /**
+     * Returns PcepStateReport.
+     *
+     * @return PcepStateReport
+     */
+    PcepStateReport.Builder buildPcepStateReport();
+
+    /**
+     * Returns PcepUpdateRequest.
+     *
+     * @return PcepUpdateRequest
+     */
+    PcepUpdateRequest.Builder buildPcepUpdateRequest();
+
+    /**
+     * Returns PcInitiatedLspRequest.
+     *
+     * @return PcInitiatedLspRequest
+     */
+    PcInitiatedLspRequest.Builder buildPcInitiatedLspRequest();
+
+    /**
+     * Returns PcepMsgPath.
+     *
+     * @return PcepMsgPath
+     */
+    PcepMsgPath.Builder buildPcepMsgPath();
+
+    /**
+     * Return PcepAttribute list.
+     *
+     * @return PcepAttribute
+     */
+    PcepAttribute.Builder buildPcepAttribute();
+
+    /**
+     * To get Builder Object for LabelUpdate message.
+     *
+     * @return Builder Object for LabelUpdate message
+     */
+    PcepLabelUpdateMsg.Builder buildPcepLabelUpdateMsg();
+
+    /**
+     * To get Builder Object for PcepLabelUpdate Object.
+     *
+     * @return Builder Object for PcepLabelUpdate Object
+     */
+    PcepLabelUpdate.Builder buildPcepLabelUpdateObject();
+
+    /**
+     * To get Builder Object for PcepLabel Object.
+     *
+     * @return Builder Object for PcepLabel Object
+     */
+    PcepLabelObject.Builder buildLabelObject();
+
+    /**
+     * To get Builder Object for Error Message.
+     *
+     * @return Builder Object for Error Message
+     */
+    PcepErrorMsg.Builder buildPcepErrorMsg();
+
+    /**
+     * To get Builder Object for Error Object.
+     *
+     * @return Builder Object for Error Object
+     */
+    PcepErrorObject.Builder buildPcepErrorObject();
+
+    /**
+     * To get Builder Object for FecIpv4Adjacency.
+     *
+     * @return Builder Object for FecIpv4Adjacency
+     */
+    PcepFecObjectIPv4Adjacency.Builder buildFecIpv4Adjacency();
+
+    /**
+     * To get Builder Object for ErrorInfo.
+     *
+     * @return Builder Object for ErrorInfo
+     */
+    PcepErrorInfo.Builder buildPcepErrorInfo();
+
+    /**
+     * To get Builder Object for PcepError.
+     *
+     * @return Builder Object for PcepError
+     */
+    PcepError.Builder buildPcepError();
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFecObject.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFecObject.java
new file mode 100755
index 0000000..e356470
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFecObject.java
@@ -0,0 +1,54 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+
+/**
+ * Abstraction of an entity providing PCEP FEC Object.
+ */
+public interface PcepFecObject {
+
+    /**
+     * Returns PCEP Version of FEC Object.
+     *
+     * @return PCEP Version of FEC Object
+     */
+    PcepVersion getVersion();
+
+    /**
+     * Returns FEC Object type.
+     *
+     * @return FEC Object type
+     */
+    int getType();
+
+    /**
+     * Writes the FEC into channel buffer.
+     *
+     * @param bb channel buffer
+     * @return Returns the writerIndex of this buffer
+     * @throws PcepParseException while writing FEC Object into Channel Buffer.
+     */
+    int write(ChannelBuffer bb) throws PcepParseException;
+
+    /**
+     * Prints attributes of FEC object.
+     */
+    void print();
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFecObjectIPv4.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFecObjectIPv4.java
new file mode 100755
index 0000000..60c6b75
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFecObjectIPv4.java
@@ -0,0 +1,107 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+import org.onosproject.pcepio.types.PcepObjectHeader;
+
+/**
+ * Abstraction of an entity providing PCEP FEC Object of Type 1 IPv4 Node ID.
+ */
+public interface PcepFecObjectIPv4 extends PcepFecObject {
+
+    /**
+     * Returns NodeID of FEC Object.
+     *
+     * @return NodeID of FEC Object
+     */
+    int getNodeID();
+
+    /**
+     * Sets NodeID with specified value.
+     *
+     * @param value node id
+     */
+    void setNodeID(int value);
+
+    @Override
+    void print();
+
+    @Override
+    int write(ChannelBuffer bb) throws PcepParseException;
+
+    /**
+     * Builder interface with get and set functions to build FEC object.
+     */
+    public interface Builder {
+
+        /**
+         * Builds FEC Object IPv4.
+         *
+         * @return FEC Object IPv4
+         * @throws PcepParseException while creating FEC IPv4 Object.
+         */
+        PcepFecObjectIPv4 build() throws PcepParseException;
+
+        /**
+         * Returns FEC Object IPv4 header.
+         *
+         * @return FEC Object IPv4 header
+         */
+        PcepObjectHeader getFecIpv4ObjHeader();
+
+        /**
+         * Sets FEC Object IPv4 header and returns its builder.
+         *
+         * @param obj FEC Object IPv4 header
+         * @return Builder by setting FEC Object IPv4 header
+         */
+        Builder setFecIpv4ObjHeader(PcepObjectHeader obj);
+
+        /**
+         * Returns NodeID of FEC Object.
+         *
+         * @return NodeID of FEC Object
+         */
+        int getNodeID();
+
+        /**
+         * Sets NodeID and returns its builder.
+         *
+         * @param value node id
+         * @return builder by setting NodeID
+         */
+        Builder setNodeID(int value);
+
+        /**
+         * Sets P flag in FEC object header and returns its builder.
+         *
+         * @param value boolean value to set P flag
+         * @return Builder by setting P flag
+         */
+        Builder setPFlag(boolean value);
+
+        /**
+         * Sets I flag in FEC object header and returns its builder.
+         *
+         * @param value boolean value to set I flag
+         * @return Builder by setting I flag
+         */
+        Builder setIFlag(boolean value);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFecObjectIPv4Adjacency.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFecObjectIPv4Adjacency.java
new file mode 100755
index 0000000..675b6fb
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFecObjectIPv4Adjacency.java
@@ -0,0 +1,136 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+import org.onosproject.pcepio.types.PcepObjectHeader;
+
+/**
+ * Abstraction of an entity providing FEC Object of Type 3 IPv4 Adjacency.
+ */
+public interface PcepFecObjectIPv4Adjacency extends PcepFecObject {
+
+    /**
+     * Returns Local IPv4Address of FEC Object.
+     *
+     * @return Local IPv4Address of FEC Object
+     */
+    int getLocalIPv4Address();
+
+    /**
+     * Sets Local IPv4Address with specified value.
+     *
+     * @param value Local IPv4Address
+     */
+    void seLocalIPv4Address(int value);
+
+    /**
+     * Returns Remote IPv4Address of FEC Object.
+     *
+     * @return Remote IPv4Address of FEC Object
+     */
+    int getRemoteIPv4Address();
+
+    /**
+     * Sets Remote IPv4Address with specified value.
+     *
+     * @param value Remote IPv4Address
+     */
+    void seRemoteIPv4Address(int value);
+
+    @Override
+    void print();
+
+    @Override
+    int write(ChannelBuffer bb) throws PcepParseException;
+
+    /**
+     * Builder interface with get and set functions to build FEC object.
+     */
+    public interface Builder {
+
+        /**
+         * Builds FEC Object IPv4 Adjacency.
+         *
+         * @return FEC Object IPv4 Adjacency
+         * @throws PcepParseException while building FEC IPv4 Adjacency object.
+         */
+        PcepFecObjectIPv4Adjacency build() throws PcepParseException;
+
+        /**
+         * Returns FEC Object IPv4 Adjacency header.
+         *
+         * @return FEC Object IPv4 Adjacency header
+         */
+        PcepObjectHeader getFecIpv4AdjacencyObjHeader();
+
+        /**
+         * Sets FEC Object IPv4 Adjacency header and returns its builder.
+         *
+         * @param obj FEC Object IPv4 Adjacency header
+         * @return Builder by setting FEC Object IPv4 header
+         */
+        Builder setFecIpv4AdjacencyObjHeader(PcepObjectHeader obj);
+
+        /**
+         * Returns Local IPv4Address of FEC Object.
+         *
+         * @return Local IPv4Address of FEC Object
+         */
+        int getLocalIPv4Address();
+
+        /**
+         * Sets Local IPv4Address and returns its builder.
+         *
+         * @param value Local IPv4Address
+         * @return Builder by setting Local IPv4Address
+         */
+        Builder seLocalIPv4Address(int value);
+
+        /**
+         * Sets Remote IPv4Address with specified value.
+         *
+         * @return Remote IPv4 Address
+         */
+        int getRemoteIPv4Address();
+
+        /**
+         * Sets Remote IPv4Address and returns its builder.
+         *
+         * @param value Remote IPv4Address
+         * @return Builder by setting Remote IPv4Address
+         */
+        Builder seRemoteIPv4Address(int value);
+
+        /**
+         * Sets P flag in FEC object header and returns its builder.
+         *
+         * @param value boolean value to set P flag
+         * @return Builder by setting P flag
+         */
+        Builder setPFlag(boolean value);
+
+        /**
+         * Sets I flag in FEC object header and returns its builder.
+         *
+         * @param value boolean value to set I flag
+         * @return Builder by setting I flag
+         */
+        Builder setIFlag(boolean value);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFecObjectIPv4UnnumberedAdjacency.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFecObjectIPv4UnnumberedAdjacency.java
new file mode 100755
index 0000000..08a7b42
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFecObjectIPv4UnnumberedAdjacency.java
@@ -0,0 +1,194 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+import org.onosproject.pcepio.types.PcepObjectHeader;
+
+/**
+ * Abstraction of an entity providing PCEP FEC Object of Type is 5 Unnumbered Adjacency with IPv4 NodeIDs.
+ */
+public interface PcepFecObjectIPv4UnnumberedAdjacency extends PcepFecObject {
+
+    /**
+     * Returns Local NodeID of FEC Object.
+     *
+     * @return Local NodeID of FEC Object
+     */
+    int getLocalNodeID();
+
+    /**
+     * Sets Local NodeID with specified value.
+     *
+     * @param value Local NodeID
+     */
+    void setLocalNodeID(int value);
+
+    /**
+     * Returns Local InterfaceID of FEC Object.
+     *
+     * @return Local InterfaceID of FEC Object
+     */
+    int getLocalInterfaceID();
+
+    /**
+     * Sets Local InterfaceID with specified value.
+     *
+     * @param value Local InterfaceID
+     */
+    void setLocalInterfaceID(int value);
+
+    /**
+     * Returns Remote NodeID of FEC Object.
+     *
+     * @return Remote NodeID of FEC Object
+     */
+    int getRemoteNodeID();
+
+    /**
+     * Sets Remote NodeID with specified value.
+     *
+     * @param value Remote NodeID
+     */
+    void setRemoteNodeID(int value);
+
+    /**
+     * Returns Remote InterfaceID of FEC Object.
+     *
+     * @return Remote InterfaceID of FEC Object
+     */
+    int getRemoteInterfaceID();
+
+    /**
+     * Sets Remote InterfaceID with specified value.
+     *
+     * @param value Remote InterfaceID
+     */
+    void setRemoteInterfaceID(int value);
+
+    @Override
+    void print();
+
+    @Override
+    int write(ChannelBuffer bb) throws PcepParseException;
+
+    /**
+     * Builder interface with get and set functions to build bandwidth object.
+     */
+    public interface Builder {
+
+        /**
+         * Builds FEC Unnumbered Adjacency with IPv4 Object.
+         *
+         * @return FEC Unnumbered Adjacency with IPv4 Object
+         * @throws PcepParseException when building FEC IPv4 Unnumbered Adjacency object.
+         */
+        PcepFecObjectIPv4UnnumberedAdjacency build() throws PcepParseException;
+
+        /**
+         * Returns FEC Unnumbered Adjacency with IPv4 header.
+         *
+         * @return FEC Unnumbered Adjacency with IPv4 header
+         */
+        PcepObjectHeader getFecIpv4UnnumberedAdjacencyObjHeader();
+
+        /**
+         * Sets FEC Unnumbered Adjacency with IPv4 header and returns its builder.
+         *
+         * @param obj FEC Unnumbered Adjacency with IPv4 header
+         * @return Builder by setting FEC Unnumbered Adjacency with IPv4 header
+         */
+        Builder setFecIpv4UnnumberedAdjacencyObjHeader(PcepObjectHeader obj);
+
+        /**
+         * Returns Local NodeID of FEC Object.
+         *
+         * @return Local NodeID of FEC Object
+         */
+        int getLocalNodeID();
+
+        /**
+         * Sets Local NodeID and returns its builder.
+         *
+         * @param value Local NodeID
+         * @return Builder by setting Local NodeID
+         */
+        Builder setLocalNodeID(int value);
+
+        /**
+         * Returns Local InterfaceID of FEC Object.
+         *
+         * @return Local InterfaceID of FEC Object
+         */
+        int getLocalInterfaceID();
+
+        /**
+         * Sets Local InterfaceID and returns its builder.
+         *
+         * @param value Local InterfaceID
+         * @return Builder by setting Local InterfaceID
+         */
+        Builder setLocalInterfaceID(int value);
+
+        /**
+         * Returns Remote NodeID of FEC Object.
+         *
+         * @return Remote NodeID of FEC Object
+         */
+        int getRemoteNodeID();
+
+        /**
+         * Sets Remote NodeID and returns its builder.
+         *
+         * @param value Remote NodeID
+         * @return Builder by setting Remote NodeID
+         */
+        Builder setRemoteNodeID(int value);
+
+        /**
+         * Returns Remote InterfaceID of FEC Object.
+         *
+         * @return Remote InterfaceID of FEC Object
+         */
+        int getRemoteInterfaceID();
+
+        /**
+         * Sets Remote InterfaceID and returns its builder.
+         *
+         * @param value Remote InterfaceID
+         * @return Builder by setting Remote InterfaceID
+         */
+        Builder setRemoteInterfaceID(int value);
+
+        /**
+         * Sets P flag in FEC object header and returns its builder.
+         *
+         * @param value boolean value to set P flag
+         * @return Builder by setting P flag
+         */
+        Builder setPFlag(boolean value);
+
+        /**
+         * Sets I flag in FEC object header and returns its builder.
+         *
+         * @param value boolean value to set I flag
+         * @return Builder by setting I flag
+         */
+        Builder setIFlag(boolean value);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFecObjectIPv6.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFecObjectIPv6.java
new file mode 100755
index 0000000..b8bfe2f
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFecObjectIPv6.java
@@ -0,0 +1,107 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+import org.onosproject.pcepio.types.PcepObjectHeader;
+
+/**
+ * Abstraction of an entity providing FEC Object of Type is 2 IPv6 Node ID.
+ */
+public interface PcepFecObjectIPv6 extends PcepFecObject {
+
+    /**
+     * Returns NodeID of FEC Object.
+     *
+     * @return NodeID of FEC Object
+     */
+    byte[] getNodeID();
+
+    /**
+     * Sets NodeID with specified value.
+     *
+     * @param value node id
+     */
+    void setNodeID(byte[] value);
+
+    @Override
+    void print();
+
+    @Override
+    int write(ChannelBuffer bb) throws PcepParseException;
+
+    /**
+     * Builder interface with get and set functions to build FEC object.
+     */
+    public interface Builder {
+
+        /**
+         * Builds FEC Object IPv6.
+         *
+         * @return FEC Object IPv6
+         * @throws PcepParseException while building FEC IPv6 Object.
+         */
+        PcepFecObjectIPv6 build() throws PcepParseException;
+
+        /**
+         * Returns FEC Object IPv6 header.
+         *
+         * @return FEC Object IPv6 header
+         */
+        PcepObjectHeader getFecIpv6ObjHeader();
+
+        /**
+         * Sets FEC Object IPv6 header and returns its builder.
+         *
+         * @param obj FEC Object IPv6 header
+         * @return Builder by setting FEC Object IPv6 header
+         */
+        Builder setFecIpv6ObjHeader(PcepObjectHeader obj);
+
+        /**
+         * Returns NodeID of FEC Object.
+         *
+         * @return NodeID of FEC Object
+         */
+        byte[] getNodeID();
+
+        /**
+         * Sets NodeID and returns its builder.
+         *
+         * @param value node id
+         * @return Builder by setting NodeID
+         */
+        Builder setNodeID(byte[] value);
+
+        /**
+         * Sets P flag in FEC object header and returns its builder.
+         *
+         * @param value boolean value to set P flag
+         * @return Builder by setting P flag
+         */
+        Builder setPFlag(boolean value);
+
+        /**
+         * Sets I flag in FEC object header and returns its builder.
+         *
+         * @param value boolean value to set I flag
+         * @return Builder by setting I flag
+         */
+        Builder setIFlag(boolean value);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFecObjectIPv6Adjacency.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFecObjectIPv6Adjacency.java
new file mode 100755
index 0000000..3fc4bb5
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepFecObjectIPv6Adjacency.java
@@ -0,0 +1,136 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+import org.onosproject.pcepio.types.PcepObjectHeader;
+
+/**
+ * Abstraction of an entity providing FEC Object of Type is 4 IPv6 Adjacency.
+ */
+public interface PcepFecObjectIPv6Adjacency extends PcepFecObject {
+
+    /**
+     * Returns Local IPv6Address of FEC Object.
+     *
+     * @return Local IPv6Address of FEC Object
+     */
+    byte[] getLocalIPv6Address();
+
+    /**
+     * Sets Local IPv6Address with specified value.
+     *
+     * @param value Local IPv6Address
+     */
+    void seLocalIPv6Address(byte[] value);
+
+    /**
+     * Returns Remote IPv6Address of FEC Object.
+     *
+     * @return Remote IPv6Address of FEC Object
+     */
+    byte[] getRemoteIPv6Address();
+
+    /**
+     * Sets Remote IPv6Address with specified value.
+     *
+     * @param value Remote IPv6Address
+     */
+    void seRemoteIPv6Address(byte[] value);
+
+    @Override
+    void print();
+
+    @Override
+    int write(ChannelBuffer bb) throws PcepParseException;
+
+    /**
+     * Builder interface with get and set functions to build FEC object.
+     */
+    public interface Builder {
+
+        /**
+         * Builds FEC Object IPv6 Adjacency.
+         *
+         * @return FEC Object IPv6 Adjacency
+         * @throws PcepParseException while building FEC IPv6 Adjacency object.
+         */
+        PcepFecObjectIPv6Adjacency build() throws PcepParseException;
+
+        /**
+         * Returns FEC Object IPv6 Adjacency header.
+         *
+         * @return FEC Object IPv6 Adjacency header
+         */
+        PcepObjectHeader getFecIpv6AdjacencyObjHeader();
+
+        /**
+         * Sets FEC Object IPv6 Adjacency header and returns its builder.
+         *
+         * @param obj FEC Object IPv6 Adjacency header
+         * @return Builder by setting FEC Object IPv6 Adjacency header
+         */
+        Builder setFecIpv6AdjacencyObjHeader(PcepObjectHeader obj);
+
+        /**
+         * Returns Local IPv6Address of FEC Object.
+         *
+         * @return Local IPv6Address of FEC Object
+         */
+        byte[] getLocalIPv6Address();
+
+        /**
+         * Sets Local IPv6Address and returns its builder.
+         *
+         * @param value Local IPv6Address
+         * @return Builder by setting Local IPv6Address
+         */
+        Builder setLocalIPv6Address(byte[] value);
+
+        /**
+         * Returns Remote IPv6Address of FEC Object.
+         *
+         * @return Remote IPv6Address of FEC Object
+         */
+        byte[] getRemoteIPv6Address();
+
+        /**
+         * Sets Remote IPv6Address and returns its builder.
+         *
+         * @param value Remote IPv6Address
+         * @return Builder by setting Remote IPv6Address
+         */
+        Builder setRemoteIPv6Address(byte[] value);
+
+        /**
+         * Sets P flag in FEC object header and returns its builder.
+         *
+         * @param value boolean value to set P flag
+         * @return Builder by setting P flag
+         */
+        Builder setPFlag(boolean value);
+
+        /**
+         * Sets I flag in FEC object header and returns its builder.
+         *
+         * @param value boolean value to set I flag
+         * @return Builder by setting I flag
+         */
+        Builder setIFlag(boolean value);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepInitiateMsg.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepInitiateMsg.java
new file mode 100755
index 0000000..0d23948
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepInitiateMsg.java
@@ -0,0 +1,81 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+import java.util.LinkedList;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+

+/**

+ * Abstraction of an entity providing PCEP Initiate Message.

+ */

+public interface PcepInitiateMsg extends PcepObject, PcepMessage {

+

+    @Override

+    PcepVersion getVersion();

+

+    @Override

+    PcepType getType();

+

+    /**

+     * Returns list of PcInitiatedLspRequestList.

+     *

+     * @return list of PcInitiatedLspRequestList

+     */

+    LinkedList<PcInitiatedLspRequest> getPcInitiatedLspRequestList();

+

+    /**

+     * Sets list of PcInitiatedLspRequestList.

+     *

+     * @param llPcInitiatedLspRequestList list of PcInitiatedLspRequestList

+     */

+    void setPcInitiatedLspRequestList(LinkedList<PcInitiatedLspRequest> llPcInitiatedLspRequestList);

+

+    @Override

+    void writeTo(ChannelBuffer channelBuffer) throws PcepParseException;

+

+    /**

+     * Builder interface with get and set functions to build Initiate message.

+     */

+    public interface Builder extends PcepMessage.Builder {

+

+        @Override

+        PcepInitiateMsg build();

+

+        @Override

+        PcepVersion getVersion();

+

+        @Override

+        PcepType getType();

+

+        /**

+         * Returns list of PcInitiatedLspRequestList.

+         *

+         * @return list of PcInitiatedLspRequestList

+         */

+        LinkedList<PcInitiatedLspRequest> getPcInitiatedLspRequestList();

+

+        /**

+         * Sets PcInitiatedLspRequestList.

+         *

+         * @param llPcInitiatedLspRequestList list of PcInitiatedLspRequestList

+         * @return builder by setting list of PcInitiatedLspRequestList

+         */

+        Builder setPcInitiatedLspRequestList(LinkedList<PcInitiatedLspRequest> llPcInitiatedLspRequestList);

+    }

+}
\ No newline at end of file
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepInterLayerObject.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepInterLayerObject.java
new file mode 100755
index 0000000..2772db8
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepInterLayerObject.java
@@ -0,0 +1,142 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+import org.onosproject.pcepio.types.PcepObjectHeader;

+

+/**

+ * Abstraction of an entity providing PCEP INTER Layer Object.

+ */

+public interface PcepInterLayerObject {

+

+    /**

+     * Returns N Flag in INTER Layer Object.

+     *

+     * @return N Flag in INTER Layer Object

+     */

+    boolean getbNFlag();

+

+    /**

+     * Sets N Flag in INTER Layer Object with specified value.

+     *

+     * @param value N Flag

+     */

+    void setbNFlag(boolean value);

+

+    /**

+     * Returns I Flag in INTER Layer Object.

+     *

+     * @return I Flag in INTER Layer Object

+     */

+    boolean getbIFlag();

+

+    /**

+     * Sets I Flag in INTER Layer Object with specified value.

+     *

+     * @param value I Flag

+     */

+    void setbIFlag(boolean value);

+

+    /**

+     * Prints attributes of INTER Layer object.

+     */

+    void print();

+

+    /**

+     * Writes the INTER Layer Object into channel buffer.

+     *

+     * @param bb channel buffer

+     * @return Returns the writerIndex of this buffer

+     * @throws PcepParseException while writing Inter Layer Object.

+     */

+    int write(ChannelBuffer bb) throws PcepParseException;

+

+    /**

+     * Builder interface with get and set functions to build INTER Layer object.

+     */

+    public interface Builder {

+

+        /**

+         * Builds INTER Layer object.

+         *

+         * @return INTER Layer object

+         */

+        PcepInterLayerObject build();

+

+        /**

+         * Returns INTER Layer object header.

+         *

+         * @return INTER Layer object header

+         */

+        PcepObjectHeader getInterLayerObjHeader();

+

+        /**

+         * Sets INTER Layer object header and returns its builder.

+         *

+         * @param obj INTER Layer object header

+         * @return Builder by setting INTER Layer object header

+         */

+        Builder setInterLayerObjHeader(PcepObjectHeader obj);

+

+        /**

+         * Returns N Flag in INTER Layer Object.

+         *

+         * @return N Flag in INTER Layer Object

+         */

+        boolean getbNFlag();

+

+        /**

+         * Sets N flag and return its builder.

+         *

+         * @param value N flag

+         * @return Builder by setting N flag

+         */

+        Builder setbNFlag(boolean value);

+

+        /**

+         * Returns I Flag in INTER Layer Object.

+         *

+         * @return I Flag in INTER Layer Object

+         */

+        boolean getbIFlag();

+

+        /**

+         * Sets I flag and return its builder.

+         *

+         * @param value I flag

+         * @return Builder by setting N flag

+         */

+        Builder setbIFlag(boolean value);

+

+        /**

+         * Sets P flag in INTER Layer object header and returns its builder.

+         *

+         * @param value boolean value to set P flag

+         * @return Builder by setting P flag

+         */

+        Builder setPFlag(boolean value);

+

+        /**

+         * Sets I flag in INTER Layer object header and returns its builder.

+         *

+         * @param value boolean value to set I flag

+         * @return Builder by setting I flag

+         */

+        Builder setIFlag(boolean value);

+    }

+}

diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepIroObject.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepIroObject.java
new file mode 100755
index 0000000..672677b
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepIroObject.java
@@ -0,0 +1,115 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+import java.util.LinkedList;

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+import org.onosproject.pcepio.types.PcepObjectHeader;

+import org.onosproject.pcepio.types.PcepValueType;

+

+/**

+ * Abstraction of an entity providing PCEP IRO Object.

+ */

+public interface PcepIroObject {

+

+    /**

+     * Returns list of  SubObjects.

+     *

+     * @return list of  SubObjects

+     */

+    LinkedList<PcepValueType> getSubObjects();

+

+    /**

+     * Sets list of SubObjects.

+     *

+     * @param llSubObjects list of SubObjects

+     */

+    void setSubObjects(LinkedList<PcepValueType> llSubObjects);

+

+    /**

+     * Prints attributes of IRO object.

+     */

+    void print();

+

+    /**

+     * Writes the IRO into channel buffer.

+     *

+     * @param bb channel buffer

+     * @return Returns the writerIndex of this buffer

+     * @throws PcepParseException while writing IRO object.

+     */

+    public int write(ChannelBuffer bb) throws PcepParseException;

+

+    /**

+     * Builder interface with get and set functions to build IRO object.

+     */

+    public interface Builder {

+

+        /**

+         * Builds IRO Object.

+         *

+         * @return IRO Object

+         */

+        PcepIroObject build();

+

+        /**

+         * Returns IRO object header.

+         *

+         * @return IRO object header

+         */

+        PcepObjectHeader getIroObjHeader();

+

+        /**

+         * Sets IRO object header and returns its builder.

+         *

+         * @param obj IRO object header

+         * @return Builder by setting IRO object header

+         */

+        Builder setIroObjHeader(PcepObjectHeader obj);

+

+        /**

+         * Returns list of SubObjects.

+         *

+         * @return list of SubObjects

+         */

+        LinkedList<PcepValueType> getSubObjects();

+

+        /**

+         * Sets list of SubObjects in IRO Object and returns its builder.

+         *

+         * @param llSubObjects list of  SubObjects

+         * @return Builder by setting list of  SubObjects

+         */

+        Builder setSubObjects(LinkedList<PcepValueType> llSubObjects);

+

+        /**

+         * Sets P flag in IRO object header and returns its builder.

+         *

+         * @param value boolean value to set P flag

+         * @return Builder by setting P flag

+         */

+        Builder setPFlag(boolean value);

+

+        /**

+         * Sets I flag in IRO object header and returns its builder.

+         *

+         * @param value boolean value to set I flag

+         * @return Builder by setting I flag

+         */

+        Builder setIFlag(boolean value);

+    }

+}

diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepKeepaliveMsg.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepKeepaliveMsg.java
new file mode 100755
index 0000000..aad8811
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepKeepaliveMsg.java
@@ -0,0 +1,49 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+
+/**
+ * Abstraction of an entity providing PCEP Keepalive Message.
+ */
+public interface PcepKeepaliveMsg extends PcepObject, PcepMessage {
+
+    @Override
+    PcepVersion getVersion();
+
+    @Override
+    PcepType getType();
+
+    @Override
+    void writeTo(ChannelBuffer channelBuffer);
+
+    /**
+     * Builder interface with get and set functions to build Keepalive message.
+     */
+    public interface Builder extends PcepMessage.Builder {
+
+        @Override
+        PcepKeepaliveMsg build();
+
+        @Override
+        PcepVersion getVersion();
+
+        @Override
+        PcepType getType();
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLabelObject.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLabelObject.java
new file mode 100755
index 0000000..82cac1f
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLabelObject.java
@@ -0,0 +1,176 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import java.util.LinkedList;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+import org.onosproject.pcepio.types.PcepObjectHeader;
+import org.onosproject.pcepio.types.PcepValueType;
+
+/**
+ * Abstraction of an entity providing PCEP Label Object.
+ */
+public interface PcepLabelObject {
+
+    /**
+     * Returns O flag in Label Object.
+     *
+     * @return Boolean value
+     */
+    boolean getOFlag();
+
+    /**
+     * Sets O flag in Label Object with specified value.
+     *
+     * @param value O flag
+     */
+    void setOFlag(boolean value);
+
+    /**
+     * Returns Label from Label Object.
+     *
+     * @return Label value
+     */
+    int getLabel();
+
+    /**
+     * Sets Label field in Label Object with specified value.
+     *
+     * @param value Label
+     */
+    void setLabel(int value);
+
+    /**
+     * Returns list of Optional Tlvs.
+     *
+     * @return list of Optional Tlvs
+     */
+    LinkedList<PcepValueType> getOptionalTlv();
+
+    /**
+     * Sets Optional Tlvs in Label Object.
+     *
+     * @param llOptionalTlv list of Optional Tlvs
+     */
+    void setOptionalTlv(LinkedList<PcepValueType> llOptionalTlv);
+
+    /**
+     * Prints attributes of Label object.
+     */
+    void print();
+
+    /**
+     * Writes the Label Object into channel buffer.
+     *
+     * @param bb channel buffer
+     * @return Returns the writerIndex of this buffer
+     * @throws PcepParseException while writing LABEL object into Channel Buffer.
+     */
+    int write(ChannelBuffer bb) throws PcepParseException;
+
+    /**
+     * Builder interface with get and set functions to build Label object.
+     */
+    public interface Builder {
+
+        /**
+         * Builds Label Object.
+         *
+         * @return Label Object
+         * @throws PcepParseException while building LABEL object.
+         */
+        PcepLabelObject build() throws PcepParseException;
+
+        /**
+         * Returns Label object header.
+         *
+         * @return Label object header
+         */
+        PcepObjectHeader getLabelObjHeader();
+
+        /**
+         * Sets Label object header and returns its builder.
+         *
+         * @param obj Label object header
+         * @return Builder by setting Label object header
+         */
+        Builder setLabelObjHeader(PcepObjectHeader obj);
+
+        /**
+         * Returns O flag in Label Object.
+         *
+         * @return Label value
+         */
+        boolean getOFlag();
+
+        /**
+         * Sets O flag and return its builder.
+         *
+         * @param value O flag
+         * @return Builder by setting O flag
+         */
+        Builder setOFlag(boolean value);
+
+        /**
+         * Returns Label from Label Object.
+         *
+         * @return Label value
+         */
+        int getLabel();
+
+        /**
+         * Sets Label field and return its builder.
+         *
+         * @param value Label field
+         * @return Builder by setting Label field
+         */
+        Builder setLabel(int value);
+
+        /**
+         * Returns list of Optional Tlvs.
+         *
+         * @return list of Optional Tlvs
+         */
+        LinkedList<PcepValueType> getOptionalTlv();
+
+        /**
+         * Sets list of Optional Tlvs and return its builder.
+         *
+         * @param llOptionalTlv list of Optional Tlvs
+         * @return Builder by setting list of Optional Tlvs
+         */
+        Builder setOptionalTlv(LinkedList<PcepValueType> llOptionalTlv);
+
+        /**
+         * Sets P flag in Label object header and returns its builder.
+         *
+         * @param value boolean value to set P flag
+         * @return Builder by setting P flag
+         */
+        public Builder setPFlag(boolean value);
+
+        /**
+         * Sets I flag in Label object header and returns its builder.
+         *
+         * @param value boolean value to set I flag
+         * @return Builder by setting I flag
+         */
+        public Builder setIFlag(boolean value);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLabelRange.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLabelRange.java
new file mode 100755
index 0000000..53ce6e4
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLabelRange.java
@@ -0,0 +1,70 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+import java.util.LinkedList;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+

+/**

+ * Abstraction of an entity providing PCEP Label Range.

+ */

+public interface PcepLabelRange {

+

+    /**

+     * Returns object of PCEP SRP Object.

+     *

+     * @return srpObject

+     */

+    public PcepSrpObject getSrpObject();

+

+    /**

+     * Sets PCEP SRP Object.

+     *

+     * @param srpObject SRP object.

+     */

+    public void setSrpObject(PcepSrpObject srpObject);

+

+    /**

+     * Returns list of PcepLabelRangeObject.

+     *

+     * @return Label Range List

+     */

+    public LinkedList<PcepLabelRangeObject> getLabelRangeList();

+

+    /**

+     * Sets list of PcepLabelRangeObject.

+     *

+     * @param llLabelRangeList Label Range List

+     */

+    public void setLabelRangeList(LinkedList<PcepLabelRangeObject> llLabelRangeList);

+

+    /**

+     * Write the byte stream of PcepLabelRange to channel buffer.

+     *

+     * @param bb of type channel buffer

+     * @return object length index

+     * @throws PcepParseException while writing LABEL RANGE into Channel Buffer.

+     */

+    public int write(ChannelBuffer bb) throws PcepParseException;

+

+    /**

+     * Prints Attributes of PcepLabelRange.

+     */

+    public void print();

+}
\ No newline at end of file
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLabelRangeObject.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLabelRangeObject.java
new file mode 100755
index 0000000..dfd8c12
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLabelRangeObject.java
@@ -0,0 +1,187 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+import org.onosproject.pcepio.types.PcepObjectHeader;
+
+/**
+ * Abstraction of an entity providing PCEP LabelRange Object.
+ */
+public interface PcepLabelRangeObject {
+
+    /**
+     * Sets LabelRange Object header.
+     *
+     * @param obj LabelRange Object header
+     */
+    void setLabelRangeObjHeader(PcepObjectHeader obj);
+
+    /**
+     * Sets LabelType in LabelRange Object.
+     *
+     * @param labelType label type value
+     */
+    void setLabelType(byte labelType);
+
+    /**
+     * Sets RangeSize in LabelRange Object.
+     *
+     * @param rangeSize range size value
+     */
+    void setRangeSize(int rangeSize);
+
+    /**
+     * Sets LabelBase in LabelRange Object.
+     *
+     * @param labelBase label base value
+     */
+    void setLabelBase(int labelBase);
+
+    /**
+     * Returns LabelRange object header.
+     *
+     * @return LabelRange object header
+     */
+    PcepObjectHeader getLabelRangeObjHeader();
+
+    /**
+     * Returns LabelType field in LabelRange object.
+     *
+     * @return LabelType field in LabelRange object
+     */
+    byte getLabelType();
+
+    /**
+     * Returns RangeSize field in LabelRange object.
+     *
+     * @return RangeSize field in LabelRange object
+     */
+    int getRangeSize();
+
+    /**
+     * Returns LabelBase field in LabelRange object.
+     *
+     * @return LabelBase field in LabelRange object
+     */
+    int getLabelBase();
+
+    /**
+     * Prints attributes of LabelRange object.
+     */
+    void print();
+
+    /**
+     * Writes the LabelRange Object into channel buffer.
+     *
+     * @param bb channel buffer
+     * @return Returns the writerIndex of this buffer
+     * @throws PcepParseException while writing LABEL RANGE object into Channel Buffer.
+     */
+    int write(ChannelBuffer bb) throws PcepParseException;
+
+    /**
+     * Builder interface with get and set functions to build LabelRange object.
+     */
+    public interface Builder {
+
+        /**
+         * Builds LabelRange Object.
+         *
+         * @return LabelRange Object
+         * @throws PcepParseException while building LABEL RANGE object.
+         */
+        PcepLabelRangeObject build() throws PcepParseException;
+
+        /**
+         * Returns LabelRange object header.
+         *
+         * @return LabelRange object header
+         */
+        PcepObjectHeader getLabelRangeObjHeader();
+
+        /**
+         * Sets LabelRange object header and returns its builder.
+         *
+         * @param obj LabelRange object header
+         * @return Builder by setting LabelRange object header
+         */
+        Builder setLabelRangeObjHeader(PcepObjectHeader obj);
+
+        /**
+         * Returns LabelType field in LabelRange object.
+         *
+         * @return LabelType field in LabelRange object
+         */
+        byte getLabelType();
+
+        /**
+         * Sets LabelType field and returns its builder.
+         *
+         * @param labelType LabelType field
+         * @return Builder by setting LabelType field
+         */
+        Builder setLabelType(byte labelType);
+
+        /**
+         * Returns RangeSize field in LabelRange object.
+         *
+         * @return RangeSize field in LabelRange object
+         */
+        int getRangeSize();
+
+        /**
+         * Sets RangeSize field and returns its builder.
+         *
+         * @param rangeSize RangeSize field
+         * @return Builder by setting RangeSize field
+         */
+        Builder setRangeSize(int rangeSize);
+
+        /**
+         * Returns LabelBase field in LabelRange object.
+         *
+         * @return LabelBase field in LabelRange object
+         */
+        int getLabelBase();
+
+        /**
+         * Sets LabelBase field and returns its builder.
+         *
+         * @param labelBase LabelBase field
+         * @return Builder by setting LabelBase field
+         */
+        Builder setLabelBase(int labelBase);
+
+        /**
+         * Sets P flag in TE object header and returns its builder.
+         *
+         * @param value boolean value to set P flag
+         * @return Builder by setting P flag
+         */
+        Builder setPFlag(boolean value);
+
+        /**
+         * Sets I flag in TE object header and returns its builder.
+         *
+         * @param value boolean value to set I flag
+         * @return Builder by setting I flag
+         */
+        Builder setIFlag(boolean value);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLabelRangeResvMsg.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLabelRangeResvMsg.java
new file mode 100755
index 0000000..04b180f
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLabelRangeResvMsg.java
@@ -0,0 +1,79 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+
+/**
+ * Abstraction of an entity providing PCEP Label Range Reservation Message.
+ */
+public interface PcepLabelRangeResvMsg extends PcepObject, PcepMessage {
+
+    @Override
+    PcepVersion getVersion();
+
+    @Override
+    PcepType getType();
+
+    /**
+     * Returns LabelRange field in Label Range Reservation message.
+     *
+     * @return LabelRange field
+     */
+    PcepLabelRange getLabelRange();
+
+    /**
+     * Sets LabelRange field in Label Range Reservation message with specified value.
+     *
+     * @param lR label range object
+     */
+    void setLabelRange(PcepLabelRange lR);
+
+    @Override
+    void writeTo(ChannelBuffer channelBuffer) throws PcepParseException;
+
+    /**
+     * Builder interface with get and set functions to build Label Range Reservation message.
+     */
+    public interface Builder extends PcepMessage.Builder {
+
+        @Override
+        PcepLabelRangeResvMsg build();
+
+        @Override
+        PcepVersion getVersion();
+
+        @Override
+        PcepType getType();
+
+        /**
+         * Returns LabelRange field in Label Range Reservation message.
+         *
+         * @return LabelRange object
+         */
+        PcepLabelRange getLabelRange();
+
+        /**
+         * Sets LabelRange field and returns its Builder.
+         *
+         * @param lR label range object
+         * @return builder by setting LabelRange field
+         */
+        Builder setLabelRange(PcepLabelRange lR);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLabelUpdate.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLabelUpdate.java
new file mode 100755
index 0000000..3db19b9
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLabelUpdate.java
@@ -0,0 +1,113 @@
+/*

+ * Copyright 2014 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.pcepio.protocol;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+import org.onosproject.pcepio.types.PcepLabelDownload;

+import org.onosproject.pcepio.types.PcepLabelMap;

+

+/***

+ * Abstraction to provide PCEP Label Updates.

+ */

+public interface PcepLabelUpdate {

+

+    /**

+     * Writes the byte stream of PcepLabelUpdate into channel buffer.

+     *

+     * @param bb of type channel buffer

+     * @throws PcepParseException while writing LABEL UPDATE.

+     */

+    public void write(ChannelBuffer bb) throws PcepParseException;

+

+    /**

+     * Sets the Label Download object.

+     *

+     * @param labelDownload PCEP Label Download object

+     */

+    public void setLabelDownload(PcepLabelDownload labelDownload);

+

+    /**

+     * Returns the PcepLabelDownload object.

+     *

+     * @return labelDownload PCEP Label Download

+     */

+    public PcepLabelDownload getLabelDownload();

+

+    /**

+     * Sets the Label map object.

+     *

+     * @param labelMap PCEP Label Map object

+     */

+    public void setLabelMap(PcepLabelMap labelMap);

+

+    /**

+     * Returns the PcepLabelMap object.

+     *

+     * @return labelMap PCEP Label Map

+     */

+    public PcepLabelMap getLabelMap();

+

+    /**

+     * Prints the attributes of PCEP Label update.

+     */

+    public void print();

+

+    /**

+     * Builder interface with get and set functions to build Label Update message.

+     */

+    public interface Builder {

+

+        /**

+         * Builds PcepLableUpdate Object.

+         *

+         * @return PcepLableUpdate Object

+         * @throws PcepParseException while building LABEL-UPDATE.

+         */

+        PcepLabelUpdate build() throws PcepParseException;

+

+        /**

+         * Sets the Label Download object.

+         *

+         * @param labelDownload PCEP Label Download object

+         * @return Builder by setting labelDownload object

+         */

+        Builder setLabelDownload(PcepLabelDownload labelDownload);

+

+        /**

+         * Returns the PcepLabelDownload object.

+         *

+         * @return labelDownload PCEP Label Download

+         */

+        PcepLabelDownload getLabelDownload();

+

+        /**

+         * Sets the Label map object.

+         *

+         * @param labelMap PCEP Label Map object

+         * @return Builder by setting PcepLabelMap object

+         */

+        Builder setLabelMap(PcepLabelMap labelMap);

+

+        /**

+         * Returns the PcepLabelMap object.

+         *

+         * @return labelMap PCEP Label Map

+         */

+        PcepLabelMap getLabelMap();

+    }

+

+}

diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLabelUpdateMsg.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLabelUpdateMsg.java
new file mode 100755
index 0000000..d6e147b
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLabelUpdateMsg.java
@@ -0,0 +1,81 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import java.util.LinkedList;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+
+/**
+ * Abstraction of an entity providing PCEP Label Update Message.
+ */
+public interface PcepLabelUpdateMsg extends PcepObject, PcepMessage {
+
+    @Override
+    PcepVersion getVersion();
+
+    @Override
+    PcepType getType();
+
+    /**
+     * Returns list of PcLabelUpdateList.
+     *
+     * @return list of PcLabelUpdateList.
+     */
+    LinkedList<PcepLabelUpdate> getPcLabelUpdateList();
+
+    /**
+     * Sets list of PcLabelUpdateList.
+     *
+     * @param llPcLabelUpdateList list of PcLabelUpdateList
+     */
+    void setPcLabelUpdateList(LinkedList<PcepLabelUpdate> llPcLabelUpdateList);
+
+    @Override
+    void writeTo(ChannelBuffer channelBuffer) throws PcepParseException;
+
+    /**
+     * Builder interface with get and set functions to build Label Update message.
+     */
+    public interface Builder extends PcepMessage.Builder {
+
+        @Override
+        PcepLabelUpdateMsg build();
+
+        @Override
+        PcepVersion getVersion();
+
+        @Override
+        PcepType getType();
+
+        /**
+         * Returns list of PcLabelUpdateList.
+         *
+         * @return list of PcLabelUpdateList.
+         */
+        LinkedList<PcepLabelUpdate> getPcLabelUpdateList();
+
+        /**
+         * Sets list of PcLabelUpdateList.
+         *
+         * @param llPcLabelUpdateList list of PcLabelUpdateList.
+         * @return Builder by setting list of PcLabelUpdateList.
+         */
+        Builder setPcLabelUpdateList(LinkedList<PcepLabelUpdate> llPcLabelUpdateList);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLspObject.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLspObject.java
new file mode 100755
index 0000000..8a03833
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLspObject.java
@@ -0,0 +1,291 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import java.util.LinkedList;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+import org.onosproject.pcepio.types.PcepObjectHeader;
+import org.onosproject.pcepio.types.PcepValueType;
+
+/**
+ * Abstraction of an entity providing PCEP LSP Object.
+ */
+public interface PcepLspObject {
+
+    /**
+     * Returns PlspId of LSP Object.
+     *
+     * @return PlspId of LSP Object
+     */
+    int getPlspId();
+
+    /**
+     * Sets PlspId with specified value.
+     *
+     * @param value PlspId
+     */
+    void setPlspId(int value);
+
+    /**
+     * Returns O flag in LSP Object.
+     *
+     * @return O flag in LSP Object
+     */
+    byte getOFlag();
+
+    /**
+     * Sets O flag with specified value.
+     *
+     * @param value O flag
+     */
+    void setOFlag(byte value);
+
+    /**
+     * Returns A flag in LSP Object.
+     *
+     * @return A flag in LSP Object
+     */
+    boolean getAFlag();
+
+    /**
+     * Sets A flag with specified value.
+     *
+     * @param value A flag
+     */
+    void setAFlag(boolean value);
+
+    /**
+     * Returns R flag in LSP Object.
+     *
+     * @return R flag in LSP Object
+     */
+    boolean getRFlag();
+
+    /**
+     * Sets R flag with specified value.
+     *
+     * @param value R flag
+     */
+    void setRFlag(boolean value);
+
+    /**
+     * Returns S flag in LSP Object.
+     *
+     * @return S flag in LSP Object
+     */
+    boolean getSFlag();
+
+    /**
+     * Sets S flag with specified value.
+     *
+     * @param value S flag
+     */
+    void setSFlag(boolean value);
+
+    /**
+     * Returns D flag in LSP Object.
+     *
+     * @return D flag in LSP Object
+     */
+    boolean getDFlag();
+
+    /**
+     * Sets D flag with specified value.
+     *
+     * @param value D flag
+     */
+    void setDFlag(boolean value);
+
+    /**
+     * Returns list of Optional Tlvs in LSP Object.
+     *
+     * @return list of Optional Tlvs
+     */
+    LinkedList<PcepValueType> getOptionalTlv();
+
+    /**
+     * Sets list of Optional Tlvs in LSP Object.
+     *
+     * @param llOptionalTlv list of Optional Tlvs
+     */
+    void setOptionalTlv(LinkedList<PcepValueType> llOptionalTlv);
+
+    /**
+     * Prints attributes of LSP object.
+     */
+    void print();
+
+    /**
+     * Writes the LSP Object into channel buffer.
+     *
+     * @param bb channel buffer
+     * @return Returns the writerIndex of this buffer
+     * @throws PcepParseException while writing LSP object into Channel Buffer.
+     */
+    int write(ChannelBuffer bb) throws PcepParseException;
+
+    /**
+     * Builder interface with get and set functions to build LSP object.
+     */
+    public interface Builder {
+
+        /**
+         * Builds LSP Object.
+         *
+         * @return LSP Object
+         */
+        PcepLspObject build();
+
+        /**
+         * Returns LSP object header.
+         *
+         * @return LSP object header
+         */
+        PcepObjectHeader getLspObjHeader();
+
+        /**
+         * Sets LSP object header and returns its builder.
+         *
+         * @param obj LSP object header
+         * @return Builder by setting LSP object header
+         */
+        Builder setLspObjHeader(PcepObjectHeader obj);
+
+        /**
+         * Returns PlspId of LSP Object.
+         *
+         * @return PlspId of LSP Object
+         */
+        int getPlspId();
+
+        /**
+         * Sets PlspId with specific value and return its builder.
+         *
+         * @param value PlspId
+         * @return Builder by setting PlspId
+         */
+        Builder setPlspId(int value);
+
+        /**
+         * Returns O flag in LSP Object.
+         *
+         * @return O flag in LSP Object
+         */
+        byte getOFlag();
+
+        /**
+         * Sets O flag with specific value and return its builder.
+         *
+         * @param value O flag
+         * @return Builder by setting O flag
+         */
+        Builder setOFlag(byte value);
+
+        /**
+         * Returns A flag in LSP Object.
+         *
+         * @return A flag in LSP Object
+         */
+        boolean getAFlag();
+
+        /**
+         * Sets A flag with specific value and return its builder.
+         *
+         * @param value A flag
+         * @return Builder by setting A flag
+         */
+        Builder setAFlag(boolean value);
+
+        /**
+         * Returns A flag in LSP Object.
+         *
+         * @return A flag in LSP Object
+         */
+        boolean getRFlag();
+
+        /**
+         * Sets R flag with specific value and return its builder.
+         *
+         * @param value r flag
+         * @return Builder by setting r flag
+         */
+        Builder setRFlag(boolean value);
+
+        /**
+         * Returns S flag in LSP Object.
+         *
+         * @return S flag in LSP Object
+         */
+        boolean getSFlag();
+
+        /**
+         * Sets S flag with specific value and return its builder.
+         *
+         * @param value s flag
+         * @return Builder by setting S flag
+         */
+        Builder setSFlag(boolean value);
+
+        /**
+         * Returns D flag in LSP Object.
+         *
+         * @return D flag in LSP Object
+         */
+        boolean getDFlag();
+
+        /**
+         * Sets D flag with specific value and return its builder.
+         *
+         * @param value D flag
+         * @return Builder by setting D flag
+         */
+        Builder setDFlag(boolean value);
+
+        /**
+         * Returns list of Optional Tlvs in LSP Object.
+         *
+         * @return list of Optional Tlvs in LSP Object
+         */
+        LinkedList<PcepValueType> getOptionalTlv();
+
+        /**
+         * Sets list of Optional Tlvs and return its builder.
+         *
+         * @param llOptionalTlv list of Optional Tlvs
+         * @return Builder by setting list of Optional Tlvs
+         */
+        Builder setOptionalTlv(LinkedList<PcepValueType> llOptionalTlv);
+
+        /**
+         * Sets P flag in LSP object header and returns its builder.
+         *
+         * @param value boolean value to set P flag
+         * @return Builder by setting P flag
+         */
+        Builder setPFlag(boolean value);
+
+        /**
+         * Sets I flag in LSP object header and returns its builder.
+         *
+         * @param value boolean value to set I flag
+         * @return Builder by setting I flag
+         */
+        Builder setIFlag(boolean value);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLspaObject.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLspaObject.java
new file mode 100755
index 0000000..d730002
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepLspaObject.java
@@ -0,0 +1,291 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+import java.util.LinkedList;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+import org.onosproject.pcepio.types.PcepObjectHeader;

+import org.onosproject.pcepio.types.PcepValueType;

+

+/**

+ * Abstraction of an entity providing PCEP LSPA Object.

+ */

+public interface PcepLspaObject {

+

+    /**

+     * Returns L flag in LSPA Object.

+     *

+     * @return L flag in LSPA Object

+     */

+    boolean getLFlag();

+

+    /**

+     * Sets L flag in LSPA Object.

+     *

+     * @param value L flag

+     */

+    void setLFlag(boolean value);

+

+    /**

+     * Returns Exclude Any field in LSPA Object.

+     *

+     * @return Exclude Any field in LSPA Object

+     */

+    int getExcludeAny();

+

+    /**

+     * Sets Exclude Any field in LSPA Object.

+     *

+     * @param value Exclude Any field

+     */

+    void setExcludeAny(int value);

+

+    /**

+     * Returns Include Any field in LSPA Object.

+     *

+     * @return Include Any field in LSPA Object

+     */

+    int getIncludeAny();

+

+    /**

+     * Sets Include Any field in LSPA Object.

+     *

+     * @param value Include Any field

+     */

+    void setIncludeAny(int value);

+

+    /**

+     * Returns Include All field in LSPA Object.

+     *

+     * @return Include All field in LSPA Object

+     */

+    int getIncludeAll();

+

+    /**

+     * Sets Include All field in LSPA Object.

+     *

+     * @param value Include All field

+     */

+    void setIncludeAll(int value);

+

+    /**

+     * Returns Setup Priority field in LSPA Object.

+     *

+     * @return Setup Priority field in LSPA Object

+     */

+    byte getSetupPriority();

+

+    /**

+     * Sets Setup Priority field in LSPA Object.

+     *

+     * @param value Setup Priority field

+     */

+    void setSetupPriority(byte value);

+

+    /**

+     * Returns Hold Priority field in LSPA Object.

+     *

+     * @return Hold Priority field in LSPA Object

+     */

+    byte getHoldPriority();

+

+    /**

+     * Sets Hold Priority field in LSPA Object.

+     *

+     * @param value Hold Priority field

+     */

+    void setHoldPriority(byte value);

+

+    /**

+     * Returns list of Optional Tlvs in LSPA Object.

+     *

+     * @return list of Optional Tlvs in LSPA Object

+     */

+    LinkedList<PcepValueType> getOptionalTlv();

+

+    /**

+     * Sets Optional Tlvs in LSPA Object.

+     *

+     * @param llOptionalTlv Optional Tlvs in LSPA Object

+     */

+    void setOptionalTlv(LinkedList<PcepValueType> llOptionalTlv);

+

+    /**

+     * Prints attributes of LSPA object.

+     */

+    void print();

+

+    /**

+     * Writes the LSPA Object into channel buffer.

+     *

+     * @param bb channel buffer

+     * @return Returns the writerIndex of this buffer

+     * @throws PcepParseException while writing LSPA object into Channel Buffer.

+     */

+    int write(ChannelBuffer bb) throws PcepParseException;

+

+    /**

+     * Builder interface with get and set functions to build bandwidth object.

+     */

+    public interface Builder {

+

+        /**

+         * Builds LSPA Object.

+         *

+         * @return LSPA Object

+         * @throws PcepParseException while building LSPA object.

+         */

+        PcepLspaObject build() throws PcepParseException;

+

+        /**

+         * Returns LSPA object header.

+         *

+         * @return LSPA object header

+         */

+        PcepObjectHeader getLspaObjHeader();

+

+        /**

+         * Sets LSPA object header and returns its builder.

+         *

+         * @param obj LSPA object header

+         * @return Builder by setting LSPA object header

+         */

+        Builder setLspaObjHeader(PcepObjectHeader obj);

+

+        /**

+         * Returns L flag in LSPA Object.

+         *

+         * @return L flag in LSPA Object

+         */

+        boolean getLFlag();

+

+        /**

+         * Sets L flag in LSPA Object and return its builder.

+         *

+         * @param value L flag in LSPA Object

+         * @return Builder by setting L flag

+         */

+        Builder setLFlag(boolean value);

+

+        /**

+         * Returns Exclude Any field in LSPA Object.

+         *

+         * @return Exclude Any field in LSPA Object

+         */

+        int getExcludeAny();

+

+        /**

+         * Sets Exclude Any field in LSPA Object and return its builder.

+         *

+         * @param value Exclude Any field in LSPA Object

+         * @return Builder by setting Exclude Any field

+         */

+        Builder setExcludeAny(int value);

+

+        /**

+         * Returns Include Any field in LSPA Object.

+         *

+         * @return Include Any field in LSPA Object

+         */

+        int getIncludeAny();

+

+        /**

+         * Sets Include Any field in LSPA Object and return its builder.

+         *

+         * @param value Include Any field in LSPA Object

+         * @return Builder by setting Include Any field

+         */

+        Builder setIncludeAny(int value);

+

+        /**

+         * Returns Include All field in LSPA Object.

+         *

+         * @return Include All field in LSPA Object

+         */

+        int getIncludeAll();

+

+        /**

+         * Sets Include All field in LSPA Object and return its builder.

+         *

+         * @param value Include All field in LSPA Object

+         * @return Builder by setting Include All field

+         */

+        Builder setIncludeAll(int value);

+

+        /**

+         * Returns Setup Priority field in LSPA Object.

+         *

+         * @return Setup Priority field in LSPA Object

+         */

+        byte getSetupPriority();

+

+        /**

+         * Sets Setup Priority field in LSPA Object and return its builder.

+         *

+         * @param value Setup Priority field in LSPA Object

+         * @return Builder by setting Setup Priority field

+         */

+        Builder setSetupPriority(byte value);

+

+        /**

+         * Returns Hold Priority field in LSPA Object.

+         *

+         * @return Hold Priority field in LSPA Object

+         */

+        byte getHoldPriority();

+

+        /**

+         * Sets Hold Priority field in LSPA Object and return its builder.

+         *

+         * @param value Hold Priority field in LSPA Object

+         * @return Builder by setting Hold Priority field

+         */

+        Builder setHoldPriority(byte value);

+

+        /**

+         * Returns list of Optional Tlvs in LSPA Object.

+         *

+         * @return list of Optional Tlvs in LSPA Object

+         */

+        LinkedList<PcepValueType> getOptionalTlv();

+

+        /**

+         * Sets list of Optional Tlvs in LSPA Object.

+         *

+         * @param llOptionalTlv list of Optional Tlvs

+         * @return builder by setting list of Optional Tlvs

+         */

+        Builder setOptionalTlv(LinkedList<PcepValueType> llOptionalTlv);

+

+        /**

+         * Sets P flag in LSPA object header and returns its builder.

+         *

+         * @param value boolean value to set P flag

+         * @return Builder by setting P flag

+         */

+        Builder setPFlag(boolean value);

+

+        /**

+         * Sets I flag in LSPA object header and returns its builder.

+         *

+         * @param value boolean value to set I flag

+         * @return Builder by setting I flag

+         */

+        Builder setIFlag(boolean value);

+    }

+}
\ No newline at end of file
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepMessage.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepMessage.java
new file mode 100755
index 0000000..a6a71a1
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepMessage.java
@@ -0,0 +1,72 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+
+/**
+ * Abstraction of an entity providing PCEP Messages.
+ */
+public interface PcepMessage extends PcepObject {
+
+    @Override
+    PcepVersion getVersion();
+
+    /**
+     * Returns Type of PCEP Message.
+     *
+     * @return Type of PCEP Message
+     */
+    PcepType getType();
+
+    /**
+     * Prints attributes of PCEP Messages.
+     */
+    void print();
+
+    @Override
+    void writeTo(ChannelBuffer channelBuffer) throws PcepParseException;
+
+    /**
+     * Builder interface with get and set functions to build PCEP Message.
+     */
+    public interface Builder {
+
+        /**
+         * Builds PCEP Message.
+         *
+         * @return PCEP Message
+         * @throws PcepParseException when build fails to create PCEP message
+         */
+        PcepMessage build() throws PcepParseException;
+
+        /**
+         * Returns Version of PCEP Message.
+         *
+         * @return Version of PCEP Message
+         */
+        PcepVersion getVersion();
+
+        /**
+         * Returns Type of PCEP Message.
+         *
+         * @return Type of PCEP Message
+         */
+        PcepType getType();
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepMessageReader.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepMessageReader.java
new file mode 100755
index 0000000..591a033
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepMessageReader.java
@@ -0,0 +1,36 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+
+/**
+ * Abstraction of an entity providing PCEP Message Reader.
+ */
+public interface PcepMessageReader<T> {
+
+    /**
+     * Reads the Objects in the PCEP Message and Returns PCEP Message.
+     *
+     * @param bb Channel Buffer
+     * @return PCEP Message
+     * @throws PcepParseException while parsing PCEP message.
+     * @throws PcepParseException when received message is empty
+     */
+    T readFrom(ChannelBuffer bb) throws PcepParseException;
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepMessageWriter.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepMessageWriter.java
new file mode 100755
index 0000000..cb16db2
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepMessageWriter.java
@@ -0,0 +1,35 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+
+/**
+ * Abstraction of an entity providing PCEP Message Writer.
+ */
+public interface PcepMessageWriter<T> {
+
+    /**
+     * Writes the Objects of the PCEP Message into Channel Buffer.
+     *
+     * @param bb Channel Buffer
+     * @param message PCEP Message
+     * @throws PcepParseException while writing PCEP message.
+     */
+    public void write(ChannelBuffer bb, T message) throws PcepParseException;
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepMetricObject.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepMetricObject.java
new file mode 100755
index 0000000..108d225
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepMetricObject.java
@@ -0,0 +1,230 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+import org.onosproject.pcepio.types.PcepObjectHeader;

+

+/**

+ * Abstraction of an entity providing PCEP Metric Object.

+ */

+public interface PcepMetricObject {

+

+    /**

+     * Returns Metric value in Metric Object.

+     *

+     * @return Metric value

+     */

+    int getMetricVal();

+

+    /**

+     * Sets Metric value in Metric Object with specified value.

+     *

+     * @param value Metric value

+     */

+    void setMetricVal(int value);

+

+    /**

+     * Returns Y flag in Metric Object.

+     *

+     * @return Y flag in Metric Object

+     */

+    byte getYFlag();

+

+    /**

+     * Sets Y flag in Metric Object with specified value.

+     *

+     * @param value Y flag

+     */

+    void setYFlag(byte value);

+

+    /**

+     * Returns C flag in Metric Object.

+     *

+     * @return C flag in Metric Object

+     */

+    boolean getCFlag();

+

+    /**

+     * Sets C flag in Metric Object with specified value.

+     *

+     * @param value C flag

+     */

+    void setCFlag(boolean value);

+

+    /**

+     * Returns B flag in Metric Object.

+     *

+     * @return B flag in Metric Object

+     */

+    boolean getBFlag();

+

+    /**

+     * Sets B flag in Metric Object with specified value.

+     *

+     * @param value B flag

+     */

+    void setBFlag(boolean value);

+

+    /**

+     * Returns BType field in Metric Object.

+     *

+     * @return BType field in Metric Object

+     */

+    byte getBType();

+

+    /**

+     * Sets BType field in Metric Object with specified value.

+     *

+     * @param value BType field

+     */

+    void setBType(byte value);

+

+    /**

+     * Prints attributes of Metric object.

+     */

+    void print();

+

+    /**

+     * Writes the Metric Object into channel buffer.

+     *

+     * @param bb channel buffer

+     * @return Returns the writerIndex of this buffer

+     * @throws PcepParseException while writing METRIC object into Channel Buffer.

+     */

+    int write(ChannelBuffer bb) throws PcepParseException;

+

+    /**

+     * Builder interface with get and set functions to build Metric object.

+     */

+    public interface Builder {

+

+        /**

+         * Builds Metric Object.

+         *

+         * @return Metric Object

+         * @throws PcepParseException when mandatory object is not set

+         */

+        PcepMetricObject build() throws PcepParseException;

+

+        /**

+         * Returns Metric object header.

+         *

+         * @return Metric object header

+         */

+        PcepObjectHeader getMetricObjHeader();

+

+        /**

+         * Sets Metric object header and returns its builder.

+         *

+         * @param obj Metric object header

+         * @return Builder by setting Metric object header

+         */

+        Builder setMetricObjHeader(PcepObjectHeader obj);

+

+        /**

+         * Returns Metric value in Metric Object.

+         *

+         * @return Metric value

+         */

+        int getMetricVal();

+

+        /**

+         * Sets Metric Value in Metric Object and returns its builder.

+         *

+         * @param value Metric Value

+         * @return Builder by setting Metric Value

+         */

+        Builder setMetricVal(int value);

+

+        /**

+         * Returns Flags in Metric Object.

+         *

+         * @return Flags in Metric Object

+         */

+        byte getYFlag();

+

+        /**

+         * Sets Flags in Metric Object and returns its builder.

+         *

+         * @param value Flags

+         * @return Builder by setting Flags

+         */

+        Builder setYFlag(byte value);

+

+        /**

+         * Returns C flag in Metric Object.

+         *

+         * @return C flag in Metric Object

+         */

+        boolean getCFlag();

+

+        /**

+         * Sets C flag in Metric Object and returns its builder.

+         *

+         * @param value C flag

+         * @return Builder by setting C flag

+         */

+        Builder setCFlag(boolean value);

+

+        /**

+         * Returns B flag in Metric Object.

+         *

+         * @return B flag in Metric Object

+         */

+        boolean getBFlag();

+

+        /**

+         * Sets B flag in Metric Object and returns its builder.

+         *

+         * @param value B flag

+         * @return Builder by setting B flag

+         */

+        Builder setBFlag(boolean value);

+

+        /**

+         * Returns BType field in Metric Object.

+         *

+         * @return BType field in Metric Object

+         */

+        byte getBType();

+

+        /**

+         * Sets B Type field in Metric Object and returns its builder.

+         *

+         * @param value B Type field

+         * @return Builder by setting B Type field

+         */

+        Builder setBType(byte value);

+

+        /**

+         * Sets P flag in Metric object header and returns its builder.

+         *

+         * @param value boolean value to set P flag

+         * @return Builder by setting P flag

+         */

+        Builder setPFlag(boolean value);

+

+        /**

+         * Sets I flag in Metric object header and returns its builder.

+         *

+         * @param value boolean value to set I flag

+         * @return Builder by setting I flag

+         */

+        Builder setIFlag(boolean value);

+    }

+}

diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepMsgPath.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepMsgPath.java
new file mode 100755
index 0000000..de2d19a
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepMsgPath.java
@@ -0,0 +1,107 @@
+package org.onosproject.pcepio.protocol;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+

+/**

+ * Abstraction of an entity Provides PCEP Message PAth for update message.

+ * Reference :PCE extensions for stateful draft-ietf-pce-stateful-pce-10.

+ */

+public interface PcepMsgPath {

+

+    /**

+     * Returns object of PcepEroObject.

+     *

+     * @return eroObject

+     */

+    PcepEroObject getEroObject();

+

+    /**

+     * Returns object of PcepAttribute.

+     *

+     * @return pcepAttribute

+     */

+    PcepAttribute getPcepAttribute();

+

+    /**

+     * Sets PcepEroObject.

+     *

+     * @param eroObject PCEP ERO Object.

+     */

+    void setEroObject(PcepEroObject eroObject);

+

+    /**

+     * Sets PcepAttribute.

+     *

+     * @param pcepAttribute PCEP-Attribute.

+     */

+    void setPcepAttribute(PcepAttribute pcepAttribute);

+

+    /**

+     * reads ERO object and attribute list.

+     *

+     * @param bb of type channel buffer

+     * @return PcepMsgPath

+     * @throws PcepParseException while parsing Message Path from Channel Buffer.

+     */

+    public PcepMsgPath read(ChannelBuffer bb) throws PcepParseException;

+

+    /**

+     * writes ERO object and attribute list to channel.

+     *

+     * @param bb of type channel buffer

+     * @return object length index

+     * @throws PcepParseException while writing Message Path into Channel Buffer.

+     */

+

+    public int write(ChannelBuffer bb) throws PcepParseException;

+

+    /**

+     * Prints the attributes of PCEP message path.

+     */

+    void print();

+

+    /**

+     * Builder interface with get and set functions to build PcepMsgPath.

+     */

+    public interface Builder {

+

+        /**

+         * Builds PcepMsgPath.

+         *

+         * @return PcepMsgPath

+         * @throws PcepParseException when mandatory object is not set

+         */

+        PcepMsgPath build() throws PcepParseException;

+

+        /**

+         * Returns object of PcepEroObject.

+         *

+         * @return PcepEroObject

+         */

+        PcepEroObject getEroObject();

+

+        /**

+         * Returns object of PcepAttribute.

+         *

+         * @return pcepAttribute

+         */

+        PcepAttribute getPcepAttribute();

+

+        /**

+         * Sets PcepEroObject.

+         *

+         * @param eroObject PcepEroObject

+         * @return Builder by setting ERO object.

+         */

+        Builder setEroObject(PcepEroObject eroObject);

+

+        /**

+         * Sets PcepAttribute.

+         *

+         * @param pcepAttribute PCEP-Attribute

+         * @return Builder by setting PCEP-Attribute.

+         */

+        Builder setPcepAttribute(PcepAttribute pcepAttribute);

+    }

+}

diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepNai.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepNai.java
new file mode 100755
index 0000000..196c513
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepNai.java
@@ -0,0 +1,40 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+

+/**

+ * Abstraction of an entity provides NAI information in SR ERO Object.

+ */

+public interface PcepNai {

+

+    /**

+     *  To get the ST type of the NAI information.

+     *

+     *  @return type of ST info

+     */

+    byte getType();

+

+    /**

+     *  To write the object information to channelBuffer.

+     *

+     *  @param cb of type channel buffer

+     *  @return length of written bytes.

+     */

+    int write(ChannelBuffer cb);

+}

diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepObject.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepObject.java
new file mode 100755
index 0000000..26dad56
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepObject.java
@@ -0,0 +1,30 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+/**
+ * Abstraction of an entity providing PCEP Object.
+ */
+public interface PcepObject extends Writeable {
+
+    /**
+     * Returns Version of PCEP Object.
+     *
+     * @return Version of PCEP Object
+     */
+    PcepVersion getVersion();
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepOpenMsg.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepOpenMsg.java
new file mode 100755
index 0000000..afa6c8b
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepOpenMsg.java
@@ -0,0 +1,73 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+
+/**
+ * Abstraction of an entity providing PCEP Open Message.
+ */
+public interface PcepOpenMsg extends PcepObject, PcepMessage {
+
+    @Override
+    PcepVersion getVersion();
+
+    @Override
+    PcepType getType();
+
+    /**
+     * Sets OpenObject in Open Message with Specified Obj.
+     *
+     * @param obj OpenObject
+     */
+    void setPcepOpenObject(PcepOpenObject obj);
+
+    /**
+     * Returns OpenObject in Open Message.
+     *
+     * @return OpenObject in Open Message
+     */
+    PcepOpenObject getPcepOpenObject();
+
+    @Override
+    void writeTo(ChannelBuffer channelBuffer);
+
+    /**
+     * Builder interface with get and set functions to build Open message.
+     */
+    public interface Builder extends PcepMessage.Builder {
+
+        @Override
+        PcepOpenMsg build() throws PcepParseException;
+
+        /**
+         * Sets Open Object in Open Message and return its builder.
+         *
+         * @param obj Open Object
+         * @return builder by setting Open Object
+         */
+        Builder setPcepOpenObj(PcepOpenObject obj);
+
+        /**
+         * Returns OpenObject in Open Message.
+         *
+         * @return OpenObject in Open Message
+         */
+        PcepOpenObject getPcepOpenObj();
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepOpenObject.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepOpenObject.java
new file mode 100755
index 0000000..49c8184
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepOpenObject.java
@@ -0,0 +1,226 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import java.util.LinkedList;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+import org.onosproject.pcepio.types.PcepObjectHeader;
+import org.onosproject.pcepio.types.PcepValueType;
+
+/**
+ * Abstraction of an entity providing PCEP Open Object.
+ */
+public interface PcepOpenObject {
+
+    /**
+     * Returns Open object header.
+     *
+     * @return Open object header
+     */
+    PcepObjectHeader getOpenObjHeader();
+
+    /**
+     * Sets Open object header in Open Object.
+     *
+     * @param obj Open object header
+     */
+    void setOpenObjHeader(PcepObjectHeader obj);
+
+    /**
+     * Returns version of Open Object.
+     *
+     * @return Version of Open Object
+     */
+    PcepVersion getVersion();
+
+    /**
+     * Returns KeepAlive Time in Open Object.
+     *
+     * @return KeepAlive Time in Open Object
+     */
+    byte getKeepAliveTime();
+
+    /**
+     * Sets KeepAlive Time in Open Object with specified value.
+     *
+     * @param value KeepAlive Time
+     */
+    void setKeepAliveTime(byte value);
+
+    /**
+     * Returns Dead Time in Open Object.
+     *
+     * @return Dead Time in Open Object
+     */
+    byte getDeadTime();
+
+    /**
+     * Sets Dead Time in Open Object with specified value.
+     *
+     * @param value Dead Time
+     */
+    void setDeadTime(byte value);
+
+    /**
+     * Returns SessionId in Open Object.
+     *
+     * @return SessionId in Open Object
+     */
+    byte getSessionId();
+
+    /**
+     * Sets SessionId in Open Object with specified value.
+     *
+     * @param value SessionId
+     */
+    void setSessionId(byte value);
+
+    /**
+     * Returns list of Optional Tlvs in Open Object.
+     *
+     * @return list of Optional Tlvs
+     */
+    LinkedList<PcepValueType> getOptionalTlv();
+
+    /**
+     * Sets list of Optional Tlvs in Open Object.
+     *
+     * @param llOptionalTlv list of Optional Tlvs
+     */
+    void setOptionalTlv(LinkedList<PcepValueType> llOptionalTlv);
+
+    /**
+     * Prints attributes of Open object.
+     */
+    void print();
+
+    /**
+     * Writes the Open into channel buffer.
+     *
+     * @param bb channel buffer
+     * @return Returns the writerIndex of this buffer
+     * @throws PcepParseException while writing Open Object into Channel Buffer.
+     */
+    int write(ChannelBuffer bb) throws PcepParseException;
+
+    /**
+     * Builder interface with get and set functions to build Open object.
+     */
+    public interface Builder {
+
+        /**
+         * Builds Open Object.
+         *
+         * @return Open Object
+         * @throws PcepParseException while building PCEP-Open object
+         */
+        PcepOpenObject build() throws PcepParseException;
+
+        /**
+         * Returns Open object header.
+         *
+         * @return Open object header
+         */
+        PcepObjectHeader getOpenObjHeader();
+
+        /**
+         * Sets Open object header and returns its builder.
+         *
+         * @param obj Open object header
+         * @return Builder by setting Open object header
+         */
+        Builder setOpenObjHeader(PcepObjectHeader obj);
+
+        /**
+         * Returns KeepAlive Time in Open Object.
+         *
+         * @return KeepAlive Time in Open Object
+         */
+        byte getKeepAliveTime();
+
+        /**
+         * Sets KeepAlive Time and returns its builder.
+         *
+         * @param value KeepAlive Time
+         * @return Builder by setting KeepAlive Time
+         */
+        Builder setKeepAliveTime(byte value);
+
+        /**
+         * Returns Dead Time in Open Object.
+         *
+         * @return Dead Time in Open Object
+         */
+        byte getDeadTime();
+
+        /**
+         * Sets Dead Time and returns its builder.
+         *
+         * @param value Dead Time
+         * @return Builder by setting Dead Time
+         */
+        Builder setDeadTime(byte value);
+
+        /**
+         * Returns SessionId in Open Object.
+         *
+         * @return SessionId in Open Object
+         */
+        byte getSessionId();
+
+        /**
+         * Sets SessionId and returns its builder.
+         *
+         * @param value SessionId
+         * @return Builder by setting SessionId
+         */
+        Builder setSessionId(byte value);
+
+        /**
+         * Returns list of Optional Tlvs in Open Object.
+         *
+         * @return list of Optional Tlvs in Open Object
+         */
+        LinkedList<PcepValueType> getOptionalTlv();
+
+        /**
+         * Sets list of Optional Tlvs and return its Builder.
+         *
+         * @param llOptionalTlv list of Optional Tlvs
+         * @return builder by setting list of Optional Tlvs
+         */
+        Builder setOptionalTlv(LinkedList<PcepValueType> llOptionalTlv);
+
+        /**
+         * Sets P flag in Open object header and returns its builder.
+         *
+         * @param value boolean value to set P flag
+         * @return Builder by setting P flag
+         */
+        Builder setPFlag(boolean value);
+
+        /**
+         * Sets I flag in Open object header and returns its builder.
+         *
+         * @param value boolean value to set I flag
+         * @return Builder by setting I flag
+         */
+        Builder setIFlag(boolean value);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepRPObject.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepRPObject.java
new file mode 100755
index 0000000..bdb69c3
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepRPObject.java
@@ -0,0 +1,261 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+import java.util.LinkedList;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+import org.onosproject.pcepio.types.PcepObjectHeader;

+import org.onosproject.pcepio.types.PcepValueType;

+

+/**

+ * Abstraction of an entity providing PCEP RP Object.

+ */

+public interface PcepRPObject {

+

+    /**

+     * Returns RequestId Number in RP Object.

+     *

+     * @return RequestId Number in RP Object

+     */

+    int getRequestIdNum();

+

+    /**

+     * Sets RequestId Number with specified value.

+     *

+     * @param value RequestId Number

+     */

+    void setRequestIdNum(int value);

+

+    /**

+     * Returns O flag in RP Object.

+     *

+     * @return O flag in RP Object

+     */

+    boolean getOFlag();

+

+    /**

+     * Sets O flag with specified value.

+     *

+     * @param value O flag

+     */

+    void setOFlag(boolean value);

+

+    /**

+     * Returns B flag in RP Object.

+     *

+     * @return B flag in RP Object

+     */

+    boolean getBFlag();

+

+    /**

+     * Sets B flag with specified value.

+     *

+     * @param value B flag

+     */

+    void setBFlag(boolean value);

+

+    /**

+     * Returns R flag in RP Object.

+     *

+     * @return R flag in RP Object

+     */

+    boolean getRFlag();

+

+    /**

+     * Sets R flag with specified value.

+     *

+     * @param value R flag

+     */

+    void setRFlag(boolean value);

+

+    /**

+     * Returns Priority Flag in RP Object.

+     *

+     * @return Priority Flag in RP Object

+     */

+    byte getPriFlag();

+

+    /**

+     * Sets Priority Flag with specified value.

+     *

+     * @param value Priority Flag

+     */

+    void setPriFlag(byte value);

+

+    /**

+     * Returns list of Optional Tlvs in RP Object.

+     *

+     * @return list of Optional Tlvs in RP Object

+     */

+    LinkedList<PcepValueType> getOptionalTlv();

+

+    /**

+     * Sets list of Optional Tlvs in RP Object and returns its builder.

+     *

+     * @param llOptionalTlv list of Optional Tlvs

+     */

+    void setOptionalTlv(LinkedList<PcepValueType> llOptionalTlv);

+

+    /**

+     * Prints attributes of RP object.

+     */

+    void print();

+

+    /**

+     * Writes the RP Object into channel buffer.

+     *

+     * @param bb channel buffer

+     * @return Returns the writerIndex of this buffer

+     * @throws PcepParseException while writing RP object into Channel Buffer.

+     */

+    int write(ChannelBuffer bb) throws PcepParseException;

+

+    /**

+     * Builder interface with get and set functions to build bandwidth object.

+     */

+    public interface Builder {

+

+        /**

+         * Builds RP Object.

+         *

+         * @return RP Object

+         */

+        PcepRPObject build();

+

+        /**

+         * Returns RP object header.

+         *

+         * @return RP object header

+         */

+        PcepObjectHeader getRPObjHeader();

+

+        /**

+         * Sets RP object header and returns its builder.

+         *

+         * @param obj RP object header

+         * @return Builder by setting RP object header

+         */

+        Builder setRPObjHeader(PcepObjectHeader obj);

+

+        /**

+         * Returns Request Id Number in RP Object.

+         *

+         * @return Request Id Number in RP Object

+         */

+        int getRequestIdNum();

+

+        /**

+         * Sets Request Id Number and returns its builder.

+         *

+         * @param value Request Id Number

+         * @return Builder by setting Request Id Number

+         */

+        Builder setRequestIdNum(int value);

+

+        /**

+         * Returns O flag in RP Object.

+         *

+         * @return O flag in RP Object

+         */

+        boolean getOFlag();

+

+        /**

+         * Sets O flag and returns its builder.

+         *

+         * @param value O flag

+         * @return Builder by setting O flag

+         */

+        Builder setOFlag(boolean value);

+

+        /**

+         * Returns B flag in RP Object.

+         *

+         * @return B flag in RP Object

+         */

+        boolean getBFlag();

+

+        /**

+         * Sets B flag and returns its builder.

+         *

+         * @param value B flag

+         * @return Builder by setting B flag

+         */

+        Builder setBFlag(boolean value);

+

+        /**

+         * Returns R flag in RP Object.

+         *

+         * @return R flag in RP Object

+         */

+        boolean getRFlag();

+

+        /**

+         * Sets R flag and returns its builder.

+         *

+         * @param value R flag

+         * @return Builder by setting R flag

+         */

+        Builder setRFlag(boolean value);

+

+        /**

+         * Returns Priority Flag in RP Object.

+         *

+         * @return Priority Flag in RP Object

+         */

+        byte getPriFlag();

+

+        /**

+         * Sets Priority Flag and returns its builder.

+         *

+         * @param value Priority Flag

+         * @return Builder by setting Priority Flag

+         */

+        Builder setPriFlag(byte value);

+

+        /**

+         * Returns list of Optional Tlvs in RP Object.

+         *

+         * @return list of Optional Tlvs

+         */

+        LinkedList<PcepValueType> getOptionalTlv();

+

+        /**

+         * Sets list of Optional Tlvs and returns its builder.

+         *

+         * @param llOptionalTlv list of Optional Tlvs

+         * @return Builder by setting list of Optional Tlvs

+         */

+        Builder setOptionalTlv(LinkedList<PcepValueType> llOptionalTlv);

+

+        /**

+         * Sets P flag in RP object header and returns its builder.

+         *

+         * @param value boolean value to set P flag

+         * @return Builder by setting P flag

+         */

+        Builder setPFlag(boolean value);

+

+        /**

+         * Sets I flag in RP object header and returns its builder.

+         *

+         * @param value boolean value to set I flag

+         * @return Builder by setting I flag

+         */

+        Builder setIFlag(boolean value);

+    }

+}

diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepReportMsg.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepReportMsg.java
new file mode 100755
index 0000000..ed9d71f
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepReportMsg.java
@@ -0,0 +1,81 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import java.util.LinkedList;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+
+/**
+ * Abstraction of an entity providing PCEP Report Message.
+ */
+public interface PcepReportMsg extends PcepObject, PcepMessage {
+
+    @Override
+    PcepVersion getVersion();
+
+    @Override
+    PcepType getType();
+
+    /**
+     * Returns PcepStateReport list.
+     *
+     * @return list of PcepStateReport
+     */
+    LinkedList<PcepStateReport> getStateReportList();
+
+    /**
+     * Sets StateReportList.
+     *
+     * @param llStateReportList list of PcepStateReport.
+     */
+    void setStateReportList(LinkedList<PcepStateReport> llStateReportList);
+
+    @Override
+    void writeTo(ChannelBuffer channelBuffer) throws PcepParseException;
+
+    /**
+     * Builder interface with get and set functions to build Report message.
+     */
+    public interface Builder extends PcepMessage.Builder {
+
+        @Override
+        PcepReportMsg build();
+
+        @Override
+        PcepVersion getVersion();
+
+        @Override
+        PcepType getType();
+
+        /**
+         * Returns StateReportList.
+         *
+         * @return StateReportList.
+         */
+        LinkedList<PcepStateReport> getStateReportList();
+
+        /**
+         * Sets list of PcepStateReport and returns builder.
+         *
+         * @param llStateReportList list of PcepStateReport.
+         * @return Builder by setting list of PcepStateReport.
+         */
+        Builder setStateReportList(LinkedList<PcepStateReport> llStateReportList);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepRroObject.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepRroObject.java
new file mode 100755
index 0000000..a2d725e
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepRroObject.java
@@ -0,0 +1,116 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+import java.util.LinkedList;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+import org.onosproject.pcepio.types.PcepObjectHeader;

+import org.onosproject.pcepio.types.PcepValueType;

+

+/**

+ * Abstraction of an entity providing PCEP RRO Object.

+ */

+public interface PcepRroObject {

+

+    /**

+     * Returns list of SubObjects.

+     *

+     * @return list of SubObjects

+     */

+    LinkedList<PcepValueType> getSubObjects();

+

+    /**

+     * Sets list of SubObjects and return its builder.

+     *

+     * @param llSubObjects list of SubObjects

+     */

+    void setSubObjects(LinkedList<PcepValueType> llSubObjects);

+

+    /**

+     * Prints attributes of RRO object.

+     */

+    void print();

+

+    /**

+     * Writes the RRO Object into channel buffer.

+     *

+     * @param bb channel buffer

+     * @return Returns the writerIndex of this buffer

+     * @throws PcepParseException when object header failed to write in channel buffer

+     */

+    public int write(ChannelBuffer bb) throws PcepParseException;

+

+    /**

+     * Builder interface with get and set functions to build RRO object.

+     */

+    public interface Builder {

+

+        /**

+         * Builds RRO Object.

+         *

+         * @return RRO Object

+         */

+        PcepRroObject build();

+

+        /**

+         * Returns RRO object header.

+         *

+         * @return RRO object header

+         */

+        PcepObjectHeader getRroObjHeader();

+

+        /**

+         * Sets RRO object header and returns its builder.

+         *

+         * @param obj RRO object header

+         * @return Builder by setting RRO object header

+         */

+        Builder setRroObjHeader(PcepObjectHeader obj);

+

+        /**

+         * Returns list of SubObjects.

+         *

+         * @return list of SubObjects

+         */

+        LinkedList<PcepValueType> getSubObjects();

+

+        /**

+         * Sets list of SubObjects in RRO Object and returns its builder.

+         *

+         * @param llSubObjects list of SubObjects

+         * @return Builder by setting list of SubObjects

+         */

+        Builder setSubObjects(LinkedList<PcepValueType> llSubObjects);

+

+        /**

+         * Sets P flag in RRO object header and returns its builder.

+         *

+         * @param value boolean value to set P flag

+         * @return Builder by setting P flag

+         */

+        Builder setPFlag(boolean value);

+

+        /**

+         * Sets I flag in RRO object header and returns its builder.

+         *

+         * @param value boolean value to set I flag

+         * @return Builder by setting I flag

+         */

+        Builder setIFlag(boolean value);

+    }

+}
\ No newline at end of file
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepSrpObject.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepSrpObject.java
new file mode 100755
index 0000000..0080d02
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepSrpObject.java
@@ -0,0 +1,177 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import java.util.LinkedList;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+import org.onosproject.pcepio.types.PcepObjectHeader;
+import org.onosproject.pcepio.types.PcepValueType;
+
+/**
+ * Abstraction of an entity providing PCEP SRP Object.
+ */
+public interface PcepSrpObject {
+
+    /**
+     * Returns SRP ID of SRP Object.
+     *
+     * @return SRP ID of SRP Object
+     */
+    int getSrpID();
+
+    /**
+     * Sets SRP ID with specified value.
+     *
+     * @param srpID SRP ID of SRP Object
+     */
+    void setSrpID(int srpID);
+
+    /**
+     * Returns R flag of SRP Object.
+     *
+     * @return R flag of SRP Object
+     */
+    boolean getRFlag();
+
+    /**
+     * Sets R flag with specified value.
+     *
+     * @param bRFlag R Flag of SRP Object
+     */
+    void setRFlag(boolean bRFlag);
+
+    /**
+     * sets the optional TLvs.
+     *
+     * @param llOptionalTlv list of optional tlvs
+     */
+    public void setOptionalTlv(LinkedList<PcepValueType> llOptionalTlv);
+
+    /**
+     * Returns list of optional tlvs.
+     *
+     * @return llOptionalTlv list of optional tlvs
+     */
+    public LinkedList<PcepValueType> getOptionalTlv();
+
+    /**
+     * Prints attributes of SRP object.
+     */
+    void print();
+
+    /**
+     * Writes the SRP Object into channel buffer.
+     *
+     * @param bb channel buffer
+     * @return Returns the writerIndex of this buffer
+     * @throws PcepParseException when tlv is null
+     */
+    int write(ChannelBuffer bb) throws PcepParseException;
+
+    /**
+     * Builder interface with get and set functions to build SRP object.
+     */
+    public interface Builder {
+
+        /**
+         * Builds SRP Object.
+         *
+         * @return SRP Object
+         * @throws PcepParseException when mandatory object is not set
+         */
+        PcepSrpObject build() throws PcepParseException;
+
+        /**
+         * Returns SRP object header.
+         *
+         * @return SRP object header
+         */
+        PcepObjectHeader getSrpObjHeader();
+
+        /**
+         * Sets SRP object header and returns its builder.
+         *
+         * @param obj SRP object header
+         * @return Builder by setting SRP object header
+         */
+        Builder setSrpObjHeader(PcepObjectHeader obj);
+
+        /**
+         * Returns SRP ID of SRP Object.
+         *
+         * @return SRP ID of SRP Object
+         */
+        int getSrpID();
+
+        /**
+         * Sets SRP ID and returns its builder.
+         *
+         * @param srpID SRP ID
+         * @return Builder by setting SRP ID
+         */
+        Builder setSrpID(int srpID);
+
+        /**
+         * Returns R flag of SRP Object.
+         *
+         * @return R flag of SRP Object
+         */
+        boolean getRFlag();
+
+        /**
+         * Sets R flag and returns its builder.
+         *
+         * @param bRFlag R flag
+         * @return Builder by setting R flag
+         */
+        Builder setRFlag(boolean bRFlag);
+
+        /**
+         * Returns list of optional tlvs.
+         *
+         * @return llOptionalTlv list of optional tlvs
+         */
+        public LinkedList<PcepValueType> getOptionalTlv();
+
+        /**
+         * sets the optional TLvs.
+         *
+         * @param llOptionalTlv List of optional tlv
+         * @return builder by setting list of optional tlv.
+         */
+        public Builder setOptionalTlv(LinkedList<PcepValueType> llOptionalTlv);
+
+        /**
+         * Sets P flag in SRP object header and returns its builder.
+         *
+         * @param value boolean value to set P flag
+         * @return Builder by setting P flag
+         */
+        Builder setPFlag(boolean value);
+
+        /**
+         * Sets I flag in SRP object header and returns its builder.
+         *
+         * @param value boolean value to set I flag
+         * @return Builder by setting I flag
+         */
+        Builder setIFlag(boolean value);
+
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepStateReport.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepStateReport.java
new file mode 100755
index 0000000..5a0bce4
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepStateReport.java
@@ -0,0 +1,218 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+

+/**

+ * Abstraction of an entity provides State Report for PCEP Report Message.

+ */

+public interface PcepStateReport {

+

+    /**

+     * Provides PCEP Message path for report message.

+     */

+    public interface PcepMsgPath {

+

+        /**

+         * Returns PcepEroObject.

+         *

+         * @return eroObj

+         */

+        PcepEroObject getEroObject();

+

+        /**

+         * Sets PcepEroObject.

+         *

+         * @param eroObject Ero Object

+         */

+        void setEroObject(PcepEroObject eroObject);

+

+        /**

+         * Returns PcepAttribute.

+         *

+         * @return attrList

+         */

+        PcepAttribute getPcepAttribute();

+

+        /**

+         * Sets PcepAttribute.

+         *

+         * @param pcepAttribute Pcep Attribute object

+         */

+        void setPcepAttribute(PcepAttribute pcepAttribute);

+

+        /**

+         * Returns PcepRroObject.

+         *

+         * @return rroObj

+         */

+        PcepRroObject getRroObject();

+

+        /**

+         * Sets PcepRroObject.

+         *

+         * @param rroObject Rro object

+         */

+        void setRroObject(PcepRroObject rroObject);

+

+        /**

+         * Returns PcepBandwidthObject.

+         *

+         * @return bandwidth object

+         */

+        PcepBandwidthObject getBandwidthObject();

+

+        /**

+         * Sets PcepBandwidthObject.

+         *

+         * @param bandwidth bandwidth object

+         */

+        void setBandwidthObject(PcepBandwidthObject bandwidth);

+

+        /**

+         * Reads all the Objects for PCEP Message Path.

+         *

+         * @param bb of type channel buffer

+         * @return PCEP Message path

+         * @throws PcepParseException when invalid buffer received

+         */

+        public PcepMsgPath read(ChannelBuffer bb) throws PcepParseException;

+

+        /**

+         * Writes all the objects for pcep message path.

+         *

+         * @param bb of type channel buffer.

+         * @return object length index

+         * @throws PcepParseException when mandatory object is not set

+         */

+        public int write(ChannelBuffer bb) throws PcepParseException;

+

+        /***

+         * Prints the attribute of PCEP Message Path.

+         */

+        public void print();

+

+    }

+

+    /**

+     * Returns PcepSrpObject.

+     *

+     * @return srpObject

+     */

+    PcepSrpObject getSrpObject();

+

+    /**

+     * Returns PcepLspObject.

+     *

+     * @return lspObject

+     */

+    PcepLspObject getLspObject();

+

+    /**

+     * Returns PcepMsgPath.

+     *

+     * @return msgPath

+     */

+    PcepMsgPath getMsgPath();

+

+    /**

+     * Sets the SRP Object.

+     *

+     * @param srpObj Pcep Srp Object

+     */

+    void setSrpObject(PcepSrpObject srpObj);

+

+    /**

+     * Sets the LSP Object.

+     *

+     * @param lspObject Pcep Lsp Object

+     */

+    void setLspObject(PcepLspObject lspObject);

+

+    /**

+     * Sets the Path Object.

+     *

+     * @param msgPath Pcep MsgPath object

+     */

+    void setMsgPath(PcepMsgPath msgPath);

+

+    /**

+     * Prints the attribute of PCEP state report.

+     */

+    public void print();

+

+    /**

+     * Builder interface with get and set functions to build PcepStateReport.

+     */

+    public interface Builder {

+

+        /**

+         * Builds PcepStateReport.

+         *

+         * @return PcepStateReport

+         * @throws PcepParseException when mandatory object is not set

+         */

+        PcepStateReport build() throws PcepParseException;

+

+        /**

+         * Returns PcepSrpObject.

+         *

+         * @return srpObject

+         */

+        PcepSrpObject getSrpObject();

+

+        /**

+         * Returns PcepLspObject.

+         *

+         * @return lspObject

+         */

+        PcepLspObject getLspObject();

+

+        /**

+         * Returns PcepMsgPath.

+         *

+         * @return msgPath

+         */

+        PcepMsgPath getMsgPath();

+

+        /**

+         * Sets the SRP Object.

+         *

+         * @param srpObj Pcep Srp Object

+         * @return builder by setting PcepSrpObject

+         */

+        Builder setSrpObject(PcepSrpObject srpObj);

+

+        /**

+         * Sets the LSP Object.

+         *

+         * @param lspObject Pcep Lsp Object

+         * @return builder by setting PcepLspObject

+         */

+        Builder setLspObject(PcepLspObject lspObject);

+

+        /**

+         * Sets the Path Object.

+         *

+         * @param msgPath Pcep MsgPath object

+         * @return builder by setting PcepMsgPath

+         */

+        Builder setMsgPath(PcepMsgPath msgPath);

+    }

+}

diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepTEObject.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepTEObject.java
new file mode 100755
index 0000000..7b40dfe
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepTEObject.java
@@ -0,0 +1,246 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+import java.util.LinkedList;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+import org.onosproject.pcepio.types.PcepObjectHeader;

+import org.onosproject.pcepio.types.PcepValueType;

+

+/**

+ * Abstraction of an entity providing PCEP TE Object.

+ */

+public interface PcepTEObject {

+

+    /**

+     * Returns TE object header.

+     *

+     * @return TE object header

+     */

+    PcepObjectHeader getTEObjHeader();

+

+    /**

+     * Sets TE Object header.

+     *

+     * @param obj TE Object header

+     */

+    void setTEObjHeader(PcepObjectHeader obj);

+

+    /**

+     * Returns ProtocolId in TE Object.

+     *

+     * @return ProtocolId in TE Object

+     */

+    byte getProtocolId();

+

+    /**

+     * Sets ProtocolId in TE Object.

+     *

+     * @param yProtId ProtocolId in TE Object

+     */

+    void setProtocolId(byte yProtId);

+

+    /**

+     * Returns R flag in TE Object.

+     *

+     * @return R flag in TE Object

+     */

+    boolean getRFlag();

+

+    /**

+     * Sets R flag in TE Object.

+     *

+     * @param bRFlag R flag in TE Object

+     */

+    void setRFlag(boolean bRFlag);

+

+    /**

+     * Returns S flag in TE Object.

+     *

+     * @return S flag in TE Object

+     */

+    boolean getSFlag();

+

+    /**

+     * Sets S flag in TE Object.

+     *

+     * @param bSFlag S flag in TE Object

+     */

+    void setSFlag(boolean bSFlag);

+

+    /**

+     * Returns TE ID in TE Object.

+     *

+     * @return TE ID in TE Object

+     */

+    int getTEId();

+

+    /**

+     * Sets TE ID in TE Object.

+     *

+     * @param iTEId TE ID in TE Object

+     */

+    void setTEId(int iTEId);

+

+    /**

+     * Returns list of Optional Tlvs in TE Object.

+     *

+     * @return list of Optional Tlvs

+     */

+    LinkedList<PcepValueType> getOptionalTlv();

+

+    /**

+     * Sets list of Optional Tlvs in TE Object.

+     *

+     * @param llOptionalTlv list of Optional Tlvs

+     */

+    void setOptionalTlv(LinkedList<PcepValueType> llOptionalTlv);

+

+    /**

+     * Prints attributes of TE object.

+     */

+    void print();

+

+    /**

+     * Writes the TE Object into channel buffer.

+     *

+     * @param bb channel buffer

+     * @return Returns the writerIndex of this buffer

+     * @throws PcepParseException when obj header is not written to channel buffer

+     */

+    public int write(ChannelBuffer bb) throws PcepParseException;

+

+    /**

+     * Builder interface with get and set functions to build TE object.

+     */

+    public interface Builder {

+

+        /**

+         * Builds TE Object.

+         *

+         * @return TE Object

+         */

+        PcepTEObject build();

+

+        /**

+         * Returns TE object header.

+         *

+         * @return TE object header

+         */

+        PcepObjectHeader getTEObjHeader();

+

+        /**

+         * Sets TE object header and returns its builder.

+         *

+         * @param obj TE object header

+         * @return Builder by setting TE object header

+         */

+        Builder setTEObjHeader(PcepObjectHeader obj);

+

+        /**

+         * Returns ProtocolId in TE Object.

+         *

+         * @return ProtocolId in TE Object

+         */

+        byte getProtocolId();

+

+        /**

+         * Sets ProtocolId in TE Object and returns its builder.

+         *

+         * @param yProtId ProtocolId in TE Object

+         * @return Builder by setting ProtocolId

+         */

+        Builder setProtocolId(byte yProtId);

+

+        /**

+         * Returns R flag in TE Object.

+         *

+         * @return R flag in TE Object

+         */

+        boolean getRFlag();

+

+        /**

+         * Sets R flag in TE Object and returns its builder.

+         *

+         * @param bRFlag R flag in TE Object

+         * @return Builder by setting R flag

+         */

+        Builder setRFlag(boolean bRFlag);

+

+        /**

+         * Returns S flag in TE Object.

+         *

+         * @return S flag in TE Object

+         */

+        boolean getSFlag();

+

+        /**

+         * Sets S flag in TE Object and returns its builder.

+         *

+         * @param bSFlag S flag in TE Object

+         * @return Builder by setting S flag

+         */

+        Builder setSFlag(boolean bSFlag);

+

+        /**

+         * Returns TE ID in TE Object.

+         *

+         * @return TE ID in TE Object

+         */

+        int getTEId();

+

+        /**

+         * Sets TE ID in TE Object and returns its builder.

+         *

+         * @param iTEId TE ID in TE Object

+         * @return Builder by setting TE ID

+         */

+        Builder setTEId(int iTEId);

+

+        /**

+         * Returns list of Optional Tlvs in TE Object.

+         *

+         * @return list of Optional Tlvs

+         */

+        LinkedList<PcepValueType> getOptionalTlv();

+

+        /**

+         * Sets list of Optional Tlvs in TE Object and returns its builder.

+         *

+         * @param llOptionalTlv list of Optional Tlvs

+         * @return Builder by setting list of Optional Tlvs

+         */

+        Builder setOptionalTlv(LinkedList<PcepValueType> llOptionalTlv);

+

+        /**

+         * Sets P flag in TE object header and returns its builder.

+         *

+         * @param value boolean value to set P flag

+         * @return Builder by setting P flag

+         */

+        Builder setPFlag(boolean value);

+

+        /**

+         * Sets I flag in TE object header and returns its builder.

+         *

+         * @param value boolean value to set I flag

+         * @return Builder by setting I flag

+         */

+        Builder setIFlag(boolean value);

+    }

+}
\ No newline at end of file
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepTEReportMsg.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepTEReportMsg.java
new file mode 100755
index 0000000..bcdd011
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepTEReportMsg.java
@@ -0,0 +1,81 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import java.util.LinkedList;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+
+/**
+ * Abstraction of an entity providing PCEP TE Report Message.
+ */
+public interface PcepTEReportMsg extends PcepObject, PcepMessage {
+
+    @Override
+    PcepVersion getVersion();
+
+    @Override
+    PcepType getType();
+
+    /**
+     * Returns list of PCEP TE Objects.
+     *
+     * @return list of PCEP TE Objects
+     */
+    LinkedList<PcepTEObject> getTEReportList();
+
+    /**
+     * Sets list of Optional Tlvs in TE Report Message.
+     *
+     * @param llTEReportList list of optional Tlvs
+     */
+    void setTEReportList(LinkedList<PcepTEObject> llTEReportList);
+
+    @Override
+    void writeTo(ChannelBuffer channelBuffer) throws PcepParseException;
+
+    /**
+     * Builder interface with get and set functions to build TE Report message.
+     */
+    public interface Builder extends PcepMessage.Builder {
+
+        @Override
+        PcepTEReportMsg build();
+
+        @Override
+        PcepVersion getVersion();
+
+        @Override
+        PcepType getType();
+
+        /**
+         * Returns list of Optional Tlv in TE Report Message.
+         *
+         * @return list of Optional Tlv
+         */
+        LinkedList<PcepTEObject> getTEReportList();
+
+        /**
+         * Sets list of Optional Tlvs and returns its builder.
+         *
+         * @param llTEReportList list of Optional Tlvs
+         * @return Builder object for TE report message
+         */
+        Builder setTEReportList(LinkedList<PcepTEObject> llTEReportList);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepType.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepType.java
new file mode 100755
index 0000000..450fdfa
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepType.java
@@ -0,0 +1,49 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+/**
+ * Enum to Provide the Different types of PCEP messages.
+ */
+public enum PcepType {
+
+    NONE(0), OPEN(1), KEEP_ALIVE(2), PATH_COMPUTATION_REQUEST(3), PATH_COMPUTATION_REPLY(4),
+    NOTIFICATION(5), ERROR(6), CLOSE(7), REPORT(10), UPDATE(11), INITIATE(12), LABEL_UPDATE(13),
+    TE_REPORT(14), LABEL_RANGE_RESERV(15), MAX(16), END(17);
+
+    int iValue;
+
+    /**
+     * Assign iValue with the value iVal as the types of PCEP message.
+     *
+     * @param iVal type of pcep message
+     */
+    PcepType(int iVal) {
+
+        iValue = iVal;
+    }
+
+    /**
+     * Returns iValue as type of PCEP message.
+     *
+     * @return iValue type of pcep message
+     */
+    public byte getType() {
+
+        return (byte) iValue;
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepUpdateMsg.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepUpdateMsg.java
new file mode 100755
index 0000000..6297f3c
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepUpdateMsg.java
@@ -0,0 +1,81 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import java.util.LinkedList;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+
+/**
+ * Abstraction of an entity providing PCEP Update Message.
+ */
+public interface PcepUpdateMsg extends PcepObject, PcepMessage {
+
+    @Override
+    PcepVersion getVersion();
+
+    @Override
+    PcepType getType();
+
+    /**
+     * Returns the update request list for PCEP Update Message.
+     *
+     * @return list of Update Requests
+     */
+    LinkedList<PcepUpdateRequest> getUpdateRequestList();
+
+    /**
+     * Sets the update request list for PCEP update message.
+     *
+     * @param llUpdateRequestList is a list of PCEP Update Requests
+     */
+    void setUpdateRequestList(LinkedList<PcepUpdateRequest> llUpdateRequestList);
+
+    @Override
+    void writeTo(ChannelBuffer channelBuffer) throws PcepParseException;
+
+    /**
+     * Builder interface with Get and Set Functions to build the PCEP update Message.
+     */
+    public interface Builder extends PcepMessage.Builder {
+
+        @Override
+        PcepUpdateMsg build();
+
+        @Override
+        PcepVersion getVersion();
+
+        @Override
+        PcepType getType();
+
+        /**
+         * Returns the update request list for the PCEP update message.
+         *
+         * @return list of Update Requests
+         */
+        LinkedList<PcepUpdateRequest> getUpdateRequestList();
+
+        /**
+         * Sets the  update request list for the PCEP update message.
+         *
+         * @param llUpdateRequestList list of Update requests
+         * @return builder by setting list llUpdateRequestList of PcepUpdateRequest.
+         */
+        Builder setUpdateRequestList(LinkedList<PcepUpdateRequest> llUpdateRequestList);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepUpdateRequest.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepUpdateRequest.java
new file mode 100755
index 0000000..0f360fa
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepUpdateRequest.java
@@ -0,0 +1,132 @@
+/*

+ * Copyright 2015 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.pcepio.protocol;

+

+import org.onosproject.pcepio.exceptions.PcepParseException;

+

+

+/**

+ * Abstraction of an entity providing PCEP Update Request List.

+ */

+public interface PcepUpdateRequest {

+

+    /**

+     * Returns object of PCEP SRP Object.

+     *

+     * @return srpObject of type PCEP SRP Object

+     */

+    PcepSrpObject getSrpObject();

+

+    /**

+     * Returns object of PCEP LSP Object.

+     *

+     * @return lspObject of type PCEP LSP Object

+     */

+    PcepLspObject getLspObject();

+

+    /**

+     * Returns object of PCEP MSG PATH.

+     *

+     * @return msgPath of type PCEP MSG PATH

+     */

+    PcepMsgPath getMsgPath();

+

+    /**

+     * Sets the PCEP SRP Object.

+     *

+     * @param srpObject object of type PCEP SRP Object

+     */

+    void setSrpObject(PcepSrpObject srpObject);

+

+    /**

+     * Sets the PCEP LSP Object.

+     *

+     * @param lspObject object of type PCEP LSP Object

+     */

+    void setLspObject(PcepLspObject lspObject);

+

+    /**

+     * sets the PCEP MSG PATH.

+     *

+     * @param msgPath object of type PCEP MSG PATH

+     */

+    void setMsgPath(PcepMsgPath msgPath);

+

+    /**

+     * Prints the attributes of PCEP Update Request.

+     */

+    public void print();

+

+    /**

+     * Builder interface with get and set functions to build PcepUpdateRequest.

+     */

+    public interface Builder {

+

+        /**

+         * Builds PcepUpdateRequest.

+         *

+         * @return PcepUpdateRequest

+         * @throws PcepParseException if mandatory object is not set

+         */

+        PcepUpdateRequest build() throws PcepParseException;

+

+        /**

+         * Returns PcepSrpObject.

+         *

+         * @return srpObject

+         */

+        PcepSrpObject getSrpObject();

+

+        /**

+         * Returns PcepLspObject.

+         *

+         * @return lspObject

+         */

+        PcepLspObject getLspObject();

+

+        /**

+         * Returns PcepMsgPath.

+         *

+         * @return msgPath

+         */

+        PcepMsgPath getMsgPath();

+

+        /**

+         * Sets the SRP Object.

+         *

+         * @param srpObj of type PcepSrpObject

+         * @return builder by setting PcepSrpObject

+         */

+        Builder setSrpObject(PcepSrpObject srpObj);

+

+        /**

+         * Sets the LSP Object.

+         *

+         * @param lspObject of type PcepLspObject

+         * @return builder by setting PcepLspObject

+         */

+        Builder setLspObject(PcepLspObject lspObject);

+

+        /**

+         * Sets the Path Object.

+         *

+         * @param msgPath of type PcepMsgPath

+         * @return builder by setting PcepMsgPath

+         */

+        Builder setMsgPath(PcepMsgPath msgPath);

+    }

+}
\ No newline at end of file
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepVersion.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepVersion.java
new file mode 100755
index 0000000..c761ed0
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/PcepVersion.java
@@ -0,0 +1,46 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+/**
+ * Enum to provide PCEP Message Version.
+ */
+public enum PcepVersion {
+
+    PCEP_1(1);
+
+    public final int packetVersion;
+
+    /**
+     * Assign PCEP PacketVersion with WireVersion.
+     *
+     * @param wireVersion version of pcep
+     */
+    PcepVersion(final int wireVersion) {
+
+        this.packetVersion = wireVersion;
+    }
+
+    /**
+     * Returns Wire version of PCEP Message.
+     *
+     * @return packetVersion
+     */
+    public int getWireVersion() {
+        return packetVersion;
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/Writeable.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/Writeable.java
new file mode 100755
index 0000000..37aef58
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/protocol/Writeable.java
@@ -0,0 +1,35 @@
+/*
+ * Copyright 2015 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.pcepio.protocol;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.exceptions.PcepParseException;
+
+/**
+ * Abstraction of an entity providing functionality to write byte streams of
+ * Messages to channel buffer.
+ */
+public interface Writeable {
+
+    /**
+     * Writes byte streams of messages to channel buffer.
+     *
+     * @param bb parameter of type channel buffer
+     * @throws PcepParseException when error occurs while writing pcep message to channel buffer
+     */
+    void writeTo(ChannelBuffer bb) throws PcepParseException;
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/ErrorObjListWithOpen.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/ErrorObjListWithOpen.java
new file mode 100755
index 0000000..d76dc96
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/ErrorObjListWithOpen.java
@@ -0,0 +1,140 @@
+package org.onosproject.pcepio.types;

+

+import java.util.LinkedList;

+import java.util.ListIterator;

+

+import org.jboss.netty.buffer.ChannelBuffer;

+import org.onosproject.pcepio.exceptions.PcepParseException;

+import org.onosproject.pcepio.protocol.PcepErrorObject;

+import org.onosproject.pcepio.protocol.PcepOpenObject;

+import org.slf4j.Logger;

+import org.slf4j.LoggerFactory;

+

+/*

+ * Provide the error object list with open object.

+ */

+public class ErrorObjListWithOpen {

+    //errorObjList is mandatory

+    LinkedList<PcepErrorObject> llerrorObjList;

+    // openObject is optional

+    PcepOpenObject openObject;

+    // flag to check if open object is set or not

+    public boolean isOpenObjectSet;

+    protected static final Logger log = LoggerFactory.getLogger(ErrorObjListWithOpen.class);

+

+    /*

+     * constructor to initialize errObj,openObj.

+     *

+     * @param errObj error object list

+     * @param openObj open object

+     */

+    public ErrorObjListWithOpen(LinkedList<PcepErrorObject> errObj, PcepOpenObject openObj) {

+        this.llerrorObjList = errObj;

+        this.openObject = openObj;

+        if (openObj != null) {

+            isOpenObjectSet = true;

+        } else {

+            isOpenObjectSet = false;

+        }

+    }

+

+    /*

+     * constructor to initialize errObj.

+     *

+     * @param errObj error object list

+     */

+    public ErrorObjListWithOpen(LinkedList<PcepErrorObject> errObj) {

+        this.llerrorObjList = errObj;

+        this.openObject = null;

+        isOpenObjectSet = false;

+    }

+

+    public LinkedList<Integer> getErrorType() {

+        LinkedList<Integer> errorType = new LinkedList<Integer>();

+        if (llerrorObjList != null) {

+            ListIterator<PcepErrorObject> errObjListIterator = llerrorObjList.listIterator();

+            int error;

+            PcepErrorObject errorObj;

+            while (errObjListIterator.hasNext()) {

+                errorObj =  errObjListIterator.next();

+                error = errorObj.getErrorType();

+                errorType.add(error);

+            }

+        }

+        return errorType;

+    }

+

+    public LinkedList<Integer> getErrorValue() {

+        LinkedList<Integer> errorValue = new LinkedList<Integer>();

+        if (llerrorObjList != null) {

+            ListIterator<PcepErrorObject> errObjListIterator = llerrorObjList.listIterator();

+            int error;

+            PcepErrorObject errorObj;

+            while (errObjListIterator.hasNext()) {

+                errorObj =  errObjListIterator.next();

+                error = errorObj.getErrorValue();

+                errorValue.add(error);

+

+            }

+        }

+        return errorValue;

+    }

+    /*

+     * Checks whether error object list is empty or not.

+     *

+     * @return whether error object list is empty or not

+     */

+    public boolean isErrorObjListWithOpenPresent() {

+        // ( <error-obj-list> [<Open>]

+        // At least in this case <error-obj-list> should be present.

+        return (!this.llerrorObjList.isEmpty()) ? true : false;

+    }

+

+    /*

+     * Write Error Object List and Open Object to channel buffer.

+     *

+     * @param bb of type channel buffer

+     * @throws PcepParseException when mandatory fields are not set

+     */

+    public int write(ChannelBuffer bb) throws PcepParseException {

+        int iLenStartIndex = bb.writerIndex();

+        boolean bIsErrObjListFound = false;

+

+        //<error-obj-list> is mandatory , if not present throw exception.

+        if (llerrorObjList != null) {

+            ListIterator<PcepErrorObject> errObjListIterator = llerrorObjList.listIterator();

+            while (errObjListIterator.hasNext()) {

+                errObjListIterator.next().write(bb);

+                bIsErrObjListFound = true;

+            }

+        }

+

+        if (!bIsErrObjListFound) {

+            throw new PcepParseException("Error: [ErrorObjListWithOpen::write] <error-obj-list> is mandatory.");

+        }

+

+        //Open Object is optional , if present write.

+        if (openObject != null) {

+            openObject.write(bb);

+        }

+

+        return bb.writerIndex() - iLenStartIndex;

+    }

+

+    /*

+     * Prints the attributes of ErrorObject List with open Object.

+     */

+    public void print() {

+        log.debug("ErrorObjListWithOpen:");

+        ListIterator<PcepErrorObject> pcepErrorObjIterator = llerrorObjList.listIterator();

+        log.debug("<error-obj-list> :");

+        while (pcepErrorObjIterator.hasNext()) {

+            pcepErrorObjIterator.next().print();

+        }

+

+        log.debug("OpenObject:");

+        if (openObject != null) {

+            openObject.print();

+        }

+    }

+}

diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/PcepLabelDownload.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/PcepLabelDownload.java
new file mode 100755
index 0000000..12f39f9
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/PcepLabelDownload.java
@@ -0,0 +1,95 @@
+package org.onosproject.pcepio.types;

+

+import java.util.LinkedList;

+import java.util.ListIterator;

+

+import org.onosproject.pcepio.protocol.PcepLabelObject;

+import org.onosproject.pcepio.protocol.PcepLspObject;

+import org.onosproject.pcepio.protocol.PcepSrpObject;

+import org.slf4j.Logger;

+import org.slf4j.LoggerFactory;

+

+/*

+ * Provides Pcep Label.

+ * REference :draft-zhao-pce-pcep-extension-for-pce-controller-01.

+ */

+public class PcepLabelDownload {

+

+    protected static final Logger log = LoggerFactory.getLogger(PcepLabelDownload.class);

+

+    //PCEP SPR Object

+    PcepSrpObject srpObject;

+    //PCEP LSP Object

+    PcepLspObject lspObject;

+    //LinkList of Labels

+    LinkedList<PcepLabelObject> llLabelList;

+

+    /*

+     * Returns SRP Object.

+     *

+     * @return PCEP SRP Object

+     */

+    public PcepSrpObject getSrpObject() {

+        return srpObject;

+    }

+

+    /*

+     * Sets the Pcep Srp Object.

+     *

+     * @param srpobj PCEP SRP Object

+     */

+    public void setSrpObject(PcepSrpObject srpobj) {

+        this.srpObject = srpobj;

+    }

+

+    /*

+     * Returns LSP Object.

+     *

+     * @return PCEP LSP Object

+     */

+    public PcepLspObject getLspObject() {

+        return lspObject;

+    }

+

+    /*

+     * Sets the Pcep LSP Object.

+     *

+     * @param lspObject PCEP LSP Object

+     */

+    public void setLspObject(PcepLspObject lspObject) {

+        this.lspObject = lspObject;

+    }

+

+    /*

+     * Returns a list of labels.

+     *

+     * @return llLabelList list of pcep label objects

+     */

+    public LinkedList<PcepLabelObject> getLabelList() {

+        return llLabelList;

+    }

+

+    /*

+     * set the llLabelList list of type PcepLableObject.

+     *

+     * @param llLabelList list of pcep label objects

+     */

+    public void setLabelList(LinkedList<PcepLabelObject> llLabelList) {

+        this.llLabelList = llLabelList;

+    }

+

+    /*

+     * Prints the attribute of PcepLableObject.

+     */

+    public void print() {

+        log.debug("LABEL DOWNLOAD:");

+        srpObject.print();

+        lspObject.print();

+

+        log.debug("label-list:");

+        ListIterator<PcepLabelObject> listIterator = llLabelList.listIterator();

+        while (listIterator.hasNext()) {

+            listIterator.next().print();

+        }

+    }

+}

diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/PcepLabelMap.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/PcepLabelMap.java
new file mode 100755
index 0000000..a421799
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/PcepLabelMap.java
@@ -0,0 +1,102 @@
+/*

+ * Copyright 2015 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.pcepio.types;

+

+import org.onosproject.pcepio.protocol.PcepFecObject;

+import org.onosproject.pcepio.protocol.PcepLabelObject;

+import org.onosproject.pcepio.protocol.PcepSrpObject;

+import org.slf4j.Logger;

+import org.slf4j.LoggerFactory;

+

+/**

+ * Provide PCEP Label Map.

+ * Reference :draft-zhao-pce-pcep-extension-for-pce-controller-01.

+ */

+public class PcepLabelMap {

+

+    protected static final Logger log = LoggerFactory.getLogger(PcepLabelMap.class);

+    //PCEP SRP Object

+    PcepSrpObject srpObject;

+    //PCEP Label Object

+    PcepLabelObject labelObject;

+    //PCEP FEC Object

+    PcepFecObject fecObject;

+

+    /**

+     * Sets Fec Object.

+     *

+     * @param fecObject PCEP fec object

+     */

+    public void setFECObject(PcepFecObject fecObject) {

+        this.fecObject = fecObject;

+    }

+

+    /**

+     * Returns the PcepFecObject.

+     *

+     * @return PCEP fec object

+     */

+    public PcepFecObject getFECObject() {

+        return this.fecObject;

+    }

+

+    /**

+     * Returns SRP Object.

+     *

+     * @return PCEP SRP Object

+     */

+    public PcepSrpObject getSrpObject() {

+        return srpObject;

+    }

+

+    /**

+     * Sets the PCEP Srp Object.

+     *

+     * @param srpObject PCEP SRP Object

+     */

+    public void setSrpObject(PcepSrpObject srpObject) {

+        this.srpObject = srpObject;

+    }

+

+    /**

+     * Returns labelObject.

+     *

+     * @return PCEP label object

+     */

+    public PcepLabelObject getLabelObject() {

+        return labelObject;

+    }

+

+    /**

+     * Sets the Pcep labelObject.

+     *

+     * @param labelObject PCEP label object

+     */

+    public void setLabelObject(PcepLabelObject labelObject) {

+        this.labelObject = labelObject;

+    }

+

+    /**

+     * Prints the attribute of PcepLabelMap.

+     */

+    public void print() {

+        log.debug("LABEL MAP:");

+        srpObject.print();

+        labelObject.print();

+        fecObject.print();

+    }

+}

diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/PcepObjectHeader.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/PcepObjectHeader.java
new file mode 100755
index 0000000..d0f0c1d9
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/PcepObjectHeader.java
@@ -0,0 +1,224 @@
+/*
+ * Copyright 2015 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.pcepio.types;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Provides PCEP Object Header which is common for all the objects.
+ * Reference : RFC 5440.
+ */
+
+public class PcepObjectHeader {
+
+    /*
+        0                   1                   2                   3
+        0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+       +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
+       | Object-Class  |   OT  |Res|P|I|   Object Length (bytes)       |
+       +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
+       |                                                               |
+       //                        (Object body)                        //
+       |                                                               |
+       +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
+
+                      PCEP Common Object Header
+     */
+
+    protected static final Logger log = LoggerFactory.getLogger(PcepObjectHeader.class);
+
+    public static final boolean REQ_OBJ_MUST_PROCESS = true;
+    public static final boolean REQ_OBJ_OPTIONAL_PROCESS = false;
+    public static final boolean RSP_OBJ_IGNORED = true;
+    public static final boolean RSP_OBJ_PROCESSED = false;
+    public static final int OBJECT_TYPE_SHIFT_VALUE = 4;
+    public static final byte PFLAG_SET = 0x02;
+    public static final byte IFLAG_SET = 0x01;
+    public static final int SET = 1;
+    private byte objClass;
+    private byte objType;
+    private boolean bPFlag;
+    private boolean bIFlag;
+    private short objLen;
+
+    /**
+     * Constructor to initialize all the variables in object header.
+     *
+     * @param objClass PCEP Object class
+     * @param objType PCEP Object type
+     * @param bPFlag P flag
+     * @param bIFlag I flag
+     * @param objLen PCEP object length
+     */
+
+    public PcepObjectHeader(byte objClass, byte objType, boolean bPFlag, boolean bIFlag, short objLen) {
+        this.objClass = objClass;
+        this.objType = objType;
+        this.bPFlag = bPFlag;
+        this.bIFlag = bIFlag;
+        this.objLen = objLen;
+    }
+
+    /**
+     * Sets the Object class.
+     *
+     * @param value object class
+     */
+    public void setObjClass(byte value) {
+        this.objClass = value;
+    }
+
+    /**
+     * Sets the Object TYPE.
+     *
+     * @param value object type
+     */
+    public void setObjType(byte value) {
+        this.objType = value;
+    }
+
+    /**
+     * Sets the Object P flag.
+     *
+     * @param value p flag
+     */
+    public void setPFlag(boolean value) {
+        this.bPFlag = value;
+    }
+
+    /**
+     * Sets the Object I flag.
+     *
+     * @param value I flag
+     */
+    public void setIFlag(boolean value) {
+        this.bIFlag = value;
+    }
+
+    /**
+     * Sets the Object Length.
+     *
+     * @param value object length
+     */
+    public void setObjLen(short value) {
+        this.objLen = value;
+    }
+
+    /**
+     * Returns Object's P flag.
+     *
+     * @return bPFlag P flag
+     */
+    public boolean getPFlag() {
+        return this.bPFlag;
+    }
+
+    /**
+     * Returns Object's i flag.
+     *
+     * @return bIFlag I flag
+     */
+    public boolean getIFlag() {
+        return this.bIFlag;
+    }
+
+    /**
+     * Returns Object Length.
+     *
+     * @return objLen object length
+     */
+    public short getObjLen() {
+        return this.objLen;
+    }
+
+    /**
+     * Returns Object class.
+     *
+     * @return objClass object class
+     */
+    public byte getObjClass() {
+        return this.objClass;
+    }
+
+    /**
+     * Returns Object Type.
+     *
+     * @return objType object type
+     */
+    public byte getObjType() {
+        return this.objType;
+    }
+
+    /**
+     *  Writes Byte stream of PCEP object header to channel buffer.
+     *
+     * @param bb of type channel buffer
+     * @return objLenIndex object length index in channel buffer
+     */
+    public int write(ChannelBuffer bb) {
+
+        bb.writeByte(this.objClass);
+        byte temp = (byte) (this.objType << OBJECT_TYPE_SHIFT_VALUE);
+        if (this.bPFlag) {
+            temp = (byte) (temp | PFLAG_SET);
+        }
+        if (this.bIFlag) {
+            temp = (byte) (temp | IFLAG_SET);
+        }
+        bb.writeByte(temp);
+        int objLenIndex = bb.writerIndex();
+        bb.writeShort((short) 0);
+        return objLenIndex;
+    }
+
+    /**
+     * Read from channel buffer and Returns PCEP Objects header.
+     *
+     * @param bb of type channel buffer
+     * @return PCEP Object header
+     */
+    public static PcepObjectHeader read(ChannelBuffer bb) {
+
+        byte objClass;
+        byte objType;
+        boolean bPFlag;
+        boolean bIFlag;
+        short objLen;
+        objClass = bb.readByte();
+        byte temp = bb.readByte();
+        bIFlag = ((temp & IFLAG_SET) == IFLAG_SET) ? true : false;
+        bPFlag = ((temp & PFLAG_SET) == PFLAG_SET) ? true : false;
+        objType = (byte) (temp >> OBJECT_TYPE_SHIFT_VALUE);
+        objLen = bb.readShort();
+        return new PcepObjectHeader(objClass, objType, bPFlag, bIFlag, objLen);
+    }
+
+    /**
+     * Prints the Attributes of PCEP Object header.
+     */
+    public void print() {
+
+        log.debug("PcepObjectHeader");
+        log.debug("Object Class: " + objClass);
+        log.debug("Object Type: " + objType);
+        log.debug("Object Length: " + objLen);
+        log.debug("P flag: " + bPFlag);
+        log.debug("I flag: " + bIFlag);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/PcepRsvpObjectHeader.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/PcepRsvpObjectHeader.java
new file mode 100755
index 0000000..37ee9fc
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/PcepRsvpObjectHeader.java
@@ -0,0 +1,161 @@
+/*
+ * Copyright 2015 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.pcepio.types;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Provides PcepRsvpObjectHeader.
+ */
+public class PcepRsvpObjectHeader {
+
+    /*
+    0             1              2             3
+    +-------------+-------------+-------------+-------------+
+    |       Length (bytes)      |  Class-Num  |   C-Type    |
+    +-------------+-------------+-------------+-------------+
+    |                                                       |
+    //                  (Object contents)                   //
+    |                                                       |
+    +-------------+-------------+-------------+-------------+
+
+              ERROR_SPEC object Header
+    */
+
+    protected static final Logger log = LoggerFactory.getLogger(PcepRsvpObjectHeader.class);
+
+    public static final boolean REQ_OBJ_MUST_PROCESS = true;
+    public static final boolean REQ_OBJ_OPTIONAL_PROCESS = false;
+    public static final boolean RSP_OBJ_IGNORED = true;
+    public static final boolean RSP_OBJ_PROCESSED = false;
+    public static final int OBJECT_TYPE_SHIFT_VALUE = 4;
+    private byte objClassNum;
+    private byte objClassType;
+    private short objLen;
+
+    /**
+     * Constructor to initialize class num , length and type.
+     *
+     * @param objClassNum object class number
+     * @param objClassType object class type
+     * @param objLen object length
+     */
+    public PcepRsvpObjectHeader(byte objClassNum, byte objClassType, short objLen) {
+        this.objClassNum = objClassNum;
+        this.objClassType = objClassType;
+        this.objLen = objLen;
+    }
+
+    /**
+     * Sets the Class num.
+     *
+     * @param value object class number
+     */
+    public void setObjClassNum(byte value) {
+        this.objClassNum = value;
+    }
+
+    /**
+     * Sets the Class type.
+     *
+     * @param value object class type
+     */
+    public void setObjClassType(byte value) {
+        this.objClassType = value;
+    }
+
+    /**
+     * Sets the Class Length.
+     *
+     * @param value object length
+     */
+    public void setObjLen(short value) {
+        this.objLen = value;
+    }
+
+    /**
+     * Returns Object Length.
+     *
+     * @return objLen
+     */
+    public short getObjLen() {
+        return this.objLen;
+    }
+
+    /**
+     * Returns Object num.
+     *
+     * @return objClassNum
+     */
+    public byte getObjClassNum() {
+        return this.objClassNum;
+    }
+
+    /**
+     * Returns Object type.
+     *
+     * @return objClassType
+     */
+    public byte getObjClassType() {
+        return this.objClassType;
+    }
+
+    /**
+     * Writes the byte stream of PcepRsvpObjectHeader to channel buffer.
+     *
+     * @param bb of type channel buffer
+     * @return object length index in channel buffer
+     */
+    public int write(ChannelBuffer bb) {
+        int iLenStartIndex = bb.writerIndex();
+        bb.writeShort((short) 0);
+        bb.writeByte(this.objClassNum);
+        bb.writeByte(this.objClassType);
+        return bb.writerIndex() - iLenStartIndex;
+    }
+
+    /**
+     * Reads the PcepRsvpObjectHeader.
+     *
+     * @param bb of type channel buffer
+     * @return PcepRsvpObjectHeader
+     */
+    public static PcepRsvpObjectHeader read(ChannelBuffer bb) {
+        log.debug("PcepRsvpObjectHeader ::read ");
+        byte objClassNum;
+        byte objClassType;
+        short objLen;
+        objLen = bb.readShort();
+        objClassNum = bb.readByte();
+        objClassType = bb.readByte();
+
+        return new PcepRsvpObjectHeader(objClassNum, objClassType, objLen);
+    }
+
+    /**
+     * Prints the attribute of PcepRsvpObjectHeader.
+     */
+    public void print() {
+
+        log.debug("PcepObjectHeader");
+        log.debug("Object Class-Num: " + objClassNum);
+        log.debug("Object C-Type: " + objClassType);
+        log.debug("Object Length: " + objLen);
+    }
+}
diff --git a/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/PcepValueType.java b/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/PcepValueType.java
new file mode 100755
index 0000000..9d3599b
--- /dev/null
+++ b/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/PcepValueType.java
@@ -0,0 +1,60 @@
+/*
+ * Copyright 2015 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.pcepio.types;
+
+import org.jboss.netty.buffer.ChannelBuffer;
+import org.onosproject.pcepio.protocol.PcepVersion;
+
+/**
+ * Abstraction which Provides the PCEP Values of Type, Length ,Version.
+ */
+public interface PcepValueType {
+
+    /**
+     * Returns the Version Of PCEP Message.
+     *
+     * @return Version of PcepVersion Type.
+     */
+    PcepVersion getVersion();
+
+    /**
+     * Returns the Type of PCEP Message.
+     *
+     * @return value of type
+     */
+    public short getType();
+
+    /**
+     * Returns the Length of PCEP Message.
+     *
+     * @return value of Length
+     */
+    public short getLength();
+
+    /**
+     * Writes the byte Stream of PCEP Message to channel buffer.
+     *
+     * @param bb of type channel buffer
+     * @return length of bytes written to channel buffer
+     */
+    public int write(ChannelBuffer bb);
+
+    /**
+     * Prints the Attributes of PCEP Message.
+     */
+    public void print();
+}
diff --git a/pcep/pom.xml b/pcep/pom.xml
new file mode 100755
index 0000000..2ab2505
--- /dev/null
+++ b/pcep/pom.xml
@@ -0,0 +1,59 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  ~ Copyright 2014 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/maven-v4_0_0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>org.onosproject</groupId>
+        <artifactId>onos</artifactId>
+        <version>1.3.0-SNAPSHOT</version>
+        <relativePath>../pom.xml</relativePath>
+    </parent>
+
+    <artifactId>onos-pcep-controller</artifactId>
+    <packaging>pom</packaging>
+
+    <description>ONOS Pcep Protocol subsystem</description>
+
+    <modules>
+        <module>api</module>
+        <module>pcepio</module>
+    </modules>
+
+    <dependencies>
+        <dependency>
+            <groupId>org.onosproject</groupId>
+            <artifactId>onlab-misc</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.onosproject</groupId>
+            <artifactId>onlab-junit</artifactId>
+        </dependency>
+    </dependencies>
+
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.felix</groupId>
+                <artifactId>maven-bundle-plugin</artifactId>
+            </plugin>
+        </plugins>
+    </build>
+
+</project>
diff --git a/pom.xml b/pom.xml
old mode 100644
new mode 100755
index 4ea2f20..cb02cda
--- a/pom.xml
+++ b/pom.xml
@@ -49,7 +49,8 @@
         <module>apps</module>
         <module>incubator</module>
         <module>features</module>
-        <module>tools/package/archetypes</module>
+        <module>pcep</module>
+	<module>tools/package/archetypes</module>
         <module>tools/package/branding</module>
         <!-- FIXME remove before release -->
         <module>tools/package/maven-plugin</module>
@@ -399,6 +400,18 @@
 
             <dependency>
                 <groupId>org.onosproject</groupId>
+                <artifactId>onos-pcepio</artifactId>
+                <version>${project.version}</version>
+            </dependency>
+
+            <dependency>
+                <groupId>org.onosproject</groupId>
+                <artifactId>onos-pcep-controller-api</artifactId>
+                <version>${project.version}</version>
+            </dependency>
+
+            <dependency>
+                <groupId>org.onosproject</groupId>
 				<artifactId>onos-app-pcep-api</artifactId>
                 <version>${project.version}</version>
             </dependency>