connectViewer static method

LogError connectViewer({
  1. required String address,
  2. void onConnect(
    1. LogError
    )?,
  3. void onReceive(
    1. dynamic
    )?,
  4. void onError(
    1. String
    )?,
})

Implementation

static LogError connectViewer(
    {required String address,
    void Function(LogError)? onConnect,
    void Function(dynamic)? onReceive,
    void Function(String)? onError}) {
  return isCriticalMode
      ? LogError(-5, message: 'is in critical mode')
      : loggerManager.connectViewer(
          address: address,
          onConnect: onConnect,
          onReceive: onReceive,
          onError: onError);
}