Class LocalSession
java.lang.Object
io.netty.channel.ChannelHandlerAdapter
io.netty.channel.ChannelInboundHandlerAdapter
io.netty.channel.SimpleChannelInboundHandler<com.github.steveice10.packetlib.packet.Packet>
com.github.steveice10.packetlib.tcp.TcpSession
org.geysermc.geyser.network.netty.LocalSession
- All Implemented Interfaces:
com.github.steveice10.packetlib.Session,io.netty.channel.ChannelHandler,io.netty.channel.ChannelInboundHandler
public final class LocalSession
extends com.github.steveice10.packetlib.tcp.TcpSession
Manages a Minecraft Java session over our LocalChannel implementations.
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.netty.channel.ChannelHandler
io.netty.channel.ChannelHandler.Sharable -
Field Summary
Fields inherited from class com.github.steveice10.packetlib.tcp.TcpSession
disconnected, host, port, USE_EVENT_LOOP_FOR_PACKETS -
Constructor Summary
ConstructorsConstructorDescriptionLocalSession(String host, int port, SocketAddress targetAddress, String clientIp, com.github.steveice10.packetlib.packet.PacketProtocol protocol, com.github.steveice10.packetlib.codec.PacketCodecHelper codecHelper) -
Method Summary
Modifier and TypeMethodDescriptionvoidconnect(boolean wait)static voidShould only be called when direct ByteBufs should be preferred.com.github.steveice10.packetlib.codec.PacketCodecHelperMethods inherited from class com.github.steveice10.packetlib.tcp.TcpSession
addListener, callEvent, callPacketReceived, callPacketSent, channelActive, channelInactive, channelRead0, connect, disconnect, disconnect, enableEncryption, exceptionCaught, getChannel, getCompressionThreshold, getConnectTimeout, getFlag, getFlag, getFlags, getHost, getListeners, getLocalAddress, getPacketProtocol, getPort, getReadTimeout, getRemoteAddress, getWriteTimeout, hasFlag, isConnected, refreshReadTimeoutHandler, refreshReadTimeoutHandler, refreshWriteTimeoutHandler, refreshWriteTimeoutHandler, removeListener, send, setCompressionThreshold, setConnectTimeout, setFlag, setReadTimeout, setWriteTimeoutMethods inherited from class io.netty.channel.SimpleChannelInboundHandler
acceptInboundMessage, channelReadMethods inherited from class io.netty.channel.ChannelInboundHandlerAdapter
channelReadComplete, channelRegistered, channelUnregistered, channelWritabilityChanged, userEventTriggeredMethods inherited from class io.netty.channel.ChannelHandlerAdapter
ensureNotSharable, handlerAdded, handlerRemoved, isSharableMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.netty.channel.ChannelHandler
handlerAdded, handlerRemoved
-
Constructor Details
-
LocalSession
public LocalSession(String host, int port, SocketAddress targetAddress, String clientIp, com.github.steveice10.packetlib.packet.PacketProtocol protocol, com.github.steveice10.packetlib.codec.PacketCodecHelper codecHelper)
-
-
Method Details
-
connect
public void connect(boolean wait)- Specified by:
connectin interfacecom.github.steveice10.packetlib.Session- Overrides:
connectin classcom.github.steveice10.packetlib.tcp.TcpSession
-
getCodecHelper
public com.github.steveice10.packetlib.codec.PacketCodecHelper getCodecHelper() -
createDirectByteBufAllocator
public static void createDirectByteBufAllocator()Should only be called when direct ByteBufs should be preferred. At this moment, this should only be called on BungeeCord.
-