Disposable mixin

Signifies that the implementing type holds resource (i.e. sockets, streams) that need to be manually disposed.

Attempting to use an implementing instance after it has been disposed is undefined behaviour.

This is in lieu of Dart refusing to provide a standardized Disposable interface for the foreseeable future, https://github.com/dart-lang/sdk/issues/43490.

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

dispose() → void
Disposes the resources held by an implementing type.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited