Class: Piglet::Relation::Union
- Inherits:
-
Object
- Object
- Piglet::Relation::Union
- Includes:
- Relation
- Defined in:
- lib/piglet/relation/union.rb
Overview
:nodoc:
Instance Attribute Summary
Attributes included from Relation
Instance Method Summary collapse
-
#initialize(*relations) ⇒ Union
constructor
A new instance of Union.
- #to_s ⇒ Object
Methods included from Relation
#[], #alias, #cogroup, #cross, #distinct, #eql?, #field, #filter, #foreach, #group, #hash, #join, #limit, #method_missing, #order, #sample, #schema, #split, #stream, #union
Constructor Details
#initialize(*relations) ⇒ Union
8 9 10 |
# File 'lib/piglet/relation/union.rb', line 8 def initialize(*relations) @sources = [relations].flatten end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Piglet::Relation::Relation
Instance Method Details
#to_s ⇒ Object
12 13 14 |
# File 'lib/piglet/relation/union.rb', line 12 def to_s "UNION #{source_aliases.join(', ')}" end |