enum

Lid::Severity

Inherits Enum < Comparable < Value < Object

Constants

Critical = 0
High = 1
Medium = 2
Low = 3
Info = 4

Constructors

parse(s : String) : Severity
Source

Instance methods

color_code
Source
critical?

Returns true if this enum value equals Critical

Source
high?

Returns true if this enum value equals High

Source
info?

Returns true if this enum value equals Info

Source
low?

Returns true if this enum value equals Low

Source
medium?

Returns true if this enum value equals Medium

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