Package io.github.joealisson.mmocore
Class Connector<T extends Client<Connection<T>>>
- java.lang.Object
-
- io.github.joealisson.mmocore.Connector<T>
-
public class Connector<T extends Client<Connection<T>>> extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description Connector()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Connector<T>bufferDefaultSize(int bufferSize)Connector<T>bufferLargePoolSize(int bufferPoolSize)Connector<T>bufferLargeSize(int bufferSize)Connector<T>bufferMediumPoolSize(int bufferPoolSize)Connector<T>bufferMediumSize(int bufferSize)Connector<T>bufferMinPoolSize(int bufferPoolSize)Connector<T>bufferMinSize(int bufferSize)Connector<T>bufferPoolSize(int bufferPoolSize)Connector<T>byteOrder(java.nio.ByteOrder order)Tconnect(java.lang.String host, int port)Tconnect(java.net.InetSocketAddress socketAddress)static <T extends Client<Connection<T>>>
Connector<T>create(ClientFactory<T> clientFactory, PacketHandler<T> packetHandler, PacketExecutor<T> executor)
-
-
-
Method Detail
-
create
public static <T extends Client<Connection<T>>> Connector<T> create(ClientFactory<T> clientFactory, PacketHandler<T> packetHandler, PacketExecutor<T> executor)
-
connect
public T connect(java.lang.String host, int port) throws java.io.IOException, java.util.concurrent.ExecutionException, java.lang.InterruptedException
- Throws:
java.io.IOExceptionjava.util.concurrent.ExecutionExceptionjava.lang.InterruptedException
-
connect
public T connect(java.net.InetSocketAddress socketAddress) throws java.io.IOException, java.util.concurrent.ExecutionException, java.lang.InterruptedException
- Throws:
java.io.IOExceptionjava.util.concurrent.ExecutionExceptionjava.lang.InterruptedException
-
-