Interface IPacketHandler
- All Known Implementing Classes:
 NetworkRegistry.ClientPacketHandler,NetworkRegistry.ServerPacketHandler
public interface IPacketHandler
Describes a handler for a packet.
 Allows for the handling of full packets from custom payloads
- 
Method Summary
Modifier and TypeMethodDescriptionvoiddisconnect(Component reason) Trigger a disconnect from the network.voidhandle(CustomPacketPayload payload) Invoked to handle the given custom payload.voidInvoked to handle the given packet. 
- 
Method Details
- 
handle
Invoked to handle the given packet.- Parameters:
 packet- The packet.
 - 
handle
Invoked to handle the given custom payload.- Parameters:
 payload- The payload.
 - 
disconnect
Trigger a disconnect from the network.- Parameters:
 reason- The reason for the disconnect.
 
 -