enum

ModelContextProtocol::Server::Utilities::Logging::Level

Inherits Enum < Comparable < Value < Object

Constants

Debug = 0
Info = 1
Notice = 2
Warning = 3
Error = 4
Critical = 5
Alert = 6
Emergency = 7

Constructors

from_string(level : String) : Level
Source

Instance methods

alert?

Returns true if this enum value equals Alert

Source
critical?

Returns true if this enum value equals Critical

Source
debug?

Returns true if this enum value equals Debug

Source
emergency?

Returns true if this enum value equals Emergency

Source
error?

Returns true if this enum value equals Error

Source
info?

Returns true if this enum value equals Info

Source
notice?

Returns true if this enum value equals Notice

Source
to_s

Returns a String representation of this enum member. In the case of regular enums, this is just the name of the member. In the case of flag enums, it's the names joined by vertical bars, or "None", if the value is zero.

If an enum's value doesn't match a member's value, the raw value is returned as a string.

Color::Red.to_s                     # => "Red"
IOMode::None.to_s                   # => "None"
(IOMode::Read | IOMode::Write).to_s # => "Read | Write"

Color.new(10).to_s # => "10"
Source
warning?

Returns true if this enum value equals Warning

Source