Package com.toxi.net
Interface ClientListener
public interface ClientListener
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Callback to give the client a chance to react to the encountered exception.void
Callback to confirm client has successfully connectedvoid
Callback to notify client has disconnected from the server.void
Callback to trigger the rendering of a new frame.void
Callback to trigger an update of the server managed process.
-
Method Details
-
triggerUpdate
void triggerUpdate()Callback to trigger an update of the server managed process. This might be called several times in a row if the client has fallen behind in time. There should be NO rendering related tasks being called from this callback. -
triggerFrame
void triggerFrame()Callback to trigger the rendering of a new frame. This method will ALWAYS be called after {triggerUpdate()
and should be purely focused on drawing/rendering specific tasks, but no CPU intensive model updates. -
notifyConnected
void notifyConnected()Callback to confirm client has successfully connected -
notifyDisconnected
void notifyDisconnected()Callback to notify client has disconnected from the server. -
handleError
Callback to give the client a chance to react to the encountered exception.- Parameters:
e
- the exception which caused the callback
-