public interface ProtocolListener
The Protocol class provides an event for error reporting (see Protocol.addListener). The error event is only used when operating in asynchronous mode (see Protocol.isValidOption). When operating in normal blocking mode, the error event is never fired and exceptions are reported by throwing them.
| Modifier and Type | Method and Description |
|---|---|
void |
onError(ErrorEvent e)
This event is fired after an error occurred when operating in asynchronous mode.
|
void onError(ErrorEvent e)
This event is fired when an error occurs in asynchronous mode (see Protocol.isValidOption(java.lang.String)).
Instead of throwing exceptions when an operation has failed like in normal blocking mode, the asynchronous mode uses
this error event for error reporting.
Please note: Keep in mind that adding code to the event handlers which can lead to the error event can cause a presumably undesired recursive behavior.
e - The event argument for the event handlerErrorEventCopyright © 2023. All rights reserved.