Dart API Referencedart:ioCloseEvent

CloseEvent abstract class

Event delivered when a web socket connection is closed.

abstract class CloseEvent extends Event {
  /**
   * Returns whether the connection was closed cleanly or not.
   */
  bool get wasClean;

  /**
   * Returns the web socket connection close code provided by the
   * server.
   */
  int get code;

  /**
   * Returns the web socket connection close reason provided by the
   * server.
   */
  String get reason;
}

Extends

Event > CloseEvent

Properties

final int code #

Returns the web socket connection close code provided by the server.

int get code;

final String reason #

Returns the web socket connection close reason provided by the server.

String get reason;

final bool wasClean #

Returns whether the connection was closed cleanly or not.

bool get wasClean;