class Aws::Endpoints::TreeRule

@api private
old service gems can use a new core version.
major version. It has to exist because
approach in each service gem. It can be removed in a new
resolution approach. It has been replaced by a code generated
This class is deprecated. It is used by the Runtime endpoint

def initialize(type: 'tree', conditions:, rules:, documentation: nil)

def initialize(type: 'tree', conditions:, rules:, documentation: nil)
  @type = type
  @conditions = Condition.from_json(conditions)
  @rules = RuleSet.rules_from_json(rules)
  @documentation = documentation
end

def match(parameters, assigned = {})

def match(parameters, assigned = {})
  assigns = assigned.dup
  matched = conditions.all? do |condition|
    output = condition.match?(parameters, assigns)
    assigns = assigns.merge(condition.assigned) if condition.assign
    output
  end
  resolve_rules(parameters, assigns) if matched
end

def resolve_rules(parameters, assigns)

def resolve_rules(parameters, assigns)
  @rules.each do |rule|
    output = rule.match(parameters, assigns)
    return output if output
  end
  nil
end