enum Ameba::Severity

Defined in:

ameba/severity.cr

Enum Members

Error = 0
Warning = 1
Convention = 2

Class Method Summary

Instance Method Summary

Class Method Detail

def self.parse(name : String) #

Creates Severity by the name.

Severity.parse("convention") # => Severity::Convention
Severity.parse("foo-bar")    # => Exception: Incorrect severity name

[View source]

Instance Method Detail

def color : Colorize::Color #

Returns a color uniquely indicating severity.

Severity::Warning.color # => Colorize::ColorANSI::Red

[View source]
def convention? #

[View source]
def error? #

[View source]
def symbol : Char #

Returns a symbol uniquely indicating severity.

Severity::Warning.symbol # => 'W'

[View source]
def warning? #

[View source]