Commands: Documents: Delete

Delete is used to remove a document from a database.

Syntax

public DeleteDocumentCommand(String id, String changeVector)
Parameters
id String ID of a document to be deleted
changeVector String Entity Change Vector, used for concurrency checks (null to skip check)

Example

DeleteDocumentCommand command = new DeleteDocumentCommand("employees/1-A", null);
session.advanced().getRequestExecutor().execute(command);