1import { DownloadOptions, DownloadPauseState, DownloadProgressCallback, FileSystemNetworkTaskProgressCallback, DownloadProgressData, UploadProgressData, DownloadResult, EncodingType, FileInfo, FileSystemAcceptedUploadHttpMethod, FileSystemDownloadResult, FileSystemRequestDirectoryPermissionsResult, FileSystemSessionType, FileSystemUploadOptions, FileSystemUploadResult, FileSystemUploadType, ReadingOptions, WritingOptions } from './FileSystem.types';
2export { DownloadOptions, DownloadPauseState, DownloadProgressCallback, DownloadProgressData, DownloadResult, EncodingType, FileInfo, FileSystemDownloadResult, FileSystemRequestDirectoryPermissionsResult, FileSystemAcceptedUploadHttpMethod, FileSystemSessionType, FileSystemUploadOptions, FileSystemUploadResult, FileSystemUploadType, FileSystemNetworkTaskProgressCallback, ReadingOptions, WritingOptions, };
3export declare const documentDirectory: string | null;
4export declare const cacheDirectory: string | null;
5export declare const bundledAssets: string | null, bundleDirectory: string | null;
6export declare function getInfoAsync(fileUri: string, options?: {
7    md5?: boolean;
8    size?: boolean;
9}): Promise<FileInfo>;
10export declare function readAsStringAsync(fileUri: string, options?: ReadingOptions): Promise<string>;
11export declare function getContentUriAsync(fileUri: string): Promise<string>;
12export declare function writeAsStringAsync(fileUri: string, contents: string, options?: WritingOptions): Promise<void>;
13export declare function deleteAsync(fileUri: string, options?: {
14    idempotent?: boolean;
15}): Promise<void>;
16export declare function deleteLegacyDocumentDirectoryAndroid(): Promise<void>;
17export declare function moveAsync(options: {
18    from: string;
19    to: string;
20}): Promise<void>;
21export declare function copyAsync(options: {
22    from: string;
23    to: string;
24}): Promise<void>;
25export declare function makeDirectoryAsync(fileUri: string, options?: {
26    intermediates?: boolean;
27}): Promise<void>;
28export declare function readDirectoryAsync(fileUri: string): Promise<string[]>;
29export declare function getFreeDiskStorageAsync(): Promise<number>;
30export declare function getTotalDiskCapacityAsync(): Promise<number>;
31export declare function downloadAsync(uri: string, fileUri: string, options?: DownloadOptions): Promise<FileSystemDownloadResult>;
32export declare function uploadAsync(url: string, fileUri: string, options?: FileSystemUploadOptions): Promise<FileSystemUploadResult>;
33export declare function createDownloadResumable(uri: string, fileUri: string, options?: DownloadOptions, callback?: FileSystemNetworkTaskProgressCallback<DownloadProgressData>, resumeData?: string): DownloadResumable;
34export declare function createUploadTask(url: string, fileUri: string, options?: FileSystemUploadOptions, callback?: FileSystemNetworkTaskProgressCallback<UploadProgressData>): UploadTask;
35export declare abstract class FileSystemCancellableNetworkTask<T extends DownloadProgressData | UploadProgressData> {
36    private _uuid;
37    protected taskWasCanceled: boolean;
38    private emitter;
39    private subscription?;
40    cancelAsync(): Promise<void>;
41    protected isTaskCancelled(): boolean;
42    protected get uuid(): string;
43    protected abstract getEventName(): string;
44    protected abstract getCallback(): FileSystemNetworkTaskProgressCallback<T> | undefined;
45    protected addSubscription(): void;
46    protected removeSubscription(): void;
47}
48export declare class UploadTask extends FileSystemCancellableNetworkTask<UploadProgressData> {
49    private url;
50    private fileUri;
51    private callback?;
52    private options;
53    constructor(url: string, fileUri: string, options?: FileSystemUploadOptions, callback?: FileSystemNetworkTaskProgressCallback<UploadProgressData> | undefined);
54    protected getEventName(): string;
55    protected getCallback(): FileSystemNetworkTaskProgressCallback<UploadProgressData> | undefined;
56    uploadAsync(): Promise<FileSystemUploadResult | undefined>;
57}
58export declare class DownloadResumable extends FileSystemCancellableNetworkTask<DownloadProgressData> {
59    private url;
60    private _fileUri;
61    private options;
62    private callback?;
63    private resumeData?;
64    constructor(url: string, _fileUri: string, options?: DownloadOptions, callback?: FileSystemNetworkTaskProgressCallback<DownloadProgressData> | undefined, resumeData?: string | undefined);
65    get fileUri(): string;
66    protected getEventName(): string;
67    protected getCallback(): FileSystemNetworkTaskProgressCallback<DownloadProgressData> | undefined;
68    downloadAsync(): Promise<FileSystemDownloadResult | undefined>;
69    pauseAsync(): Promise<DownloadPauseState>;
70    resumeAsync(): Promise<FileSystemDownloadResult | undefined>;
71    savable(): DownloadPauseState;
72}
73/**
74 * Android only
75 */
76export declare namespace StorageAccessFramework {
77    function getUriForDirectoryInRoot(folderName: string): string;
78    function requestDirectoryPermissionsAsync(initialFileUrl?: string | null): Promise<FileSystemRequestDirectoryPermissionsResult>;
79    function readDirectoryAsync(dirUri: string): Promise<string[]>;
80    function makeDirectoryAsync(parentUri: string, dirName: string): Promise<string>;
81    function createFileAsync(parentUri: string, fileName: string, mimeType: string): Promise<string>;
82    const writeAsStringAsync: typeof import("./FileSystem").writeAsStringAsync;
83    const readAsStringAsync: typeof import("./FileSystem").readAsStringAsync;
84    const deleteAsync: typeof import("./FileSystem").deleteAsync;
85    const moveAsync: typeof import("./FileSystem").moveAsync;
86    const copyAsync: typeof import("./FileSystem").copyAsync;
87}
88//# sourceMappingURL=FileSystem.d.ts.map