Class: SurveyorGui::Models::DependencyConditionMethods::Rules

Inherits:
Object
  • Object
show all
Defined in:
lib/surveyor_gui/models/dependency_condition_methods.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(dependency_condition) ⇒ Rules

Returns a new instance of Rules.



26
27
28
29
30
31
32
# File 'lib/surveyor_gui/models/dependency_condition_methods.rb', line 26

def initialize(dependency_condition)
  if dependency_condition.dependency
    @rules = dependency_condition.dependency.rule.split(' ')
  else
    @rules = []
  end
end

Instance Attribute Details

#rulesObject

Returns the value of attribute rules.



24
25
26
# File 'lib/surveyor_gui/models/dependency_condition_methods.rb', line 24

def rules
  @rules
end

Instance Method Details

#join_operator(rule_key) ⇒ Object



34
35
36
# File 'lib/surveyor_gui/models/dependency_condition_methods.rb', line 34

def join_operator(rule_key)
  _find_join_operator(_find_rule_key(rule_key))
end