Class: OpenscapParser::Benchmark
Instance Attribute Summary
Attributes inherited from XmlNode
#namespaces
Instance Method Summary
collapse
Methods included from Values
included
Methods included from Groups
included
Methods included from Profiles
included
included
Methods included from Rules
included
Methods included from Util
#newline_to_whitespace
Methods inherited from XmlNode
#initialize, #parsed_xml, #text, #xpath_node, #xpath_nodes
Instance Method Details
#description ⇒ Object
30
31
32
33
34
35
|
# File 'lib/openscap_parser/benchmark.rb', line 30
def description
@description ||= newline_to_whitespace(
@parsed_xml.xpath('description') &&
@parsed_xml.xpath('description').text || ''
)
end
|
#id ⇒ Object
21
22
23
|
# File 'lib/openscap_parser/benchmark.rb', line 21
def id
@id ||= @parsed_xml['id']
end
|
#title ⇒ Object
25
26
27
28
|
# File 'lib/openscap_parser/benchmark.rb', line 25
def title
@title ||= @parsed_xml.xpath('title') &&
@parsed_xml.xpath('title').text
end
|
#version ⇒ Object
37
38
39
40
|
# File 'lib/openscap_parser/benchmark.rb', line 37
def version
@version ||= @parsed_xml.xpath('version') &&
@parsed_xml.xpath('version').text
end
|