AcpServerConnectionRegistry class final

Tracks pending-handshake and active remote ACP connections.

Constructors

AcpServerConnectionRegistry({String createConnectionId()?})
Creates a registry.

Properties

activeCount int
Number of active, publicly routable connections.
no setter
hashCode int
The hash code for this object.
no setterinherited
isClosed bool
Whether this registry has begun terminal shutdown.
no setter
pendingCount int
Number of connections still completing their handshake.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

activate(String connectionId) AcpServerConnectionState
Publishes a pending connection after successful initialization.
addPending(AcpServerConnectionState state) → void
Adds state as a non-routable pending handshake.
addReservedPending(AcpServerConnectionState state) → void
Publishes state into the pending map using its reserved ID.
closeAll([Object? reason]) Future<void>
Clears the registry first, then waits for every state to close.
discard(String connectionId, [Object? reason]) Future<bool>
Discards and closes an active or pending connection.
lookup(String connectionId) AcpServerConnectionState?
Finds only an initialized active connection.
nextConnectionId() String
Generates an ID not used by an active or pending state.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
releaseConnectionId(String connectionId) → void
Releases an unused asynchronous handshake reservation.
remove(String connectionId, [Object? reason]) Future<bool>
Removes and closes one active connection.
reserveConnectionId() String
Atomically reserves a unique ID for an asynchronous connection factory.
toString() String
A string representation of this object.
inherited

Operators

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