Class: Influxdb::Arel::Nodes::SelectStatement
- Defined in:
- lib/influxdb/arel/nodes/select_statement.rb
Instance Attribute Summary collapse
-
#columns ⇒ Object
Returns the value of attribute columns.
-
#fill ⇒ Object
Returns the value of attribute fill.
-
#groups ⇒ Object
Returns the value of attribute groups.
-
#into ⇒ Object
Returns the value of attribute into.
-
#join ⇒ Object
Returns the value of attribute join.
-
#limit ⇒ Object
Returns the value of attribute limit.
-
#merge ⇒ Object
Returns the value of attribute merge.
-
#order ⇒ Object
Returns the value of attribute order.
-
#series ⇒ Object
Returns the value of attribute series.
-
#wheres ⇒ Object
Returns the value of attribute wheres.
Instance Method Summary collapse
- #eql?(other) ⇒ Boolean (also: #==)
- #hash ⇒ Object
-
#initialize ⇒ SelectStatement
constructor
A new instance of SelectStatement.
- #initialize_copy(other) ⇒ Object
- #table ⇒ Object
Methods inherited from Node
Constructor Details
#initialize ⇒ SelectStatement
Returns a new instance of SelectStatement.
7 8 9 10 11 12 13 14 15 16 17 18 19 |
# File 'lib/influxdb/arel/nodes/select_statement.rb', line 7 def initialize super self.wheres = [] self.groups = [] self.columns = [] self.series = [] self.merge = nil self.join = nil self.order = nil self.limit = nil self.fill = nil self.into = nil end |
Instance Attribute Details
#columns ⇒ Object
Returns the value of attribute columns.
5 6 7 |
# File 'lib/influxdb/arel/nodes/select_statement.rb', line 5 def columns @columns end |
#fill ⇒ Object
Returns the value of attribute fill.
5 6 7 |
# File 'lib/influxdb/arel/nodes/select_statement.rb', line 5 def fill @fill end |
#groups ⇒ Object
Returns the value of attribute groups.
5 6 7 |
# File 'lib/influxdb/arel/nodes/select_statement.rb', line 5 def groups @groups end |
#into ⇒ Object
Returns the value of attribute into.
5 6 7 |
# File 'lib/influxdb/arel/nodes/select_statement.rb', line 5 def into @into end |
#join ⇒ Object
Returns the value of attribute join.
5 6 7 |
# File 'lib/influxdb/arel/nodes/select_statement.rb', line 5 def join @join end |
#limit ⇒ Object
Returns the value of attribute limit.
5 6 7 |
# File 'lib/influxdb/arel/nodes/select_statement.rb', line 5 def limit @limit end |
#merge ⇒ Object
Returns the value of attribute merge.
5 6 7 |
# File 'lib/influxdb/arel/nodes/select_statement.rb', line 5 def merge @merge end |
#order ⇒ Object
Returns the value of attribute order.
5 6 7 |
# File 'lib/influxdb/arel/nodes/select_statement.rb', line 5 def order @order end |
#series ⇒ Object
Returns the value of attribute series.
5 6 7 |
# File 'lib/influxdb/arel/nodes/select_statement.rb', line 5 def series @series end |
#wheres ⇒ Object
Returns the value of attribute wheres.
5 6 7 |
# File 'lib/influxdb/arel/nodes/select_statement.rb', line 5 def wheres @wheres end |
Instance Method Details
#eql?(other) ⇒ Boolean Also known as: ==
43 44 45 46 47 48 49 50 51 52 53 |
# File 'lib/influxdb/arel/nodes/select_statement.rb', line 43 def eql?(other) self.class == other.class && columns == other.columns && wheres == other.wheres && groups == other.groups && table == other.table && order == other.order && limit == other.limit && fill == other.fill && into == other.into end |
#hash ⇒ Object
39 40 41 |
# File 'lib/influxdb/arel/nodes/select_statement.rb', line 39 def hash [limit, order, wheres, groups, columns, table, fill, into].hash end |
#initialize_copy(other) ⇒ Object
21 22 23 24 25 26 27 28 29 30 31 32 33 |
# File 'lib/influxdb/arel/nodes/select_statement.rb', line 21 def initialize_copy(other) super self.wheres = wheres.map{|where| where.clone } self.groups = groups.map{|group| group.clone } self.columns = columns.map{|column| column.clone } self.series = series.map{|series| series.clone } self.join = join.clone if join self.merge = merge.clone if merge self.order = order.clone if order self.limit = limit.clone if limit self.fill = fill.clone if fill self.into = into.clone if into end |
#table ⇒ Object
35 36 37 |
# File 'lib/influxdb/arel/nodes/select_statement.rb', line 35 def table join || merge || series.map(&:unalias).uniq end |