disconnect method

  1. @override
Future<EventFluxStatus> disconnect()
override

Disconnects from the event stream.

Closes the HTTP client and the stream controller. Returns the disconnection status enum.

Usage Example:

EventFluxStatus disconnectStatus = await EventFlux.instance.disconnect();
print(disconnectStatus.name);

Implementation

@override
Future<EventFluxStatus> disconnect() async {
  _isExplicitDisconnect = true;
  return await _stop();
}