delete() public method

delete a document
public delete ( mixed $id = false, string $index, string $type, array $options = [] ) : Bulk
$id mixed
$index string Index
$type string Type
$options array Parameters to pass to delete action
return Bulk
Exemplo n.º 1
0
 /**
  * Flush this index/type combination
  *
  * @return array
  * @param mixed $id If id is supplied, delete that id for this index
  *                  if not wipe the entire index
  * @param array $options Parameters to pass to delete action
  */
 public function delete($id = false, $options = array())
 {
     if ($this->bulk) {
         return $this->bulk->delete($id, $this->index, $this->type, $options);
     }
     return $this->transport->delete($id, $options);
 }