added of packet provider - unimplemented
diff --git a/core/trivial/src/main/java/org/onlab/onos/net/trivial/packet/impl/SimplePacketManager.java b/core/trivial/src/main/java/org/onlab/onos/net/trivial/packet/impl/SimplePacketManager.java
index cf324f4..2233c32 100644
--- a/core/trivial/src/main/java/org/onlab/onos/net/trivial/packet/impl/SimplePacketManager.java
+++ b/core/trivial/src/main/java/org/onlab/onos/net/trivial/packet/impl/SimplePacketManager.java
@@ -95,4 +95,4 @@
}
}
-}
\ No newline at end of file
+}
diff --git a/providers/of/packet/pom.xml b/providers/of/packet/pom.xml
new file mode 100644
index 0000000..a425899
--- /dev/null
+++ b/providers/of/packet/pom.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<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.onlab.onos</groupId>
+ <artifactId>onos-of-providers</artifactId>
+ <version>1.0.0-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+
+ <artifactId>onos-of-provider-packet</artifactId>
+ <packaging>bundle</packaging>
+
+ <description>ONOS OpenFlow protocol packet provider</description>
+
+</project>
diff --git a/providers/of/packet/src/main/java/org/onlab/onos/provider/of/packet/impl/OpenFlowPacketProvider.java b/providers/of/packet/src/main/java/org/onlab/onos/provider/of/packet/impl/OpenFlowPacketProvider.java
new file mode 100644
index 0000000..c854daa
--- /dev/null
+++ b/providers/of/packet/src/main/java/org/onlab/onos/provider/of/packet/impl/OpenFlowPacketProvider.java
@@ -0,0 +1,85 @@
+package org.onlab.onos.provider.of.packet.impl;
+
+import static org.slf4j.LoggerFactory.getLogger;
+
+import org.apache.felix.scr.annotations.Activate;
+import org.apache.felix.scr.annotations.Component;
+import org.apache.felix.scr.annotations.Deactivate;
+import org.apache.felix.scr.annotations.Reference;
+import org.apache.felix.scr.annotations.ReferenceCardinality;
+import org.onlab.onos.net.packet.OutboundPacket;
+import org.onlab.onos.net.packet.PacketProvider;
+import org.onlab.onos.net.packet.PacketProviderRegistry;
+import org.onlab.onos.net.packet.PacketProviderService;
+import org.onlab.onos.net.provider.AbstractProvider;
+import org.onlab.onos.net.provider.ProviderId;
+import org.onlab.onos.of.controller.OpenFlowController;
+import org.onlab.onos.of.controller.OpenFlowPacketContext;
+import org.onlab.onos.of.controller.PacketListener;
+import org.slf4j.Logger;
+
+/**
+ * Provider which uses an OpenFlow controller to detect network
+ * infrastructure links.
+ */
+@Component(immediate = true)
+public class OpenFlowPacketProvider extends AbstractProvider implements PacketProvider {
+
+ private final Logger log = getLogger(getClass());
+
+ @Reference(cardinality = ReferenceCardinality.MANDATORY_UNARY)
+ protected PacketProviderRegistry providerRegistry;
+
+ @Reference(cardinality = ReferenceCardinality.MANDATORY_UNARY)
+ protected OpenFlowController controller;
+
+ private PacketProviderService providerService;
+
+ private final boolean useBDDP = true;
+
+ private final InternalPacketProvider listener = new InternalPacketProvider();
+
+
+
+ /**
+ * Creates an OpenFlow link provider.
+ */
+ public OpenFlowPacketProvider() {
+ super(new ProviderId("org.onlab.onos.provider.openflow"));
+ }
+
+ @Activate
+ public void activate() {
+ providerService = providerRegistry.register(this);
+ controller.addPacketListener(0, listener);
+ log.info("Started");
+ }
+
+ @Deactivate
+ public void deactivate() {
+ providerRegistry.unregister(this);
+ controller.removePacketListener(listener);
+ providerService = null;
+ log.info("Stopped");
+ }
+
+ @Override
+ public void emit(OutboundPacket packet) {
+ // TODO Auto-generated method stub
+
+ }
+
+
+ private class InternalPacketProvider implements PacketListener {
+
+
+ @Override
+ public void handlePacket(OpenFlowPacketContext pktCtx) {
+
+
+ }
+
+ }
+
+
+}
diff --git a/providers/of/pom.xml b/providers/of/pom.xml
index 0722d71..901cdd6 100644
--- a/providers/of/pom.xml
+++ b/providers/of/pom.xml
@@ -20,6 +20,7 @@
<module>device</module>
<module>link</module>
<module>host</module>
+ <module>packet</module>
</modules>
<dependencies>