import type { DropboxAccessor } from '../../accessor/dropbox.ts';
import type { PathSpec } from '../../types.ts';
import { type DropboxTokenManager } from './client.ts';
import { type DropboxEntry } from './api.ts';
/**
 * Run a copy or move, replacing a file that holds the destination name. The op
 * goes first, since Dropbox answers a missing source before a taken name. A
 * held destination is measured before the op, cleared with its rev on a taken
 * name, and refused as gone when a folder took it. `emptyFolder` lets an empty
 * folder there give way too. Returns the op's reply and the destination it
 * replaced when that was looked up. Mirrors Python's `replace_onto`.
 */
export declare function replaceOnto<T>(tm: DropboxTokenManager, src: PathSpec, dst: PathSpec, to: string, op: () => Promise<T>, emptyFolder: boolean): Promise<[T, DropboxEntry | null]>;
/**
 * copy_v2 copies files and folder subtrees server-side; an existing
 * destination FILE is replaced, as cp does (see `replaceOnto`).
 */
export declare function copy(accessor: DropboxAccessor, src: PathSpec, dst: PathSpec): Promise<void>;
/**
 * Copy a folder tree onto a fresh name in one copy_v2. `cp -r` asks this
 * only when nothing holds `dst`, so a taken name is Dropbox's conflict,
 * never a merge.
 */
export declare function dirCopy(accessor: DropboxAccessor, src: PathSpec, dst: PathSpec): Promise<void>;
//# sourceMappingURL=copy.d.ts.map