Module: SurveyorParserDependencyMethods
- Defined in:
- lib/surveyor/parser.rb
Overview
Dependency model
Instance Method Summary collapse
Instance Method Details
#parse_and_build(context, args, original_method, reference_identifier) ⇒ Object
286 287 288 289 290 291 292 293 294 295 296 297 298 |
# File 'lib/surveyor/parser.rb', line 286 def parse_and_build(context, args, original_method, reference_identifier) # clear context [ :dependency, :dependency_condition ].each{|k| context.delete k} # build and set context self.attributes = (args[0] || {}) if context[:question] context[:dependency] = context[:question].dependency = self elsif context[:question_group] context[:dependency] = context[:question_group].dependency = self end end |