Module: DataMapper::Aggregates::Operators

Included in:
Symbol
Defined in:
lib/dm-aggregates/operators.rb

Instance Method Summary collapse

Instance Method Details

#avgObject



16
17
18
# File 'lib/dm-aggregates/operators.rb', line 16

def avg
  DataMapper::Query::Operator.new(self, :avg)
end

#countObject



4
5
6
# File 'lib/dm-aggregates/operators.rb', line 4

def count
  DataMapper::Query::Operator.new(self, :count)
end

#maxObject



12
13
14
# File 'lib/dm-aggregates/operators.rb', line 12

def max
  DataMapper::Query::Operator.new(self, :max)
end

#minObject



8
9
10
# File 'lib/dm-aggregates/operators.rb', line 8

def min
  DataMapper::Query::Operator.new(self, :min)
end

#sumObject



20
21
22
# File 'lib/dm-aggregates/operators.rb', line 20

def sum
  DataMapper::Query::Operator.new(self, :sum)
end