SocketConnectionOptions class
A comprehensive class for all socket connection options.
Constructors
-
SocketConnectionOptions({String? path, List<
String> ? transports, bool? reconnection, int? reconnectionAttempts, int? reconnectionDelay, int? reconnectionDelayMax, double? randomizationFactor, int? timeout, String? query, Map<String, String> ? auth, bool? secure, bool? forceNew, ExtraIOSSocketOptions? extraIOSConfig, ExtraAndroidSocketOptions? androidConfig})
Properties
- androidConfig → ExtraAndroidSocketOptions?
-
final
-
auth
→ Map<
String, String> ? -
Authentication data to send with the connection.
final
- extraIOSConfig → ExtraIOSSocketOptions?
-
final
- forceNew → bool?
-
If true, creates a new connection, bypassing any existing multiplexed connection.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- path → String?
-
The path on the server to connect to.
final
- query → String?
-
Extra query parameters to send with the connection request.
final
- randomizationFactor → double?
-
A factor to randomize the reconnection delay. e.g., 0.5.
final
- reconnection → bool?
-
Whether to automatically reconnect on disconnection.
final
- reconnectionAttempts → int?
-
Number of reconnection attempts. Use -1 for infinite.
final
- reconnectionDelay → int?
-
Delay between reconnection attempts (in milliseconds).
final
- reconnectionDelayMax → int?
-
Maximum delay between reconnection attempts (in milliseconds).
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- secure → bool?
-
Whether to use a secure connection (wss/https).
final
- timeout → int?
-
Connection timeout duration (in milliseconds).
final
-
transports
→ List<
String> ? -
A list of transports to use. e.g.,
'websocket', 'polling'.final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toMap(
) → Map< String, dynamic> - Converts this object into a map for the platform channel.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited