Interface RequestPacketResponse<R extends Packet>
- Type Parameters:
R
- The response packet type
public interface RequestPacketResponse<R extends Packet>
Represents a callback for the response of a request packet.
-
Method Summary
Modifier and TypeMethodDescriptionvoid
fail
(ChannelException exception) Sets the response of the request packet as failed with the givenChannelException
.void
Sets the response of the request packet as success with the given response packet.
-
Method Details
-
fail
Sets the response of the request packet as failed with the givenChannelException
.If this response fails, then will other side of the connection end up with a
NoResponseException
.- Parameters:
exception
- The exception
-
success
Sets the response of the request packet as success with the given response packet.- Parameters:
response
- The response packet
-