import org.opendaylight.protocol.bgp.parser.BGPDocumentedException;
import org.opendaylight.protocol.bgp.rib.spi.BGPSessionListener;
-import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev100924.AsNumber;
import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev100924.IpAddress;
import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev100924.Ipv4Address;
+import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.message.rev130919.Open;
/**
* Registry that contains configured bgp peers ready for when a bgp session is established with remote peer.
* Add configured peer, its IP address and preferences. To be used when a BGP session is established.
*
* @param ip address of remote peer
- * @param peer configured peer as ReusableBGPPeer
+ * @param peer configured peer as BGPSessionListener
* @param prefs session preferences for configured peer
*/
- void addPeer(IpAddress ip, ReusableBGPPeer peer, BGPSessionPreferences prefs);
+ void addPeer(IpAddress ip, BGPSessionListener peer, BGPSessionPreferences prefs);
/**
* Remove configured peer from registry.
* @param ip address of remote peer
* @param sourceId BGP ID of peer that initiated the session (current device or remote peer)
* @param remoteId BGP ID of peer that accepted the session (current device or remote peer)
- * @return configured Peer as BGP listener
+ * @param open remote Open message
+ * @return BGPSessionListener configured Peer as BGP listener
*
* @throws BGPDocumentedException if session establishment cannot be finished successfully
* @throws java.lang.IllegalStateException if there is no peer configured for provided ip address
*/
- BGPSessionListener getPeer(IpAddress ip, Ipv4Address sourceId, Ipv4Address remoteId, AsNumber asNumber) throws BGPDocumentedException;
+ BGPSessionListener getPeer(IpAddress ip, Ipv4Address sourceId, Ipv4Address remoteId, Open open) throws BGPDocumentedException;
/**
* @param ip address of remote peer