@Deprecated public class JnlpProtocol1Handler extends JnlpProtocolHandler<STATE>
JnlpProtocol4Handler| Modifier and Type | Field and Description |
|---|---|
static String |
GREETING_SUCCESS
The expected response from the master on successful completion of the
handshake.
|
| Constructor and Description |
|---|
JnlpProtocol1Handler(JnlpClientDatabase clientDatabase,
ExecutorService threadPool,
NioChannelHub hub,
boolean preferNio)
Deprecated.
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
Future<Channel> |
connect(Socket socket,
Map<String,String> headers,
List<? extends JnlpConnectionStateListener> listeners)
Handles an outgoing connection to the server on the supplied socket.
|
LegacyJnlpConnectionState |
createConnectionState(Socket socket,
List<? extends JnlpConnectionStateListener> listeners)
Deprecated.
Creates the
JnlpConnectionState instance for this JnlpProtocolHandler. |
String |
getName()
Deprecated.
Get the name of the protocol.
|
Future<Channel> |
handle(Socket socket,
Map<String,String> headers,
List<? extends JnlpConnectionStateListener> listeners)
Handles an incoming client connection on the supplied socket.
|
connect, getClientDatabase, handle, isEnabled, isPreferNiopublic static final String GREETING_SUCCESS
public JnlpProtocol1Handler(@Nullable JnlpClientDatabase clientDatabase, @Nonnull ExecutorService threadPool, @Nullable NioChannelHub hub, boolean preferNio)
clientDatabase - the client database to use or null if client connections will not be required.threadPool - the ExecutorService to run tasks on.hub - the NioChannelHub to use or null to use blocking I/O.preferNio - true means that the protocol should attempt to use NIO if possiblepublic String getName()
getName in class JnlpProtocolHandler<LegacyJnlpConnectionState>@Nonnull public LegacyJnlpConnectionState createConnectionState(@Nonnull Socket socket, @Nonnull List<? extends JnlpConnectionStateListener> listeners) throws IOException
JnlpConnectionState instance for this JnlpProtocolHandler.socket - the Socketlisteners - the initial JnlpConnectionStateListener instances.JnlpConnectionState for this connection.IOException - if something goes wrong.@Nonnull public Future<Channel> handle(@Nonnull Socket socket, @Nonnull Map<String,String> headers, @Nonnull List<? extends JnlpConnectionStateListener> listeners) throws IOException
handle in class JnlpProtocolHandler<STATE extends LegacyJnlpConnectionState>socket - the socket.headers - the headers to send.listeners - the listeners to approve and receive the connection.Future for the Channel to the server.IOException - if the protocol cannot be initiated.@Nonnull public Future<Channel> connect(@Nonnull Socket socket, @Nonnull Map<String,String> headers, @Nonnull List<? extends JnlpConnectionStateListener> listeners) throws IOException
connect in class JnlpProtocolHandler<STATE extends LegacyJnlpConnectionState>socket - the socket.headers - the headers to send.listeners - the listeners to approve and receive the connection.Future for the Channel to the server.IOException - if the protocol cannot be initiated.Copyright © 2004–2018. All rights reserved.