Fix BGP operational state
[bgpcep.git] / bgp / rib-spi / src / main / java / org / opendaylight / protocol / bgp / rib / spi / state / BGPAfiSafiState.java
1 /*
2  * Copyright (c) 2016 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.protocol.bgp.rib.spi.state;
9
10 import java.util.Set;
11 import org.eclipse.jdt.annotation.NonNull;
12 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.rib.rev180329.rib.TablesKey;
13
14 /**
15  * BGP Operational Afi SafiS State.
16  */
17 public interface BGPAfiSafiState extends BGPLlGracelfulRestartState {
18     /**
19      * is AfiSafi Supported.
20      *
21      * @param tablesKey tables Key
22      * @return true if Afi Safi was advertized to and by the neighbor
23      */
24     boolean isAfiSafiSupported(@NonNull TablesKey tablesKey);
25
26     /**
27      * Prefixes installed per specific tablekey.
28      *
29      * @param tablesKey tables Key
30      * @return count
31      */
32     long getPrefixesInstalledCount(@NonNull TablesKey tablesKey);
33
34     /**
35      * Prefixed sent to the Peer count.
36      *
37      * @param tablesKey tablesKey Type
38      * @return Prefixes sent count
39      */
40     long getPrefixesSentCount(@NonNull TablesKey tablesKey);
41
42     /**
43      * Prefixed received from the peer count.
44      *
45      * @param tablesKey tablesKey Type
46      * @return Prefixed received count
47      */
48     long getPrefixesReceivedCount(@NonNull TablesKey tablesKey);
49
50     /**
51      * List of TablesKey - Afi Safi Advertized to the neighbor.
52      *
53      * @return TableKeys
54      */
55     @NonNull Set<TablesKey> getAfiSafisAdvertized();
56
57     /**
58      * List of TablesKey - Afi Safi Advertized by neighbor.
59      *
60      * @return TableKeys
61      */
62     @NonNull Set<TablesKey> getAfiSafisReceived();
63 }