Module: ActiveFacts::CQL::CQL::InformalDescription1

Defined in:
lib/activefacts/cql/parser/CQLParser.rb

Instance Method Summary collapse

Instance Method Details

#astObject



1596
1597
1598
1599
1600
1601
# File 'lib/activefacts/cql/parser/CQLParser.rb', line 1596

def ast
  kind = subject.signifier.text_value.to_sym
  subject_name = (kind == :each ? subject.term.text_value : subject.reading.text_value)
  phrases = subject.reading.elements.map(&:ast) if kind == :when
  Compiler::InformalDefinition.new(kind, subject_name, phrases, informal_description_body.text_value)
end