Switch to MD-SAL APIs
[openflowplugin.git] / openflowplugin-api / src / main / java / org / opendaylight / openflowplugin / api / openflow / registry / flow / DeviceFlowRegistry.java
1 /*
2  * Copyright (c) 2015 Cisco Systems, Inc. and others.  All rights reserved.
3  *
4  * This program and the accompanying materials are made available under the
5  * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6  * and is available at http://www.eclipse.org/legal/epl-v10.html
7  */
8 package org.opendaylight.openflowplugin.api.openflow.registry.flow;
9
10 import com.google.common.util.concurrent.ListenableFuture;
11 import java.util.List;
12 import java.util.Optional;
13 import javax.annotation.Nonnull;
14 import javax.annotation.Nullable;
15 import org.opendaylight.openflowplugin.api.openflow.registry.CommonDeviceRegistry;
16 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.inventory.rev130819.FlowCapableNode;
17
18 /**
19  * Registry for mapping composite-key of flow ({@link FlowRegistryKey}) from device view
20  * to flow descriptor ({@link FlowDescriptor}) as the identifier of the same flow in data store.
21  */
22 public interface DeviceFlowRegistry extends CommonDeviceRegistry<FlowRegistryKey> {
23
24     ListenableFuture<List<Optional<FlowCapableNode>>> fill();
25
26     void storeDescriptor(@Nonnull FlowRegistryKey flowRegistryKey, @Nonnull FlowDescriptor flowDescriptor);
27
28     @Nullable
29     FlowDescriptor retrieveDescriptor(@Nonnull FlowRegistryKey flowRegistryKey);
30
31 }