Class: Bmg::Relation::Materialized
- Inherits:
-
Object
- Object
- Bmg::Relation::Materialized
show all
- Includes:
- Operator::Unary
- Defined in:
- lib/bmg/relation/materialized.rb
Instance Method Summary
collapse
#bind
Methods included from Operator
#inspect, #to_s
#bind, #count, #debug, #delete, empty, #empty?, #insert, new, #one, #one_or_nil, #to_csv, #to_json, #to_xlsx, #update, #visit, #with_type, #with_type_attrlist, #with_typecheck, #without_typecheck, #y_by_x, #ys_by_x
Methods included from Algebra
#allbut, #autosummarize, #autowrap, #constants, #extend, #group, #image, #join, #left_join, #matching, #materialize, #not_matching, #page, #project, #rename, #restrict, #spied, #summarize, #transform, #ungroup, #union, #unspied, #unwrap
#exclude, #image, #images, #join, #left_join, #matching, #not_matching, #prefix, #rxmatch, #suffix, #ungroup, #unwrap, #where
Constructor Details
6
7
8
|
# File 'lib/bmg/relation/materialized.rb', line 6
def initialize(operand)
@operand = operand
end
|
Instance Method Details
#_count ⇒ Object
21
22
23
|
# File 'lib/bmg/relation/materialized.rb', line 21
def _count
operand._count
end
|
#args ⇒ Object
36
37
38
|
# File 'lib/bmg/relation/materialized.rb', line 36
def args
[]
end
|
#each(&bl) ⇒ Object
27
28
29
30
|
# File 'lib/bmg/relation/materialized.rb', line 27
def each(&bl)
@operand = Relation::InMemory.new(operand.type, operand.to_a) unless @operand.is_a?(Relation::InMemory)
@operand.each(&bl)
end
|
#to_ast ⇒ Object
32
33
34
|
# File 'lib/bmg/relation/materialized.rb', line 32
def to_ast
[ :materizalized, operand ]
end
|
#type ⇒ Object
10
11
12
|
# File 'lib/bmg/relation/materialized.rb', line 10
def type
operand.type
end
|