Elastica\Aggregation\AbstractAggregation::getName PHP Метод

getName() публичный Метод

Retrieve the name of this aggregation.
public getName ( ) : string
Результат string
    public function getName()
    {
        return $this->_name;
    }

Usage Example

Пример #1
0
 /**
  * Add a sub-aggregation
  * @throws \Elastica\Exception\InvalidException
  *
  * @param  AbstractAggregation $aggregation
  * @return $this
  */
 public function addAggregation(AbstractAggregation $aggregation)
 {
     if ($aggregation instanceof GlobalAggregation) {
         throw new InvalidException('Global aggregators can only be placed as top level aggregators');
     }
     $this->_aggs[$aggregation->getName()] = $aggregation->toArray();
     return $this;
 }
All Usage Examples Of Elastica\Aggregation\AbstractAggregation::getName