Bug 3044 - Conversion from Flowspec BI -> BA
[bgpcep.git] / bgp / rib-spi / src / main / java / org / opendaylight / protocol / bgp / rib / spi / AdjRIBsIn.java
1 /*
2  * Copyright (c) 2013 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;
9
10 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.message.rev130919.Update;
11 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.message.rev130919.path.attributes.Attributes;
12 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.multiprotocol.rev130919.update.attributes.MpReachNlri;
13 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.multiprotocol.rev130919.update.attributes.MpReachNlriBuilder;
14 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.multiprotocol.rev130919.update.attributes.MpUnreachNlri;
15 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.rib.rev130925.Route;
16
17 @Deprecated
18 public interface AdjRIBsIn<K, V extends Route> {
19
20     /**
21      * Adds routes to this adjacency rib.
22      * @param trans data-store transaction
23      * @param peer advertising peer
24      * @param nlri routes
25      * @param attributes route attributes
26      */
27     void addRoutes(final AdjRIBsTransaction trans, final Peer peer, final MpReachNlri nlri, final Attributes attributes);
28
29     /**
30      * Removes routes from this adjacency rib.
31      * @param trans data-store transaction
32      * @param peer advertising peer
33      * @param nlri routes
34      */
35     void removeRoutes(final AdjRIBsTransaction trans, final Peer peer, final MpUnreachNlri nlri);
36
37     /**
38      * Clears adjacency rib tables.
39      * @param trans data-store transaction
40      * @param peer advertising peer
41      */
42     void clear(final AdjRIBsTransaction trans, final Peer peer);
43
44     /**
45      * Marks true or false the state of this adjacency rib.
46      * @param trans data-store transaction
47      * @param peer advertising peer
48      */
49     void markUptodate(final AdjRIBsTransaction trans, final Peer peer);
50
51     /**
52      * Transform an advertised data object into the corresponding NLRI in MP_REACH attribute.
53      * @param builder MP_REACH attribute builder
54      * @param data Data object
55      */
56     void addAdvertisement(final MpReachNlriBuilder builder, final V data);
57
58     /**
59      * Creates end-of-rib message for this adjacency rib.
60      * @return BGP Update message
61      */
62     Update endOfRib();
63 }