onDisconnected method
- Device device,
- bool isError,
- Object error,
- StackTrace stackTrace
When the socket connection closes either normally or due to an error,
this method is called. If the connection closed without error, isError
will be false. If an error occurred, you can retrieve the error using
error
. stackTrace
may be null is the error provider does not send one.
device
contains the object to the Device that was disconnected.
If device
is null, this means that the Host was unable to start the socket.
Implementation
void onDisconnected(Device device, bool isError, Object error, StackTrace stackTrace);