class Axiom::Adapter::Arango::Visitor::For::Binary::Join::Right

Visitor for right of join

Private Instance Methods

body() click to toggle source

Return body of for statement

@return [AQL::Node]

@api private

# File lib/axiom/adapter/arango/visitor/for/binary/join.rb, line 80
def body
  AQL::Node::Block.new([filter, return_operation])
end
filter() click to toggle source

Return filter

@return [AQL::Node::Operation::Filter]

@api private

# File lib/axiom/adapter/arango/visitor/for/binary/join.rb, line 36
def filter
  AQL::Node::Operation::Unary::Filter.new(filter_expression)
end
filter_expression() click to toggle source

Return filter expression

@return [AQL::Node]

@api private

# File lib/axiom/adapter/arango/visitor/for/binary/join.rb, line 46
def filter_expression
  AQL::Node::Operator::Nary::And.new(filter_predicates)
end
filter_predicate(attribute) click to toggle source

Return filter predicate for attribute

@param [Attribute] attribute

@return [AQL::Node::Operator::Binary::Equality]

@api private

# File lib/axiom/adapter/arango/visitor/for/binary/join.rb, line 70
def filter_predicate(attribute)
  AQL::Node::Operator::Binary::Equality.new(visit(attribute, context), visit(attribute))
end
filter_predicates() click to toggle source

Return filter predicates

@return [Enumerable<AQL::Node::Operator::Binary::Equality>]

@api private

# File lib/axiom/adapter/arango/visitor/for/binary/join.rb, line 56
def filter_predicates
  context_input.join_header.map do |attribute|
    filter_predicate(attribute)
  end
end
left_document_attributes() click to toggle source

Return left document attributes

@return [Enumerable<AQL::Node::Literal::Composed::Document::Attribute>]

@api private

# File lib/axiom/adapter/arango/visitor/for/binary/join.rb, line 90
def left_document_attributes
  visitor(left_header, context).document_attributes
end
left_header() click to toggle source

Return left header

@return [Relation::Header]

@api private

# File lib/axiom/adapter/arango/visitor/for/binary/join.rb, line 100
def left_header
  context_input.left.header
end
right_document_attributes() click to toggle source

Return right document attributes

@return [Enumerable<AQL::Node::Literal::Composed::Document::Attribute>]

@api private

# File lib/axiom/adapter/arango/visitor/for/binary/join.rb, line 110
def right_document_attributes
  visitor(right_document_header).document_attributes
end
right_document_header() click to toggle source

Return right document header

@return [Relation::Header]

@api private

# File lib/axiom/adapter/arango/visitor/for/binary/join.rb, line 120
def right_document_header
  right_header - left_header
end