Fix "Bug 5589 - Deprecate PortNumberCache"
[openflowplugin.git] / openflowplugin-api / src / main / java / org / opendaylight / openflowplugin / api / openflow / device / PortNumberCache.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
9 package org.opendaylight.openflowplugin.api.openflow.device;
10
11 import javax.annotation.Nonnull;
12 import javax.annotation.Nullable;
13 import org.opendaylight.yang.gen.v1.urn.opendaylight.inventory.rev130819.NodeConnectorRef;
14
15 /**
16  * keeps mapping between port number (protocol based) and {@link NodeConnectorRef}
17  */
18 public interface PortNumberCache {
19
20     /**
21      * @param portNumber
22      * @return corresponding nodeConnectorRef if present
23      */
24     @Nullable
25     @Deprecated
26     NodeConnectorRef lookupNodeConnectorRef(Long portNumber);
27
28     /**
29      * @param portNumber       protocol port number
30      * @param nodeConnectorRef corresponding value of {@link NodeConnectorRef}
31      */
32     @Deprecated
33     void storeNodeConnectorRef(@Nonnull Long portNumber, @Nonnull NodeConnectorRef nodeConnectorRef);
34 }