setLogLevel static method

Future<void> setLogLevel(
  1. LogLevel logLevel
)

You can change the log level to one of the followings:

Implementation

static Future<void> setLogLevel(final LogLevel logLevel) async {
  String logLevelStr;
  switch (logLevel) {
    case LogLevel.debug:
      logLevelStr = 'Debug';
      break;
    case LogLevel.info:
      logLevelStr = 'Info';
      break;
    case LogLevel.warn:
      logLevelStr = 'Warn';
      break;
    case LogLevel.error:
      logLevelStr = 'Error';
      break;
  }
  await _invokeMethod('setLogLevel', logLevelStr);
}