src/Graviton/AnalyticsBundle/Model/AnalyticModel.php
public function getAggregate($params = [])
    {
        if ($this->getMultipipeline()) {
            $pipelines = [];
            foreach ($this->class as $name => $className) {
                if (!class_exists($className)) {
                    throw new \LogicException("Analytics class '" . $className . "' does not exist!");
                }
                $class = new $className();
                $class->setParams($params);
                $pipelines[$name] = $class->get();
            }
            return $pipelines;
        } else {
            $className = $this->class;
            if (!class_exists($className)) {
                throw new \LogicException("Analytics class '" . $className . "' does not exist!");
            }
            $class = new $className();
            $class->setParams($params);
            return $class->get();
        }
    }
public function getAggregate($params = [])
    {
        if ($this->getMultipipeline()) {
            $pipelines = [];
            foreach ($this->class as $name => $className) {
                if (!class_exists($className)) {
                    throw new \LogicException("Analytics class '" . $className . "' does not exist!");
                }
                $class = new $className();
                $class->setParams($params);
                $pipelines[$name] = $class->get();
            }
            return $pipelines;
        } else {
            $className = $this->class;
            if (!class_exists($className)) {
                throw new \LogicException("Analytics class '" . $className . "' does not exist!");
            }
            $class = new $className();
            $class->setParams($params);
            return $class->get();
        }
    }
public function getAggregate ( $ params = [ ] ) { if ( $ this -> getMultipipeline ( ) ) { $ pipelines = [ ] ; foreach ( $ this -> class as $ name => $ className ) { if ( ! class_exists ( $ className ) ) { throw new \ LogicException ( "Analytics class '" . $ className . "' does not exist!" ) ; } $ class = new $ className ( ) ; $ class -> setParams ( $ params ) ; $ pipelines [ $ name ] = $ class -> get ( ) ; } return $ pipelines ; } else { $ className = $ this -> class ; if ( ! class_exists ( $ className ) ) { throw new \ LogicException ( "Analytics class '" . $ className . "' does not exist!" ) ; } $ class = new $ className ( ) ; $ class -> setParams ( $ params ) ; return $ class -> get ( ) ; } }
Build a output Db Model aggregation pipeline array.

@param array $params params

@return array the pipeline
Build a output Db Model aggregation pipeline array .