Class: OpenSCAP::Xccdf::Fix
- Inherits:
-
Object
- Object
- OpenSCAP::Xccdf::Fix
- Defined in:
- lib/openscap/xccdf/fix.rb
Instance Method Summary collapse
- #content ⇒ Object
-
#fix_system ⇒ Object
system is a reserved word in Rails, so didn’t use it.
- #id ⇒ Object
-
#initialize(raw) ⇒ Fix
constructor
A new instance of Fix.
- #platform ⇒ Object
- #to_hash ⇒ Object
Constructor Details
#initialize(raw) ⇒ Fix
Returns a new instance of Fix.
6 7 8 9 10 11 |
# 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
#content ⇒ Object
26 27 28 |
# File 'lib/openscap/xccdf/fix.rb', line 26 def content OpenSCAP.xccdf_fix_get_content(@raw) end |
#fix_system ⇒ Object
system is a reserved word in Rails, so didn’t use it
22 23 24 |
# File 'lib/openscap/xccdf/fix.rb', line 22 def fix_system OpenSCAP.xccdf_fix_get_system(@raw) end |
#id ⇒ Object
13 14 15 |
# File 'lib/openscap/xccdf/fix.rb', line 13 def id OpenSCAP.xccdf_fix_get_id(@raw) end |
#platform ⇒ Object
17 18 19 |
# File 'lib/openscap/xccdf/fix.rb', line 17 def platform OpenSCAP.xccdf_fix_get_platform(@raw) end |
#to_hash ⇒ Object
30 31 32 33 34 35 36 37 |
# File 'lib/openscap/xccdf/fix.rb', line 30 def to_hash { :id => id, :platform => platform, :system => fix_system, :content => content } end |