level property

LoggingLevel get level

The level of logging that the client wants to receive from the server.

The server should send all logs at this level and higher (i.e., more severe) to the client as notifications/message.

Implementation

LoggingLevel get level {
  final levelName = _value['level'];
  final foundLevel = LoggingLevel.values.firstWhereOrNull(
    (level) => level.name == levelName,
  );
  if (foundLevel == null) {
    throw ArgumentError(
      "Invalid level field in $SetLevelRequest: didn't find level $levelName",
    );
  }
  return foundLevel;
}