Class: Mack::Utils::HttpStatusCodes

Inherits:
RegistryMap
  • Object
show all
Defined in:
lib/mack/utils/http_status_codes.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.get(status) ⇒ Object



11
12
13
# File 'lib/mack/utils/http_status_codes.rb', line 11

def get(status)
  self.registered_items[status.to_i] || 'UNKNOWN HTTP STATUS'
end

Instance Method Details

#initial_stateObject



5
6
7
# File 'lib/mack/utils/http_status_codes.rb', line 5

def initial_state
  YAML.load(File.read(File.join(File.dirname(__FILE__), 'http_status_codes.yml')))
end