Class: AbideDevUtils::XCCDF::Profile

Inherits:
XccdfElement show all
Defined in:
lib/abide_dev_utils/xccdf.rb

Constant Summary

Constants included from Common

Common::CIS_CONTROL_NUMBER, Common::CIS_CONTROL_PARTS, Common::CIS_LEVEL_CODE, Common::CIS_NEXT_GEN_WINDOWS, Common::CIS_PROFILE_PARTS, Common::CONTROL_PREFIX, Common::UNDERSCORED, Common::XPATHS

Instance Method Summary collapse

Methods inherited from XccdfElement

#hiera_title, #reference, #to_h, #to_s

Methods included from Common

#==, #abide_object?, #control_parts, #control_profile_text, #name_normalize_control, #normalize_control_name, #normalize_profile_name, #normalize_string, #number_normalize_control, #profile_parts, #sorted_control_classes, #sorted_profile_classes, #text_normalize, #validate_xccdf, #xpath

Constructor Details

#initialize(profile) ⇒ Profile

Returns a new instance of Profile.



527
528
529
530
531
532
533
# File 'lib/abide_dev_utils/xccdf.rb', line 527

def initialize(profile)
  super(profile)
  @level, @title = profile_parts(control_profile_text(profile))
  @plain_text_title = @xml.xpath('./xccdf:title').text
  @controls = Controls.new(xpath('./xccdf:select'))
  properties :title, :level, :plain_text_title, controls: :to_h
end