git-documentdb
Version:
Offline-first database that syncs with Git
33 lines • 1.33 kB
TypeScript
/**
* GitDocumentDB
* Copyright (c) Hidekazu Kubota
*
* This source code is licensed under the Mozilla Public License Version 2.0
* found in the LICENSE file in the root directory of gitDDB source tree.
*/
import { GitDDBInterface } from '../types_gitddb';
import { DeleteOptions, DeleteResult } from '../types';
/**
* Implementation of delete()
*
* @throws {@link Err.DatabaseClosingError}
* @throws {@link Err.RepositoryNotOpenError}
* @throws {@link Err.TaskCancelError}
*
* @throws # Errors from deleteWorker
* @throws - {@link Err.UndefinedDBError}
* @throws - {@link Err.DocumentNotFoundError}
* @throws - {@link Err.CannotDeleteDataError}
*
* @internal
*/
export declare function deleteImpl(gitDDB: GitDDBInterface, collectionPath: string, shortId: string | undefined, shortName: string, options?: DeleteOptions): Promise<Pick<DeleteResult, 'commit' | 'fileOid' | 'name'>>;
/**
* Remove and commit a file
*
* @throws {@link Err.UndefinedDBError}
* @throws {@link Err.DocumentNotFoundError}
* @throws {@link Err.CannotDeleteDataError}
*/
export declare function deleteWorker(gitDDB: GitDDBInterface, collectionPath: string, shortName: string, commitMessage: string): Promise<Pick<DeleteResult, 'commit' | 'fileOid' | 'name'>>;
//# sourceMappingURL=delete.d.ts.map