Class: OpenSCAP::Xccdf::Fix

Inherits:
Object
  • Object
show all
Defined in:
lib/openscap/xccdf/fix.rb

Instance Method Summary collapse

Constructor Details

#initialize(raw) ⇒ Fix

Returns a new instance of Fix.



6
7
8
9
10
# File 'lib/openscap/xccdf/fix.rb', line 6

def initialize raw
  raise OpenSCAP::OpenSCAPError, "Cannot initialize #{self.class.name} with '#{raw}'" unless raw.is_a? FFI::Pointer

  @raw = raw
end

Instance Method Details

#complexityObject



19
# File 'lib/openscap/xccdf/fix.rb', line 19

def complexity = OpenSCAP.xccdf_fix_get_complexity @raw

#contentObject



15
# File 'lib/openscap/xccdf/fix.rb', line 15

def content = OpenSCAP.xccdf_fix_get_content @raw

#disruptionObject



18
# File 'lib/openscap/xccdf/fix.rb', line 18

def disruption = OpenSCAP.xccdf_fix_get_disruption @raw

#fix_systemObject



14
# File 'lib/openscap/xccdf/fix.rb', line 14

def fix_system = OpenSCAP.xccdf_fix_get_system @raw

#idObject



12
# File 'lib/openscap/xccdf/fix.rb', line 12

def id = OpenSCAP.xccdf_fix_get_id @raw

#platformObject



13
# File 'lib/openscap/xccdf/fix.rb', line 13

def platform = OpenSCAP.xccdf_fix_get_platform @raw

#rebootObject



16
# File 'lib/openscap/xccdf/fix.rb', line 16

def reboot = OpenSCAP.xccdf_fix_get_reboot @raw

#strategyObject



17
# File 'lib/openscap/xccdf/fix.rb', line 17

def strategy = OpenSCAP.xccdf_fix_get_strategy @raw

#to_hashObject



21
22
23
# File 'lib/openscap/xccdf/fix.rb', line 21

def to_hash
  { id:, platform:, system: fix_system, content: }
end