diff options
Diffstat (limited to 'vendor/ruflin/elastica/lib/Elastica/Filter/Exists.php')
-rw-r--r-- | vendor/ruflin/elastica/lib/Elastica/Filter/Exists.php | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/vendor/ruflin/elastica/lib/Elastica/Filter/Exists.php b/vendor/ruflin/elastica/lib/Elastica/Filter/Exists.php new file mode 100644 index 00000000..6fe43e3d --- /dev/null +++ b/vendor/ruflin/elastica/lib/Elastica/Filter/Exists.php @@ -0,0 +1,35 @@ +<?php + +namespace Elastica\Filter; + +/** + * Exists query + * + * @category Xodoa + * @package Elastica + * @author Oleg Cherniy <oleg.cherniy@gmail.com> + * @link http://www.elasticsearch.org/guide/reference/query-dsl/exists-filter.html + */ +class Exists extends AbstractFilter +{ + /** + * Construct exists filter + * + * @param string $field + */ + public function __construct($field) + { + $this->setField($field); + } + + /** + * Set field + * + * @param string $field + * @return \Elastica\Filter\Exists + */ + public function setField($field) + { + return $this->setParam('field', $field); + } +} |