BaseTransport class abstract

Base implementation of Transport with common functionality

Implemented types
Implementers

Constructors

BaseTransport()
Constructor

Properties

connected → bool
Whether this transport is currently connected
no setteroverride
connectionStateStream → Stream<bool>
Stream of connection state changes
no setteroverride
errorStream → Stream<FayeError>
Stream of errors
no setteroverride
hashCode → int
The hash code for this object.
no setterinherited
messageStream → Stream<Map<String, dynamic>>
Stream of messages received from the transport
no setteroverride
name → String
Transport name
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
statistics → Map<String, dynamic>
Get transport statistics
no setteroverride
supported → bool
Whether this transport is supported
no setterinherited
timeout ↔ int
Connection timeout in seconds
getter/setter pairoverride

Methods

close() → Future<void>
Close the transport
override
connect(String url, {Map<String, String>? headers}) → Future<void>
Connect to the server
inherited
disconnect() → Future<void>
Disconnect from the server
inherited
emitError(FayeError error) → void
Emit an error
emitMessage(Map<String, dynamic> message) → void
Emit a message
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
recordConnectTime(int milliseconds) → void
Record connection time
recordMessageSent(Map<String, dynamic> message) → void
Record message sent
send(Map<String, dynamic> message) → Future<void>
Send a message to the server
inherited
sendBatch(List<Map<String, dynamic>> messages) → Future<void>
Send multiple messages to the server
inherited
toString() → String
A string representation of this object.
override
updateConnectionState(bool connected) → void
Update connection state
updateLastActivity() → void
Update last activity timestamp

Operators

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