public void purge(@NonNull String id) throws CouchbaseLiteException {
        if (id == null) { throw new IllegalArgumentException("document id cannot be null."); }

        synchronized (lock) {
            boolean commit = false;
            beginTransaction();
            try {
                getC4Database().purgeDoc(id);
                commit = true;
            }
            catch (LiteCoreException e) {
                throw CBLStatus.convertException(e);
            }
            finally {
                endTransaction(commit);
            }
        }
    }
public void purge ( @ NonNull String id ) throws CouchbaseLiteException { if ( id == null ) { throw new IllegalArgumentException ( "document id cannot be null." ) ; } synchronized ( lock ) { boolean commit = false ; beginTransaction ( ) ; try { getC4Database ( ) . purgeDoc ( id ) ; commit = true ; } catch ( LiteCoreException e ) { throw CBLStatus . convertException ( e ) ; } finally { endTransaction ( commit ) ; } } }
Purges the given document id for the document in database. This is more drastic than delete(Document),
it removes all traces of the document. The purge will NOT be replicated to other databases.

@param id the document ID