Rubyipmi::Freeipmi::Fru

Constants

DEFAULT_FRU

Attributes

list[RW]

Public Class Methods

new(opts = ObservableHash.new) click to toggle source
# File lib/rubyipmi/freeipmi/commands/fru.rb, line 9
def initialize(opts = ObservableHash.new)
    super("ipmi-fru", opts)
    @list = {}
end

Public Instance Methods

board_serial() click to toggle source
# File lib/rubyipmi/freeipmi/commands/fru.rb, line 29
def board_serial
  get_from_list('board_serial_number')
end
get_from_list(key) click to toggle source
# File lib/rubyipmi/freeipmi/commands/fru.rb, line 14
def get_from_list(key)
  if list.has_key?(DEFAULT_FRU)
    if list[DEFAULT_FRU].has_key?(key)
       list[DEFAULT_FRU][key]
     else
       nil
     end
  end
end
getfrus() click to toggle source

method to retrieve the raw fru data

# File lib/rubyipmi/freeipmi/commands/fru.rb, line 42
def getfrus
  command
  return @result
end
manufacturer() click to toggle source
# File lib/rubyipmi/freeipmi/commands/fru.rb, line 25
def manufacturer
  get_from_list('board_manufacturer')
end
model() click to toggle source
# File lib/rubyipmi/freeipmi/commands/fru.rb, line 37
def model
  get_from_list('board_product_name')
end
names() click to toggle source
# File lib/rubyipmi/freeipmi/commands/fru.rb, line 47
def names
  list.keys
end
serial() click to toggle source
# File lib/rubyipmi/freeipmi/commands/fru.rb, line 33
def serial
  get_from_list('board_serial_number')
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.