From 308b9c148391562500eb0e3cda10e0c334c5e5e3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Mantas=20Jonu=C5=A1as?= <mantas.jonusas@nfq.lt>
Date: Tue, 24 Mar 2015 10:30:39 +0200
Subject: [PATCH] Added avg aggregation

---
 Aggregation/AvgAggregation.php | 26 ++++++++++++++++++++++++++
 1 file changed, 26 insertions(+)
 create mode 100644 Aggregation/AvgAggregation.php

diff --git a/Aggregation/AvgAggregation.php b/Aggregation/AvgAggregation.php
new file mode 100644
index 0000000..2d79579
--- /dev/null
+++ b/Aggregation/AvgAggregation.php
@@ -0,0 +1,26 @@
+<?php
+
+/*
+ * This file is part of the ONGR package.
+ *
+ * (c) NFQ Technologies UAB <info@nfq.com>
+ *
+ * For the full copyright and license information, please view the LICENSE
+ * file that was distributed with this source code.
+ */
+
+namespace ONGR\ElasticsearchBundle\DSL\Aggregation;
+
+/**
+ * Class representing Avg Aggregation.
+ */
+class AvgAggregation extends StatsAggregation
+{
+    /**
+     * {@inheritdoc}
+     */
+    public function getType()
+    {
+        return 'avg';
+    }
+}
-- 
GitLab