Package com.kristensoft.kdc
Interface UdpClientEventHandler
-
- All Known Implementing Classes:
UdpClientEventAdapter
public interface UdpClientEventHandlerDefines event callbacks for monitoring the operation of aUdpClient.Implementations may be registered with a UDP client to receive notifications for socket lifecycle events, datagram sends, and agent communication events. Implementing this interface is optional and is not required for normal UDP client operation.
- Author:
- Charles B. Kozoyed
- See Also:
UdpClient,UdpClientEventAdapter
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidonDatagramSent(DatagramPacket datagram)Called after a UDP datagram has been sent.voidonReceivedAgent(Agent agent)Called when an agent has been received.voidonSendingAsyncAgent(Agent agent)Called when an asynchronous agent is being sent.voidonSocketClosed(UdpClient udpClient)Called when the UDP socket has been closed.voidonSocketCreated(DatagramSocket socket)Called when the UDP socket has been created.
-
-
-
Method Detail
-
onSocketCreated
void onSocketCreated(DatagramSocket socket)
Called when the UDP socket has been created.- Parameters:
socket- the created UDP socket
-
onSocketClosed
void onSocketClosed(UdpClient udpClient)
Called when the UDP socket has been closed.- Parameters:
udpClient- the UDP client whose socket was closed
-
onDatagramSent
void onDatagramSent(DatagramPacket datagram)
Called after a UDP datagram has been sent.- Parameters:
datagram- the datagram that was sent
-
onReceivedAgent
void onReceivedAgent(Agent agent)
Called when an agent has been received.- Parameters:
agent- the received agent
-
onSendingAsyncAgent
void onSendingAsyncAgent(Agent agent)
Called when an asynchronous agent is being sent.- Parameters:
agent- the agent being sent
-
-