ClientGate class

Inheritance

Constructors

ClientGate()

Properties

delegate PorterDelegate?
getter/setter pairinherited
hashCode int
The hash code for this object.
no setterinherited
hub ClientHub?
getter/setter pairinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

allPorters() Iterable<Porter>
inherited
cleanupPorters(Iterable<Porter> porters) Future<void>
inherited
createPorter({required SocketAddress remote, SocketAddress? local}) Porter
Create new porter for received data
override
createPorterPool() AddressPairMap<Porter>
inherited
dock(Connection connection, bool newPorter) Future<Porter?>
inherited
drivePorters(Iterable<Porter> porters) Future<int>
inherited
fetchPorter({required SocketAddress remote, SocketAddress? local}) Future<Porter?>
inherited
getPorter({required SocketAddress remote, SocketAddress? local}) Porter?
override
heartbeat(Connection connection) Future<void>
Send a heartbeat package('PING') to remote address
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
onConnectionError(IOError error, Connection connection) Future<void>
Called when connection (receiving) error
inherited
onConnectionFailed(IOError error, Uint8List data, Connection connection) Future<void>
Called when failed to send data via the connection
inherited
onConnectionReceived(Uint8List data, Connection connection) Future<void>
Called when connection received data
inherited
onConnectionSent(int sent, Uint8List data, Connection connection) Future<void>
Called after data sent via the connection
inherited
onConnectionStateChanged(ConnectionState? previous, ConnectionState? current, Connection connection) Future<void>
Called when connection state is changed
inherited
process() Future<bool>
Do the job
inherited
removePorter(Porter? porter, {required SocketAddress remote, SocketAddress? local}) Porter?
override
sendData(Uint8List payload, {required SocketAddress remote, SocketAddress? local}) Future<bool>
Pack data to an outgo ship (with normal priority), and append to the waiting queue of porter for remote address
inherited
sendResponse(Uint8List payload, Arrival ship, {required SocketAddress remote, SocketAddress? local}) Future<bool>
inherited
sendShip(Departure outgo, {required SocketAddress remote, SocketAddress? local}) Future<bool>
Append outgo ship (carrying data package, with priority) to the waiting queue of porter for remote address
inherited
setPorter(Porter porter, {required SocketAddress remote, SocketAddress? local}) Porter?
override
toString() String
A string representation of this object.
inherited

Operators

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