Class: ConceptQL::GraphNodifier

Inherits:
Object
  • Object
show all
Defined in:
lib/conceptql/graph_nodifier.rb

Defined Under Namespace

Classes: BinaryOperatorNode, DotNode

Constant Summary collapse

BINARY_OPERATOR_TYPES =
%w(before after meets met_by started_by starts contains during overlaps overlapped_by finished_by finishes coincides except person_filter less_than less_than_or_equal equal not_equal greater_than greater_than_or_equal filter).map { |temp| [temp, "not_#{temp}"] }.flatten.map(&:to_sym)

Instance Method Summary collapse

Instance Method Details

#create(type, values) ⇒ Object



118
119
120
121
# File 'lib/conceptql/graph_nodifier.rb', line 118

def create(type, values)
  return BinaryOperatorNode.new(type, values) if BINARY_OPERATOR_TYPES.include?(type)
  DotNode.new(type, values)
end