lib/abide_dev_utils/xccdf/diff/benchmark.rb
def include_numbered_child?(child, only_classes: [], level: nil, profile: nil)
          return false unless valid_class?(child, only_classes)
          return true if level.nil? && profile.nil?

          validated_props = valid_profile_and_level(child, level, profile)
          should_include = validated_props.none?(&:nil?)
          new_validated_props_vars(validated_props) if should_include
          should_include
        end
# Function to check if a numbered child meets inclusion criteria based on filtering
# options.
# @param child [Object] XCCDF parser object that includes AbideDevUtils::XCCDF::Parser::Objects::NumberedObject.
# @param only_classes [Array] class names as strings. When this is specified, only objects with those class names will be considered.
# @param level [String] Specifies the benchmark profile level to filter children on. Only applies to Rules linked to Profiles that have levels.
# @param profile [String] Specifies the benchmark profile to filter children on. Only applies to Rules that have linked Profiles.
# @return [TrueClass] if child meets all filtering criteria and should be included in the set.
# @return [FalseClass] if child does not meet all criteria and should be excluded from the set.
Function to check if a numbered child meets inclusion criteria based on filtering
options.
Function to check if a numbered child meets inclusion criteria based on filtering options .
def include_numbered_child?(child, only_classes: [], level: nil, profile: nil)
          return false unless valid_class?(child, only_classes)
          return true if level.nil? && profile.nil?
          validated_props = valid_profile_and_level(child, level, profile)
          should_include = validated_props.none?(&:nil?)
          new_validated_props_vars(validated_props) if should_include
          should_include
        end
def include_numbered_child? ( child , only_classes : [ ] , level : nil , profile : nil ) return false unless valid_class? ( child , only_classes ) return true if level . nil? && profile . nil? validated_props = valid_profile_and_level ( child , level , profile ) should_include = validated_props . none? ( & :nil? ) new_validated_props_vars ( validated_props ) if should_include should_include end
Function to check if a numbered child meets inclusion criteria based on filtering
options.
Function to check if a numbered child meets inclusion criteria based on filtering options .
if child meets all filtering criteria and should be included in the set.
if child meets all filtering criteria and should be included in the set .
TrueClass
if child does not meet all criteria and should be excluded from the set.
if child does not meet all criteria and should be excluded from the set .
FalseClass
child
XCCDF parser object that includes AbideDevUtils::XCCDF::Parser::Objects::NumberedObject.
XCCDF parser object that includes AbideDevUtils :: XCCDF :: Parser :: Objects :: NumberedObject .
only_classes
class names as strings. When this is specified, only objects with those class names will be considered.
class names as strings . When this is specified only objects with those class names will be considered .
level
Specifies the benchmark profile level to filter children on. Only applies to Rules linked to Profiles that have levels.
Specifies the benchmark profile level to filter children on . Only applies to Rules linked to Profiles that have levels .
profile
Specifies the benchmark profile to filter children on. Only applies to Rules that have linked Profiles.
Specifies the benchmark profile to filter children on . Only applies to Rules that have linked Profiles .