e2df70da1b5351b451a6c287d571efed66cbb479
[bgpcep.git] / bgp / rib-impl / src / main / java / org / opendaylight / protocol / bgp / rib / impl / spi / BGPDispatcher.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.impl.spi;
9
10 import io.netty.util.concurrent.Future;
11
12 import java.io.IOException;
13
14 import org.opendaylight.protocol.bgp.parser.BGPSession;
15 import org.opendaylight.protocol.framework.ProtocolMessageFactory;
16 import org.opendaylight.protocol.framework.ReconnectStrategy;
17
18 /**
19  * Dispatcher class for creating BGP clients.
20  */
21 public interface BGPDispatcher {
22
23         /**
24          * Creates BGP client.
25          * 
26          * @param connection attributes required for connection
27          * @param parser BGP message parser
28          * @return client session
29          * @throws IOException
30          */
31         Future<? extends BGPSession> createClient(BGPConnection connection, ProtocolMessageFactory parser, final ReconnectStrategy strategy);
32 }