Update FlowManager's API design and define batch operation map's API.

- FlowManager returns FlowBatchHandle as a handler to the batch execution.
 -- addFlow(), removeFlow() and executeBatch() methods are executed asynchronously.
 -- Users can get the current state of the batch via the FlowBatchHandle.
- Defined FlowOperationMap's inital API designs.

This task is a part of ONOS-1687, ONOS-1842, and ONOS-1692.

Change-Id: Ic9e8ce3ab0378615d9d3016b7755ee6d15e1e47c
diff --git a/src/main/java/net/onrc/onos/api/flowmanager/FlowManagerService.java b/src/main/java/net/onrc/onos/api/flowmanager/FlowManagerService.java
index 4812de2..347c5fa 100644
--- a/src/main/java/net/onrc/onos/api/flowmanager/FlowManagerService.java
+++ b/src/main/java/net/onrc/onos/api/flowmanager/FlowManagerService.java
@@ -15,20 +15,26 @@
  */
 public interface FlowManagerService {
     /**
-     * Adds Flow object, calculates match-action plan and executes it.
+     * Adds Flow object, calculates match-action plan and executes it
+     * asynchronously.
+     * <p>
+     * To track the execution result, use the returned FlowBatchHandle object.
      *
      * @param flow Flow object to be added
-     * @return true if succeeded, false otherwise
+     * @return FlowBatchHandle object if succeeded, null otherwise
      */
-    boolean addFlow(Flow flow);
+    FlowBatchHandle addFlow(Flow flow);
 
     /**
-     * Removes Flow object, calculates match-action plan and executes it.
+     * Removes Flow object, calculates match-action plan and executes it
+     * asynchronously.
+     * <p>
+     * To track the execution result, use the returned FlowBatchHandle object.
      *
      * @param id ID for Flow object to be removed
-     * @return true if succeeded, false otherwise
+     * @return FlowBatchHandle object if succeeded, null otherwise
      */
-    boolean removeFlow(FlowId id);
+    FlowBatchHandle removeFlow(FlowId id);
 
     /**
      * Gets Flow object.
@@ -46,12 +52,14 @@
     Collection<Flow> getFlows();
 
     /**
-     * Executes batch operation of Flow object.
+     * Executes batch operation of Flow object asynchronously.
+     * <p>
+     * To track the execution result, use the returned FlowBatchHandle object.
      *
      * @param ops flow operations to be executed
-     * @return true if succeeded, false otherwise
+     * @return FlowBatchHandle object if succeeded, null otherwise
      */
-    boolean executeBatch(FlowBatchOperation ops);
+    FlowBatchHandle executeBatch(FlowBatchOperation ops);
 
     /**
      * Sets a conflict detection policy.