OnDisconnect class

What the server should do with path if this client goes away without saying goodbye.

Registered with the server now and carried out by it on disconnect, which is the only cleanup that survives a device losing power rather than shutting down — nothing on the device gets to run at that point.

The future completes when the registration lands. Whether the server later carries it out is not something a client can observe.

Constructors

OnDisconnect(String path, {String? app})
For path on the default app, or on the named one app.
const

Properties

app → String?
The app whose Database this is registered with; null is the default.
final
hashCode → int
The hash code for this object.
no setterinherited
path → String
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

cancel() → Future<void>
Drops every registration for path, not only the last one.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
remove() → Future<void>
Removes path on disconnect. The usual way to clear a presence marker.
setValue(Object? value) → Future<void>
Writes value on disconnect.
setValueWithPriority(Object? value, Object? priority) → Future<void>
Writes value with priority on disconnect, in one operation.
toString() → String
A string representation of this object.
inherited
updateChildren(Map<String, Object?> value) → Future<void>
Writes the named children on disconnect, leaving the rest.

Operators

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