Class: Elasticated::StatsAggregation

Inherits:
Aggregation show all
Defined in:
lib/elasticated/aggregations/stats_aggregation.rb

Instance Attribute Summary

Attributes inherited from Aggregation

#alias_name, #extra_params, #field

Instance Method Summary collapse

Methods inherited from Aggregation

#initialize, #name, #original_name

Methods included from Mixins::Inspectionable

#inspect, #text_for_inspect

Methods included from Mixins::BlockEvaluation

#evaluate

Methods included from Mixins::Clonable

#==, #clone

Constructor Details

This class inherits a constructor from Elasticated::Aggregation

Instance Method Details

#buildObject



4
5
6
# File 'lib/elasticated/aggregations/stats_aggregation.rb', line 4

def build
  { stats: { field: field } }
end

#parse(response) ⇒ Object



8
9
10
# File 'lib/elasticated/aggregations/stats_aggregation.rb', line 8

def parse(response)
  response
end