code: public void delete(Term term) {
          Log.debug(String.format("Deleting by term %s", term));
          try {
              indexWriter.deleteDocuments(term);
          } catch (IOException e) {
              Log.error(e, "Error while deleting by term %s", term);
              throw new RuntimeException(e);
          }
      }
docs: Deletes all the {@link Document}s containing the specified {@link Term}.
  
  @param term The {@link Term} to identify the documents to be deleted.