Class: AbideDevUtils::XCCDF::Parser::Objects::ControlURI
- Inherits:
-
ElementBase
- Object
- ElementBase
- AbideDevUtils::XCCDF::Parser::Objects::ControlURI
- Defined in:
- lib/abide_dev_utils/xccdf/parser/objects.rb
Overview
Class for XCCDF Ident ControlURI element
Constant Summary
Constants inherited from ElementBase
Instance Attribute Summary collapse
-
#namespace ⇒ Object
readonly
Returns the value of attribute namespace.
-
#value ⇒ Object
readonly
Returns the value of attribute value.
Attributes inherited from ElementBase
#child_labels, #children, #link_labels, #links, #parent
Instance Method Summary collapse
- #eql?(other) ⇒ Boolean
- #hash ⇒ Object
-
#initialize(element, parent_node: nil) ⇒ ControlURI
constructor
A new instance of ControlURI.
- #to_s ⇒ Object
Methods inherited from ElementBase
#<=>, #add_link, #add_links, #all_values, #ancestors, #depth, #descendants, #find_similarity, #inspect, #label, #leaf?, #print_tree, #root, #root?, #siblings, #xccdf_type, xmlns, xpath
Methods included from Helpers::XPath
Methods included from DiffableObject
#check_diffable!, #correlate_added_removed, #diff, #diff_ambiguous, #diff_array_obj, #diff_benchmark, #diff_change_result, #diff_check, #diff_complex_check, #diff_group, #diff_plain_obj, #diff_profile, #diff_rule, #diff_str_obj, #diff_value, #diff_xccdf_select, #process_details_hash!, #result_from_details_hash
Constructor Details
#initialize(element, parent_node: nil) ⇒ ControlURI
Returns a new instance of ControlURI.
553 554 555 556 557 |
# File 'lib/abide_dev_utils/xccdf/parser/objects.rb', line 553 def initialize(element, parent_node: nil) super @namespace = element.attributes['controlURI'].namespace.prefix @value = element.attributes['controlURI'].value end |
Instance Attribute Details
#namespace ⇒ Object (readonly)
Returns the value of attribute namespace.
551 552 553 |
# File 'lib/abide_dev_utils/xccdf/parser/objects.rb', line 551 def namespace @namespace end |
#value ⇒ Object (readonly)
Returns the value of attribute value.
551 552 553 |
# File 'lib/abide_dev_utils/xccdf/parser/objects.rb', line 551 def value @value end |
Instance Method Details
#eql?(other) ⇒ Boolean
559 560 561 |
# File 'lib/abide_dev_utils/xccdf/parser/objects.rb', line 559 def eql?(other) to_s == other.to_s end |
#hash ⇒ Object
563 564 565 |
# File 'lib/abide_dev_utils/xccdf/parser/objects.rb', line 563 def hash to_s.hash end |
#to_s ⇒ Object
567 568 569 |
# File 'lib/abide_dev_utils/xccdf/parser/objects.rb', line 567 def to_s [label, @namespace, @value].join(':') end |