SFClient constructor
SFClient({
- required Host host,
- required SFClientConfig config,
- PubSub? pubsub,
- PayloadEncryptor? encryptor,
Implementation
SFClient({
required this.host,
required this.config,
this.pubsub,
this.encryptor,
}) {
if (!config.isValid()) {
throw ArgumentError('Invalid client configuration');
}
_serverSelector = ServerSelector(host: host);
_messageSender = MessageSender(
host: host,
config: config,
serverSelector: _serverSelector,
);
_mailboxManager = MailboxManager(
host: host,
config: config,
);
}