PusherConnector constructor
PusherConnector(
- String key, {
- required String authEndPoint,
- Map<
String, String> authHeaders = const {'Content-Type' : 'application/json'}, - String? cluster,
- String host = "ws.pusherapp.com",
- int wsPort = 80,
- int wssPort = 443,
- bool encrypted = true,
- int activityTimeout = 120000,
- int pongTimeout = 30000,
- int maxReconnectionAttempts = 6,
- int maxReconnectGapInSeconds = 30,
- bool enableLogging = true,
- bool autoConnect = true,
- String? nameSpace,
Implementation
PusherConnector(
String key, {
required String authEndPoint,
Map<String, String> authHeaders = const {
'Content-Type': 'application/json'
},
String? cluster,
String host = "ws.pusherapp.com",
int wsPort = 80,
int wssPort = 443,
bool encrypted = true,
int activityTimeout = 120000,
int pongTimeout = 30000,
int maxReconnectionAttempts = 6,
int maxReconnectGapInSeconds = 30,
bool enableLogging = true,
bool autoConnect = true,
String? nameSpace,
}) : super(
ConnectorOptions(
client: PusherClient(
key,
PusherOptions(
auth: PusherAuth(authEndPoint, headers: authHeaders),
cluster: cluster,
host: host,
wsPort: wsPort,
wssPort: wssPort,
encrypted: encrypted,
activityTimeout: activityTimeout,
pongTimeout: pongTimeout,
maxReconnectionAttempts: maxReconnectionAttempts,
maxReconnectGapInSeconds: maxReconnectGapInSeconds,
),
enableLogging: enableLogging,
autoConnect: autoConnect,
),
nameSpace: nameSpace),
);