Class: Alf::Engine::Rank::Cesure

Inherits:
Object
  • Object
show all
Includes:
Cesure, Alf::Engine::Rank
Defined in:
lib/alf/engine/rank/cesure.rb

Constant Summary

Constants included from Cog

Cog::EMPTY_CHILDREN, Cog::EMPTY_OPTIONS

Instance Attribute Summary collapse

Attributes included from Compiler::Cog

#compiler, #expr

Instance Method Summary collapse

Methods included from Cesure

#each

Methods included from Cog

#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(operand, by, as, expr = nil, compiler = nil) ⇒ Cesure

Creates an Rank::Cesure instance


17
18
19
20
21
22
# File 'lib/alf/engine/rank/cesure.rb', line 17

def initialize(operand, by, as, expr = nil, compiler = nil)
  super(expr, compiler)
  @operand = operand
  @by = by.to_attr_list
  @as = as
end

Instance Attribute Details

#asAttrName (readonly)

Returns Name of the introduced attribute

Returns:

  • (AttrName)

    Name of the introduced attribute


14
15
16
# File 'lib/alf/engine/rank/cesure.rb', line 14

def as
  @as
end

#byAttrList (readonly)

Returns List of attributes that form the operand ordering

Returns:

  • (AttrList)

    List of attributes that form the operand ordering


11
12
13
# File 'lib/alf/engine/rank/cesure.rb', line 11

def by
  @by
end

#operandEnumerable (readonly)

Returns The operand

Returns:

  • (Enumerable)

    The operand


8
9
10
# File 'lib/alf/engine/rank/cesure.rb', line 8

def operand
  @operand
end

Instance Method Details

#argumentsObject


24
25
26
# File 'lib/alf/engine/rank/cesure.rb', line 24

def arguments
  [ by, as ]
end