Class: Elasticband::Aggregation::TopHits
- Inherits:
-
Elasticband::Aggregation
- Object
- Elasticband::Aggregation
- Elasticband::Aggregation::TopHits
- Defined in:
- lib/elasticband/aggregation/top_hits.rb
Constant Summary
Constants inherited from Elasticband::Aggregation
Instance Attribute Summary collapse
-
#options ⇒ Object
Returns the value of attribute options.
-
#size ⇒ Object
Returns the value of attribute size.
Attributes inherited from Elasticband::Aggregation
Instance Method Summary collapse
-
#initialize(name, size, options = {}) ⇒ TopHits
constructor
A new instance of TopHits.
- #to_h ⇒ Object
Methods inherited from Elasticband::Aggregation
Constructor Details
#initialize(name, size, options = {}) ⇒ TopHits
Returns a new instance of TopHits.
6 7 8 9 10 |
# File 'lib/elasticband/aggregation/top_hits.rb', line 6 def initialize(name, size, = {}) super(name) self.size = size self. = end |
Instance Attribute Details
#options ⇒ Object
Returns the value of attribute options.
4 5 6 |
# File 'lib/elasticband/aggregation/top_hits.rb', line 4 def @options end |
#size ⇒ Object
Returns the value of attribute size.
4 5 6 |
# File 'lib/elasticband/aggregation/top_hits.rb', line 4 def size @size end |
Instance Method Details
#to_h ⇒ Object
12 13 14 |
# File 'lib/elasticband/aggregation/top_hits.rb', line 12 def to_h super(top_hits_hash) end |