package org.opendaylight.openflowplugin.api.openflow.registry.flow;
+import com.google.common.base.Optional;
+import com.google.common.util.concurrent.ListenableFuture;
+import java.util.List;
import java.util.Map;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.inventory.rev130819.FlowCapableNode;
import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.inventory.rev130819.FlowId;
-import org.opendaylight.yang.gen.v1.urn.opendaylight.inventory.rev130819.nodes.Node;
-import org.opendaylight.yang.gen.v1.urn.opendaylight.inventory.rev130819.nodes.NodeKey;
-import org.opendaylight.yangtools.yang.binding.KeyedInstanceIdentifier;
/**
- * Created by Martin Bobak <mbobak@cisco.com> on 8.4.2015.
+ * Registry for mapping composite-key of flow ({@link FlowRegistryKey}) from device view
+ * to flow descriptor ({@link FlowDescriptor}) as the identifier of the same flow in data store.
*/
public interface DeviceFlowRegistry extends AutoCloseable {
- void fill(KeyedInstanceIdentifier<Node, NodeKey> instanceIdentifier);
+ ListenableFuture<List<Optional<FlowCapableNode>>> fill();
FlowDescriptor retrieveIdForFlow(FlowRegistryKey flowRegistryKey);
FlowId storeIfNecessary(FlowRegistryKey flowRegistryKey);
- void markToBeremoved(FlowRegistryKey flowRegistryKey);
+ void removeDescriptor(FlowRegistryKey flowRegistryKey);
- void removeMarked();
+ void update(FlowRegistryKey newFlowRegistryKey,FlowDescriptor flowDescriptor);
Map<FlowRegistryKey, FlowDescriptor> getAllFlowDescriptors();
@Override
void close();
-}
+}
\ No newline at end of file