Class LogLevelExtensions

Helper methods for log level handling.

Inheritance
System.Object LogLevelExtensions
Inherited Members
System.Object.ToString() System.Object.Equals(System.Object) System.Object.Equals(System.Object, System.Object) System.Object.ReferenceEquals(System.Object, System.Object) System.Object.GetHashCode() System.Object.GetType() System.Object.MemberwiseClone()
Namespace: BepInEx.Logging
Assembly: BepInEx.dll
Syntax
public static class LogLevelExtensions

Methods

GetConsoleColor(LogLevel)

Returns a translation of a log level to it's associated console colour.

Declaration
public static ConsoleColor GetConsoleColor(this LogLevel level)
Parameters
Type Name Description
LogLevel level

The log level(s).

Returns
Type Description
System.ConsoleColor

A console color associated with the highest log level supplied.

GetHighestLevel(LogLevel)

Gets the highest log level when there could potentially be multiple levels provided.

Declaration
public static LogLevel GetHighestLevel(this LogLevel levels)
Parameters
Type Name Description
LogLevel levels

The log level(s).

Returns
Type Description
LogLevel

The highest log level supplied.