32f3edd6433f692218483337bec6eb20f2d7927e
[bgpcep.git] / pcep / api / src / main / java / org / opendaylight / protocol / pcep / PCEPDispatcher.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.pcep;
9
10 import io.netty.channel.ChannelFuture;
11
12 import java.net.InetSocketAddress;
13
14 import org.opendaylight.protocol.framework.SessionListenerFactory;
15
16 /**
17  * Dispatcher class for creating servers and clients.
18  */
19 public interface PCEPDispatcher {
20         /**
21          * Creates server. Each server needs three factories to pass their instances to client sessions.
22          * 
23          * @param address to be bound with the server
24          * @param listenerFactory to create listeners for clients
25          * @return instance of PCEPServer
26          */
27         public ChannelFuture createServer(final InetSocketAddress address, final SessionListenerFactory<PCEPSessionListener> listenerFactory);
28 }