Parent

Methods

KASPAuditor::ChangedConfig::Element

This class holds some data, along with the timestamp at which is was last seen to change

Attributes

timestamp[RW]
value[R]

Public Class Methods

new(*args) click to toggle source

e.g. Element.new(3) Element.new(3, Time.now.to_i)

# File ../../auditor/lib/kasp_auditor/changed_config.rb, line 46
def initialize(*args)
  @timestamp = 0
  if (args.length >= 1)
    @value = args[0]
    if (args.length == 2)
      @timestamp = args[1]
    end
  end
end

Public Instance Methods

to_s() click to toggle source
# File ../../auditor/lib/kasp_auditor/changed_config.rb, line 55
def to_s
  if (@value.class == Array)
    ret = ""
    @value.each {|v|
      ret += "#{v}, "
    }
    ret += "#{@timestamp}"
    return ret
  else
    return "#{@value}, #{@timestamp}"
  end
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.