Sha256: 57f39e4d86c5843ea7d57620370766377f0299e6a7bd66832b5a566c1ecfa081
Contents?: true
Size: 921 Bytes
Versions: 2
Compression:
Stored size: 921 Bytes
Contents
module Rubyipmi module Ipmitool class ErrorCodes CODES = { "Authentication type NONE not supported\nAuthentication type NONE not supported\n" \ "Error: Unable to establish LAN session\nGet Device ID command failed\n" => {"I" => "lanplus"}, "Authentication type NONE not supported" => {"I" => "lanplus"}, "Error: Unable to establish LAN session\nGet Device ID command failed\n" => {"I" => "lanplus"} } def self.length CODES.length end def self.code CODES end def self.search(code) fix = CODES.fetch(code, nil) if fix.nil? CODES.each do |error, result| # the error should be a subset of the actual erorr return result if code =~ /.*#{error}.*/i end else return fix end raise "No Fix found" if fix.nil? end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
rubyipmi-0.11.1 | lib/rubyipmi/ipmitool/errorcodes.rb |
rubyipmi-0.11.0 | lib/rubyipmi/ipmitool/errorcodes.rb |