Class PacketHandlersImpl

java.lang.Object
org.geysermc.floodgate.core.packet.PacketHandlersImpl
All Implemented Interfaces:
org.geysermc.floodgate.core.api.packet.PacketHandlers<io.netty.channel.ChannelHandlerContext>

@Singleton public final class PacketHandlersImpl extends Object implements org.geysermc.floodgate.core.api.packet.PacketHandlers<io.netty.channel.ChannelHandlerContext>
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    deregister(org.geysermc.floodgate.core.api.packet.PacketHandler<io.netty.channel.ChannelHandlerContext> handler)
     
    Collection<org.geysermc.floodgate.api.util.TriFunction<io.netty.channel.ChannelHandlerContext,Object,Boolean,Object>>
     
    boolean
     
    void
    register(org.geysermc.floodgate.core.api.packet.PacketHandler<io.netty.channel.ChannelHandlerContext> handler, Class<?> packetClass, org.geysermc.floodgate.api.util.TriFunction<io.netty.channel.ChannelHandlerContext,Object,Boolean,Object> consumer)
     
    void
    registerAll(org.geysermc.floodgate.core.api.packet.PacketHandler<io.netty.channel.ChannelHandlerContext> handler)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.geysermc.floodgate.core.api.packet.PacketHandlers

    register
  • Constructor Details

    • PacketHandlersImpl

      public PacketHandlersImpl()
  • Method Details

    • register

      public void register(org.geysermc.floodgate.core.api.packet.PacketHandler<io.netty.channel.ChannelHandlerContext> handler, Class<?> packetClass, org.geysermc.floodgate.api.util.TriFunction<io.netty.channel.ChannelHandlerContext,Object,Boolean,Object> consumer)
      Specified by:
      register in interface org.geysermc.floodgate.core.api.packet.PacketHandlers<io.netty.channel.ChannelHandlerContext>
    • registerAll

      public void registerAll(org.geysermc.floodgate.core.api.packet.PacketHandler<io.netty.channel.ChannelHandlerContext> handler)
      Specified by:
      registerAll in interface org.geysermc.floodgate.core.api.packet.PacketHandlers<io.netty.channel.ChannelHandlerContext>
    • deregister

      public void deregister(org.geysermc.floodgate.core.api.packet.PacketHandler<io.netty.channel.ChannelHandlerContext> handler)
      Specified by:
      deregister in interface org.geysermc.floodgate.core.api.packet.PacketHandlers<io.netty.channel.ChannelHandlerContext>
    • getPacketHandlers

      public Collection<org.geysermc.floodgate.api.util.TriFunction<io.netty.channel.ChannelHandlerContext,Object,Boolean,Object>> getPacketHandlers(Class<?> packet)
    • hasHandlers

      public boolean hasHandlers()