Add interfaces for FlowMap and FlowBatchMap.

- These interfacees are used by FlowManagerModule and are not exposed to applications.
- This task is preperation for ONOS-1688, ONOS-1736 and ONOS-1842.

Change-Id: I93c7e9fc30ad0c0eb1c1879660416e59057ec123
diff --git a/src/main/java/net/onrc/onos/core/flowmanager/FlowMapEventListener.java b/src/main/java/net/onrc/onos/core/flowmanager/FlowMapEventListener.java
new file mode 100644
index 0000000..adc8225
--- /dev/null
+++ b/src/main/java/net/onrc/onos/core/flowmanager/FlowMapEventListener.java
@@ -0,0 +1,34 @@
+package net.onrc.onos.core.flowmanager;
+
+import net.onrc.onos.api.flowmanager.Flow;
+import net.onrc.onos.api.flowmanager.FlowId;
+import net.onrc.onos.api.flowmanager.FlowState;
+
+/**
+ * An interface to the event listener of the flow map.
+ */
+interface FlowMapEventListener {
+    /**
+     * Invoked when a {@link Flow} object is added.
+     *
+     * @param id the ID of the {@link Flow}.
+     * @param flow the {@link Flow} object.
+     */
+    void flowAdded(FlowId id, Flow flow);
+
+    /**
+     * Invoked when a {@link Flow} object is removed.
+     *
+     * @param id the ID of the {@link Flow}.
+     */
+    void flowRemoved(FlowId id);
+
+    /**
+     * Invoked when a {@link FlowState} of a {@link Flow} object is changed.
+     *
+     * @param id the ID of the {@link Flow}
+     * @param oldState the old state of the {@link Flow}
+     * @param currentState the current state of the {@link Flow}
+     */
+    void flowStateChanged(FlowId id, FlowState oldState, FlowState currentState);
+}