summaryrefslogtreecommitdiff
path: root/vendor/ruflin/elastica/lib/Elastica/Bulk/Action/DeleteDocument.php
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/ruflin/elastica/lib/Elastica/Bulk/Action/DeleteDocument.php')
-rw-r--r--vendor/ruflin/elastica/lib/Elastica/Bulk/Action/DeleteDocument.php33
1 files changed, 33 insertions, 0 deletions
diff --git a/vendor/ruflin/elastica/lib/Elastica/Bulk/Action/DeleteDocument.php b/vendor/ruflin/elastica/lib/Elastica/Bulk/Action/DeleteDocument.php
new file mode 100644
index 00000000..572f80b6
--- /dev/null
+++ b/vendor/ruflin/elastica/lib/Elastica/Bulk/Action/DeleteDocument.php
@@ -0,0 +1,33 @@
+<?php
+
+namespace Elastica\Bulk\Action;
+
+use Elastica\AbstractUpdateAction;
+
+class DeleteDocument extends AbstractDocument
+{
+ /**
+ * @var string
+ */
+ protected $_opType = self::OP_TYPE_DELETE;
+
+ /**
+ * @param \Elastica\AbstractUpdateAction $action
+ * @return array
+ */
+ protected function _getMetadata(AbstractUpdateAction $action)
+ {
+ $params = array(
+ 'index',
+ 'type',
+ 'id',
+ 'version',
+ 'version_type',
+ 'routing',
+ 'parent'
+ );
+ $metadata = $action->getOptions($params, true);
+
+ return $metadata;
+ }
+}