Class: Alf::Engine::Concat

Inherits:
Object
  • Object
show all
Includes:
Cog
Defined in:
lib/alf/engine/concat.rb

Overview

Concat tuples from multiple operands.

Constant Summary

Constants included from Cog

Alf::Engine::Cog::EMPTY_CHILDREN, Alf::Engine::Cog::EMPTY_OPTIONS

Instance Attribute Summary collapse

Attributes included from Compiler::Cog

#compiler, #expr

Instance Method Summary collapse

Methods included from Cog

#arguments, #children, #each, #options, #to_s

Methods included from Compiler::Cog

#cog_orders, #orderedby?, #relation_type, #to_ascii_tree, #to_cog, #to_relation

Constructor Details

#initialize(operands, expr = nil, compiler = nil) ⇒ Concat

Creates a Concat instance


13
14
15
16
# File 'lib/alf/engine/concat.rb', line 13

def initialize(operands, expr = nil, compiler = nil)
  super(expr, compiler)
  @operands = operands
end

Instance Attribute Details

#operandsArray (readonly)

Returns operands to concatenate

Returns:

  • (Array)

    operands to concatenate


10
11
12
# File 'lib/alf/engine/concat.rb', line 10

def operands
  @operands
end

Instance Method Details

#_each(&block) ⇒ Object


19
20
21
22
23
# File 'lib/alf/engine/concat.rb', line 19

def _each(&block)
  operands.each do |op|
    op.each(&block)
  end
end