StompConfig class
Constructors
-
StompConfig({required String url, Duration reconnectDelay = const Duration(seconds: 5), Duration heartbeatIncoming = const Duration(seconds: 5), Duration heartbeatOutgoing = const Duration(seconds: 5), Duration connectionTimeout = const Duration(), Map<
String, String> ? stompConnectHeaders, Map<String, dynamic> ? webSocketConnectHeaders, StompBeforeConnectCallback beforeConnect = _noOpFuture, StompFrameCallback onConnect = _noOp, StompFrameCallback onStompError = _noOp, StompFrameCallback onDisconnect = _noOp, StompFrameCallback onUnhandledFrame = _noOp, StompFrameCallback onUnhandledMessage = _noOp, StompFrameCallback onUnhandledReceipt = _noOp, StompWebSocketErrorCallback onWebSocketError = _noOp, StompWebSocketDoneCallback onWebSocketDone = _noOp, StompDebugCallback onDebugMessage = _noOp, bool useSockJS = false}) -
const
-
StompConfig.SockJS({required String url, Duration reconnectDelay = const Duration(seconds: 5), Duration heartbeatIncoming = const Duration(seconds: 5), Duration heartbeatOutgoing = const Duration(seconds: 5), Duration connectionTimeout = const Duration(), Map<
String, String> ? stompConnectHeaders, Map<String, dynamic> ? webSocketConnectHeaders, StompBeforeConnectCallback beforeConnect = _noOpFuture, StompFrameCallback onConnect = _noOp, StompFrameCallback onStompError = _noOp, StompFrameCallback onDisconnect = _noOp, StompFrameCallback onUnhandledFrame = _noOp, StompFrameCallback onUnhandledMessage = _noOp, StompFrameCallback onUnhandledReceipt = _noOp, StompWebSocketErrorCallback onWebSocketError = _noOp, StompWebSocketDoneCallback onWebSocketDone = _noOp, StompDebugCallback onDebugMessage = _noOp})
Properties
- beforeConnect → StompBeforeConnectCallback
-
Asynchronous function to be executed before we connect
the socket
final
- connectionTimeout → Duration
-
Connection timeout. If specified the connection will will be dropped after
the timeout and depending on the reconnectDelay it will try again
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- heartbeatIncoming → Duration
-
Time between incoming heartbeats
Set to a duration with 0 milliseconds to not receive any heartbeats
final
- heartbeatOutgoing → Duration
-
Time between outgoing heartbeats
Set to a duration with 0 milliseconds to not send any heartbeats
final
- onConnect → StompFrameCallback
-
Callback for when STOMP has successfully connected
final
- onDebugMessage → StompDebugCallback
-
Callback for debug messages
final
- onDisconnect → StompFrameCallback
-
Callback for when STOMP has disconnected
final
- onStompError → StompFrameCallback
-
Callback for any errors encountered with STOMP
final
- onUnhandledFrame → StompFrameCallback
-
Error callback for unhandled STOMP frames
final
- onUnhandledMessage → StompFrameCallback
-
Error callback for unhandled messages inside a frame
final
- onUnhandledReceipt → StompFrameCallback
-
Error callback for unhandled message receipts
final
- onWebSocketDone → StompWebSocketDoneCallback
-
Callback when the underlying WebSocket connection is done/closed
final
- onWebSocketError → StompWebSocketErrorCallback
-
Error callback for any errors with the underlying WebSocket
final
- reconnectDelay → Duration
-
Time between reconnect attempts
Set to a duration with 0 milliseconds if you don't want to reconnect
automatically
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
stompConnectHeaders
→ Map<
String, String> ? -
Optional Headers to be passed when connecting to STOMP
final
- url → String
-
The url of the WebSocket to connect to
final
- useSockJS → bool
-
Whether to use SockJS
final
-
webSocketConnectHeaders
→ Map<
String, dynamic> ? -
Optional Headers to be passed when connecting to WebSocket
final
Methods
-
copyWith(
{String? url, Duration? reconnectDelay, Duration? heartbeatIncoming, Duration? heartbeatOutgoing, Duration? connectionTimeout, bool? useSockJS, Map< String, String> ? stompConnectHeaders, Map<String, dynamic> ? webSocketConnectHeaders, StompBeforeConnectCallback? beforeConnect, StompFrameCallback? onConnect, StompFrameCallback? onStompError, StompFrameCallback? onDisconnect, StompFrameCallback? onUnhandledFrame, StompFrameCallback? onUnhandledMessage, StompFrameCallback? onUnhandledReceipt, StompWebSocketErrorCallback? onWebSocketError, StompWebSocketDoneCallback? onWebSocketDone, StompDebugCallback? onDebugMessage}) → StompConfig -
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