yeet
This commit is contained in:
3
node_modules/expo-file-system/build/ExponentFileSystem.d.ts
generated
vendored
Normal file
3
node_modules/expo-file-system/build/ExponentFileSystem.d.ts
generated
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
import { ExponentFileSystemModule } from './FileSystem.types';
|
||||
declare const _default: ExponentFileSystemModule;
|
||||
export default _default;
|
11
node_modules/expo-file-system/build/ExponentFileSystem.js
generated
vendored
Normal file
11
node_modules/expo-file-system/build/ExponentFileSystem.js
generated
vendored
Normal file
@ -0,0 +1,11 @@
|
||||
import { NativeModulesProxy } from '@unimodules/core';
|
||||
import ExponentFileSystemShim from './ExponentFileSystemShim';
|
||||
let platformModule;
|
||||
if (NativeModulesProxy.ExponentFileSystem) {
|
||||
platformModule = NativeModulesProxy.ExponentFileSystem;
|
||||
}
|
||||
else {
|
||||
platformModule = ExponentFileSystemShim;
|
||||
}
|
||||
export default platformModule;
|
||||
//# sourceMappingURL=ExponentFileSystem.js.map
|
1
node_modules/expo-file-system/build/ExponentFileSystem.js.map
generated
vendored
Normal file
1
node_modules/expo-file-system/build/ExponentFileSystem.js.map
generated
vendored
Normal file
@ -0,0 +1 @@
|
||||
{"version":3,"file":"ExponentFileSystem.js","sourceRoot":"","sources":["../src/ExponentFileSystem.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,kBAAkB,CAAC;AAEtD,OAAO,sBAAsB,MAAM,0BAA0B,CAAC;AAG9D,IAAI,cAAc,CAAC;AAEnB,IAAI,kBAAkB,CAAC,kBAAkB,EAAE;IACzC,cAAc,GAAG,kBAAkB,CAAC,kBAAkB,CAAC;CACxD;KAAM;IACL,cAAc,GAAG,sBAAsB,CAAC;CACzC;AAED,eAAe,cAA0C,CAAC","sourcesContent":["import { NativeModulesProxy } from '@unimodules/core';\n\nimport ExponentFileSystemShim from './ExponentFileSystemShim';\nimport { ExponentFileSystemModule } from './FileSystem.types';\n\nlet platformModule;\n\nif (NativeModulesProxy.ExponentFileSystem) {\n platformModule = NativeModulesProxy.ExponentFileSystem;\n} else {\n platformModule = ExponentFileSystemShim;\n}\n\nexport default platformModule as ExponentFileSystemModule;\n"]}
|
2
node_modules/expo-file-system/build/ExponentFileSystem.web.d.ts
generated
vendored
Normal file
2
node_modules/expo-file-system/build/ExponentFileSystem.web.d.ts
generated
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
import ExponentFileSystemShim from './ExponentFileSystemShim';
|
||||
export default ExponentFileSystemShim;
|
3
node_modules/expo-file-system/build/ExponentFileSystem.web.js
generated
vendored
Normal file
3
node_modules/expo-file-system/build/ExponentFileSystem.web.js
generated
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
import ExponentFileSystemShim from './ExponentFileSystemShim';
|
||||
export default ExponentFileSystemShim;
|
||||
//# sourceMappingURL=ExponentFileSystem.web.js.map
|
1
node_modules/expo-file-system/build/ExponentFileSystem.web.js.map
generated
vendored
Normal file
1
node_modules/expo-file-system/build/ExponentFileSystem.web.js.map
generated
vendored
Normal file
@ -0,0 +1 @@
|
||||
{"version":3,"file":"ExponentFileSystem.web.js","sourceRoot":"","sources":["../src/ExponentFileSystem.web.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,MAAM,0BAA0B,CAAC;AAC9D,eAAe,sBAAsB,CAAC","sourcesContent":["import ExponentFileSystemShim from './ExponentFileSystemShim';\nexport default ExponentFileSystemShim;\n"]}
|
3
node_modules/expo-file-system/build/ExponentFileSystemShim.d.ts
generated
vendored
Normal file
3
node_modules/expo-file-system/build/ExponentFileSystemShim.d.ts
generated
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
import { ExponentFileSystemModule } from './FileSystem.types';
|
||||
declare const platformModule: ExponentFileSystemModule;
|
||||
export default platformModule;
|
21
node_modules/expo-file-system/build/ExponentFileSystemShim.js
generated
vendored
Normal file
21
node_modules/expo-file-system/build/ExponentFileSystemShim.js
generated
vendored
Normal file
@ -0,0 +1,21 @@
|
||||
const platformModule = {
|
||||
get name() {
|
||||
return 'ExponentFileSystem';
|
||||
},
|
||||
get documentDirectory() {
|
||||
return null;
|
||||
},
|
||||
get cacheDirectory() {
|
||||
return null;
|
||||
},
|
||||
get bundledAssets() {
|
||||
return null;
|
||||
},
|
||||
get bundleDirectory() {
|
||||
return null;
|
||||
},
|
||||
addListener(eventName) { },
|
||||
removeListeners(count) { },
|
||||
};
|
||||
export default platformModule;
|
||||
//# sourceMappingURL=ExponentFileSystemShim.js.map
|
1
node_modules/expo-file-system/build/ExponentFileSystemShim.js.map
generated
vendored
Normal file
1
node_modules/expo-file-system/build/ExponentFileSystemShim.js.map
generated
vendored
Normal file
@ -0,0 +1 @@
|
||||
{"version":3,"file":"ExponentFileSystemShim.js","sourceRoot":"","sources":["../src/ExponentFileSystemShim.ts"],"names":[],"mappings":"AAEA,MAAM,cAAc,GAA6B;IAC/C,IAAI,IAAI;QACN,OAAO,oBAAoB,CAAC;IAC9B,CAAC;IACD,IAAI,iBAAiB;QACnB,OAAO,IAAI,CAAC;IACd,CAAC;IACD,IAAI,cAAc;QAChB,OAAO,IAAI,CAAC;IACd,CAAC;IACD,IAAI,aAAa;QACf,OAAO,IAAI,CAAC;IACd,CAAC;IACD,IAAI,eAAe;QACjB,OAAO,IAAI,CAAC;IACd,CAAC;IACD,WAAW,CAAC,SAAiB,IAAS,CAAC;IACvC,eAAe,CAAC,KAAa,IAAS,CAAC;CACxC,CAAC;AAEF,eAAe,cAAc,CAAC","sourcesContent":["import { ExponentFileSystemModule } from './FileSystem.types';\n\nconst platformModule: ExponentFileSystemModule = {\n get name(): 'ExponentFileSystem' {\n return 'ExponentFileSystem';\n },\n get documentDirectory(): string | null {\n return null;\n },\n get cacheDirectory(): string | null {\n return null;\n },\n get bundledAssets(): string | null {\n return null;\n },\n get bundleDirectory(): string | null {\n return null;\n },\n addListener(eventName: string): void {},\n removeListeners(count: number): void {},\n};\n\nexport default platformModule;\n"]}
|
51
node_modules/expo-file-system/build/FileSystem.d.ts
generated
vendored
Normal file
51
node_modules/expo-file-system/build/FileSystem.d.ts
generated
vendored
Normal file
@ -0,0 +1,51 @@
|
||||
import { EventEmitter, Subscription } from '@unimodules/core';
|
||||
import { DownloadOptions, DownloadPauseState, DownloadProgressCallback, DownloadProgressData, DownloadResult, EncodingType, FileInfo, FileSystemAcceptedUploadHttpMethod, FileSystemDownloadResult, FileSystemSessionType, FileSystemUploadOptions, FileSystemUploadResult, FileSystemUploadType, ProgressEvent, ReadingOptions, WritingOptions } from './FileSystem.types';
|
||||
export { DownloadOptions, DownloadPauseState, DownloadProgressCallback, DownloadProgressData, DownloadResult, EncodingType, FileInfo, FileSystemDownloadResult, FileSystemAcceptedUploadHttpMethod, FileSystemSessionType, FileSystemUploadOptions, FileSystemUploadResult, FileSystemUploadType, ProgressEvent, ReadingOptions, WritingOptions, };
|
||||
export declare const documentDirectory: string | null;
|
||||
export declare const cacheDirectory: string | null;
|
||||
export declare const bundledAssets: string | null, bundleDirectory: string | null;
|
||||
export declare function getInfoAsync(fileUri: string, options?: {
|
||||
md5?: boolean;
|
||||
size?: boolean;
|
||||
}): Promise<FileInfo>;
|
||||
export declare function readAsStringAsync(fileUri: string, options?: ReadingOptions): Promise<string>;
|
||||
export declare function getContentUriAsync(fileUri: string): Promise<string>;
|
||||
export declare function writeAsStringAsync(fileUri: string, contents: string, options?: WritingOptions): Promise<void>;
|
||||
export declare function deleteAsync(fileUri: string, options?: {
|
||||
idempotent?: boolean;
|
||||
}): Promise<void>;
|
||||
export declare function deleteLegacyDocumentDirectoryAndroid(): Promise<void>;
|
||||
export declare function moveAsync(options: {
|
||||
from: string;
|
||||
to: string;
|
||||
}): Promise<void>;
|
||||
export declare function copyAsync(options: {
|
||||
from: string;
|
||||
to: string;
|
||||
}): Promise<void>;
|
||||
export declare function makeDirectoryAsync(fileUri: string, options?: {
|
||||
intermediates?: boolean;
|
||||
}): Promise<void>;
|
||||
export declare function readDirectoryAsync(fileUri: string): Promise<string[]>;
|
||||
export declare function getFreeDiskStorageAsync(): Promise<number>;
|
||||
export declare function getTotalDiskCapacityAsync(): Promise<number>;
|
||||
export declare function downloadAsync(uri: string, fileUri: string, options?: DownloadOptions): Promise<FileSystemDownloadResult>;
|
||||
export declare function uploadAsync(url: string, fileUri: string, options?: FileSystemUploadOptions): Promise<FileSystemUploadResult>;
|
||||
export declare function createDownloadResumable(uri: string, fileUri: string, options?: DownloadOptions, callback?: DownloadProgressCallback, resumeData?: string): DownloadResumable;
|
||||
export declare class DownloadResumable {
|
||||
_uuid: string;
|
||||
_url: string;
|
||||
_fileUri: string;
|
||||
_options: DownloadOptions;
|
||||
_resumeData?: string;
|
||||
_callback?: DownloadProgressCallback;
|
||||
_subscription?: Subscription | null;
|
||||
_emitter: EventEmitter;
|
||||
constructor(url: string, fileUri: string, options?: DownloadOptions, callback?: DownloadProgressCallback, resumeData?: string);
|
||||
downloadAsync(): Promise<FileSystemDownloadResult | undefined>;
|
||||
pauseAsync(): Promise<DownloadPauseState>;
|
||||
resumeAsync(): Promise<FileSystemDownloadResult | undefined>;
|
||||
savable(): DownloadPauseState;
|
||||
_addSubscription(): void;
|
||||
_removeSubscription(): void;
|
||||
}
|
192
node_modules/expo-file-system/build/FileSystem.js
generated
vendored
Normal file
192
node_modules/expo-file-system/build/FileSystem.js
generated
vendored
Normal file
@ -0,0 +1,192 @@
|
||||
import { EventEmitter, UnavailabilityError } from '@unimodules/core';
|
||||
import { Platform } from 'react-native';
|
||||
import uuidv4 from 'uuid/v4';
|
||||
import ExponentFileSystem from './ExponentFileSystem';
|
||||
import { EncodingType, FileSystemSessionType, FileSystemUploadType, } from './FileSystem.types';
|
||||
if (!ExponentFileSystem) {
|
||||
console.warn("No native ExponentFileSystem module found, are you sure the expo-file-system's module is linked properly?");
|
||||
}
|
||||
// Prevent webpack from pruning this.
|
||||
const _unused = new EventEmitter(ExponentFileSystem); // eslint-disable-line
|
||||
export { EncodingType, FileSystemSessionType, FileSystemUploadType, };
|
||||
function normalizeEndingSlash(p) {
|
||||
if (p != null) {
|
||||
return p.replace(/\/*$/, '') + '/';
|
||||
}
|
||||
return null;
|
||||
}
|
||||
export const documentDirectory = normalizeEndingSlash(ExponentFileSystem.documentDirectory);
|
||||
export const cacheDirectory = normalizeEndingSlash(ExponentFileSystem.cacheDirectory);
|
||||
export const { bundledAssets, bundleDirectory } = ExponentFileSystem;
|
||||
export async function getInfoAsync(fileUri, options = {}) {
|
||||
if (!ExponentFileSystem.getInfoAsync) {
|
||||
throw new UnavailabilityError('expo-file-system', 'getInfoAsync');
|
||||
}
|
||||
return await ExponentFileSystem.getInfoAsync(fileUri, options);
|
||||
}
|
||||
export async function readAsStringAsync(fileUri, options) {
|
||||
if (!ExponentFileSystem.readAsStringAsync) {
|
||||
throw new UnavailabilityError('expo-file-system', 'readAsStringAsync');
|
||||
}
|
||||
return await ExponentFileSystem.readAsStringAsync(fileUri, options || {});
|
||||
}
|
||||
export async function getContentUriAsync(fileUri) {
|
||||
if (Platform.OS === 'android') {
|
||||
if (!ExponentFileSystem.getContentUriAsync) {
|
||||
throw new UnavailabilityError('expo-file-system', 'getContentUriAsync');
|
||||
}
|
||||
return await ExponentFileSystem.getContentUriAsync(fileUri);
|
||||
}
|
||||
else {
|
||||
return new Promise(function (resolve, reject) {
|
||||
resolve(fileUri);
|
||||
});
|
||||
}
|
||||
}
|
||||
export async function writeAsStringAsync(fileUri, contents, options = {}) {
|
||||
if (!ExponentFileSystem.writeAsStringAsync) {
|
||||
throw new UnavailabilityError('expo-file-system', 'writeAsStringAsync');
|
||||
}
|
||||
return await ExponentFileSystem.writeAsStringAsync(fileUri, contents, options);
|
||||
}
|
||||
export async function deleteAsync(fileUri, options = {}) {
|
||||
if (!ExponentFileSystem.deleteAsync) {
|
||||
throw new UnavailabilityError('expo-file-system', 'deleteAsync');
|
||||
}
|
||||
return await ExponentFileSystem.deleteAsync(fileUri, options);
|
||||
}
|
||||
export async function deleteLegacyDocumentDirectoryAndroid() {
|
||||
if (Platform.OS !== 'android' || documentDirectory == null) {
|
||||
return;
|
||||
}
|
||||
const legacyDocumentDirectory = `${documentDirectory}ExperienceData/`;
|
||||
return await deleteAsync(legacyDocumentDirectory, { idempotent: true });
|
||||
}
|
||||
export async function moveAsync(options) {
|
||||
if (!ExponentFileSystem.moveAsync) {
|
||||
throw new UnavailabilityError('expo-file-system', 'moveAsync');
|
||||
}
|
||||
return await ExponentFileSystem.moveAsync(options);
|
||||
}
|
||||
export async function copyAsync(options) {
|
||||
if (!ExponentFileSystem.copyAsync) {
|
||||
throw new UnavailabilityError('expo-file-system', 'copyAsync');
|
||||
}
|
||||
return await ExponentFileSystem.copyAsync(options);
|
||||
}
|
||||
export async function makeDirectoryAsync(fileUri, options = {}) {
|
||||
if (!ExponentFileSystem.makeDirectoryAsync) {
|
||||
throw new UnavailabilityError('expo-file-system', 'makeDirectoryAsync');
|
||||
}
|
||||
return await ExponentFileSystem.makeDirectoryAsync(fileUri, options);
|
||||
}
|
||||
export async function readDirectoryAsync(fileUri) {
|
||||
if (!ExponentFileSystem.readDirectoryAsync) {
|
||||
throw new UnavailabilityError('expo-file-system', 'readDirectoryAsync');
|
||||
}
|
||||
return await ExponentFileSystem.readDirectoryAsync(fileUri, {});
|
||||
}
|
||||
export async function getFreeDiskStorageAsync() {
|
||||
if (!ExponentFileSystem.getFreeDiskStorageAsync) {
|
||||
throw new UnavailabilityError('expo-file-system', 'getFreeDiskStorageAsync');
|
||||
}
|
||||
return await ExponentFileSystem.getFreeDiskStorageAsync();
|
||||
}
|
||||
export async function getTotalDiskCapacityAsync() {
|
||||
if (!ExponentFileSystem.getTotalDiskCapacityAsync) {
|
||||
throw new UnavailabilityError('expo-file-system', 'getTotalDiskCapacityAsync');
|
||||
}
|
||||
return await ExponentFileSystem.getTotalDiskCapacityAsync();
|
||||
}
|
||||
export async function downloadAsync(uri, fileUri, options = {}) {
|
||||
if (!ExponentFileSystem.downloadAsync) {
|
||||
throw new UnavailabilityError('expo-file-system', 'downloadAsync');
|
||||
}
|
||||
return await ExponentFileSystem.downloadAsync(uri, fileUri, {
|
||||
sessionType: FileSystemSessionType.BACKGROUND,
|
||||
...options,
|
||||
});
|
||||
}
|
||||
export async function uploadAsync(url, fileUri, options = {}) {
|
||||
if (!ExponentFileSystem.uploadAsync) {
|
||||
throw new UnavailabilityError('expo-file-system', 'uploadAsync');
|
||||
}
|
||||
return await ExponentFileSystem.uploadAsync(url, fileUri, {
|
||||
sessionType: FileSystemSessionType.BACKGROUND,
|
||||
uploadType: FileSystemUploadType.BINARY_CONTENT,
|
||||
...options,
|
||||
httpMethod: (options.httpMethod || 'POST').toUpperCase(),
|
||||
});
|
||||
}
|
||||
export function createDownloadResumable(uri, fileUri, options, callback, resumeData) {
|
||||
return new DownloadResumable(uri, fileUri, options, callback, resumeData);
|
||||
}
|
||||
export class DownloadResumable {
|
||||
constructor(url, fileUri, options = {}, callback, resumeData) {
|
||||
this._uuid = uuidv4();
|
||||
this._url = url;
|
||||
this._fileUri = fileUri;
|
||||
this._options = options;
|
||||
this._resumeData = resumeData;
|
||||
this._callback = callback;
|
||||
this._subscription = null;
|
||||
this._emitter = new EventEmitter(ExponentFileSystem);
|
||||
}
|
||||
async downloadAsync() {
|
||||
if (!ExponentFileSystem.downloadResumableStartAsync) {
|
||||
throw new UnavailabilityError('expo-file-system', 'downloadResumableStartAsync');
|
||||
}
|
||||
this._addSubscription();
|
||||
return await ExponentFileSystem.downloadResumableStartAsync(this._url, this._fileUri, this._uuid, this._options, this._resumeData);
|
||||
}
|
||||
async pauseAsync() {
|
||||
if (!ExponentFileSystem.downloadResumablePauseAsync) {
|
||||
throw new UnavailabilityError('expo-file-system', 'downloadResumablePauseAsync');
|
||||
}
|
||||
const pauseResult = await ExponentFileSystem.downloadResumablePauseAsync(this._uuid);
|
||||
this._removeSubscription();
|
||||
if (pauseResult) {
|
||||
this._resumeData = pauseResult.resumeData;
|
||||
return this.savable();
|
||||
}
|
||||
else {
|
||||
throw new Error('Unable to generate a savable pause state');
|
||||
}
|
||||
}
|
||||
async resumeAsync() {
|
||||
if (!ExponentFileSystem.downloadResumableStartAsync) {
|
||||
throw new UnavailabilityError('expo-file-system', 'downloadResumableStartAsync');
|
||||
}
|
||||
this._addSubscription();
|
||||
return await ExponentFileSystem.downloadResumableStartAsync(this._url, this._fileUri, this._uuid, this._options, this._resumeData);
|
||||
}
|
||||
savable() {
|
||||
return {
|
||||
url: this._url,
|
||||
fileUri: this._fileUri,
|
||||
options: this._options,
|
||||
resumeData: this._resumeData,
|
||||
};
|
||||
}
|
||||
_addSubscription() {
|
||||
if (this._subscription) {
|
||||
return;
|
||||
}
|
||||
this._subscription = this._emitter.addListener('expo-file-system.downloadProgress', (event) => {
|
||||
if (event.uuid === this._uuid) {
|
||||
const callback = this._callback;
|
||||
if (callback) {
|
||||
callback(event.data);
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
_removeSubscription() {
|
||||
if (!this._subscription) {
|
||||
return;
|
||||
}
|
||||
this._emitter.removeSubscription(this._subscription);
|
||||
this._subscription = null;
|
||||
}
|
||||
}
|
||||
//# sourceMappingURL=FileSystem.js.map
|
1
node_modules/expo-file-system/build/FileSystem.js.map
generated
vendored
Normal file
1
node_modules/expo-file-system/build/FileSystem.js.map
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
116
node_modules/expo-file-system/build/FileSystem.types.d.ts
generated
vendored
Normal file
116
node_modules/expo-file-system/build/FileSystem.types.d.ts
generated
vendored
Normal file
@ -0,0 +1,116 @@
|
||||
export declare enum FileSystemSessionType {
|
||||
BACKGROUND = 0,
|
||||
FOREGROUND = 1
|
||||
}
|
||||
export declare enum FileSystemUploadType {
|
||||
BINARY_CONTENT = 0,
|
||||
MULTIPART = 1
|
||||
}
|
||||
export declare type DownloadOptions = {
|
||||
md5?: boolean;
|
||||
cache?: boolean;
|
||||
headers?: Record<string, string>;
|
||||
sessionType?: FileSystemSessionType;
|
||||
};
|
||||
export declare type FileSystemHttpResult = {
|
||||
headers: Record<string, string>;
|
||||
status: number;
|
||||
mimeType: string | null;
|
||||
};
|
||||
export declare type FileSystemDownloadResult = FileSystemHttpResult & {
|
||||
uri: string;
|
||||
md5?: string;
|
||||
};
|
||||
/**
|
||||
* @deprecated Use `FileSystemDownloadResult` instead.
|
||||
*/
|
||||
export declare type DownloadResult = FileSystemDownloadResult;
|
||||
export declare type FileSystemUploadOptions = ({
|
||||
uploadType?: FileSystemUploadType.BINARY_CONTENT;
|
||||
} | {
|
||||
uploadType: FileSystemUploadType.MULTIPART;
|
||||
fieldName?: string;
|
||||
mimeType?: string;
|
||||
parameters?: Record<string, string>;
|
||||
}) & {
|
||||
headers?: Record<string, string>;
|
||||
httpMethod?: FileSystemAcceptedUploadHttpMethod;
|
||||
sessionType?: FileSystemSessionType;
|
||||
};
|
||||
export declare type FileSystemUploadResult = FileSystemHttpResult & {
|
||||
body: string;
|
||||
};
|
||||
export declare type DownloadProgressCallback = (data: DownloadProgressData) => void;
|
||||
export declare type DownloadProgressData = {
|
||||
totalBytesWritten: number;
|
||||
totalBytesExpectedToWrite: number;
|
||||
};
|
||||
export declare type DownloadPauseState = {
|
||||
url: string;
|
||||
fileUri: string;
|
||||
options: DownloadOptions;
|
||||
resumeData?: string;
|
||||
};
|
||||
export declare type FileInfo = {
|
||||
exists: true;
|
||||
uri: string;
|
||||
size: number;
|
||||
isDirectory: boolean;
|
||||
modificationTime: number;
|
||||
md5?: string;
|
||||
} | {
|
||||
exists: false;
|
||||
uri: string;
|
||||
size: undefined;
|
||||
isDirectory: false;
|
||||
modificationTime: undefined;
|
||||
md5: undefined;
|
||||
};
|
||||
export declare enum EncodingType {
|
||||
UTF8 = "utf8",
|
||||
Base64 = "base64"
|
||||
}
|
||||
export declare type FileSystemAcceptedUploadHttpMethod = 'POST' | 'PUT' | 'PATCH';
|
||||
export declare type ReadingOptions = {
|
||||
encoding?: EncodingType | 'utf8' | 'base64';
|
||||
position?: number;
|
||||
length?: number;
|
||||
};
|
||||
export declare type WritingOptions = {
|
||||
encoding?: EncodingType | 'utf8' | 'base64';
|
||||
};
|
||||
export declare type ProgressEvent = {
|
||||
uuid: string;
|
||||
data: {
|
||||
totalBytesWritten: number;
|
||||
totalBytesExpectedToWrite: number;
|
||||
};
|
||||
};
|
||||
declare type PlatformMethod = (...args: any[]) => Promise<any>;
|
||||
export interface ExponentFileSystemModule {
|
||||
readonly name: 'ExponentFileSystem';
|
||||
readonly documentDirectory: string | null;
|
||||
readonly cacheDirectory: string | null;
|
||||
readonly bundledAssets: string | null;
|
||||
readonly bundleDirectory: string | null;
|
||||
readonly getInfoAsync?: PlatformMethod;
|
||||
readonly readAsStringAsync?: PlatformMethod;
|
||||
readonly writeAsStringAsync?: PlatformMethod;
|
||||
readonly deleteAsync?: PlatformMethod;
|
||||
readonly moveAsync?: PlatformMethod;
|
||||
readonly copyAsync?: PlatformMethod;
|
||||
readonly makeDirectoryAsync?: PlatformMethod;
|
||||
readonly readDirectoryAsync?: PlatformMethod;
|
||||
readonly downloadAsync?: PlatformMethod;
|
||||
readonly uploadAsync?: PlatformMethod;
|
||||
readonly downloadResumableStartAsync?: PlatformMethod;
|
||||
readonly downloadResumablePauseAsync?: PlatformMethod;
|
||||
readonly getContentUriAsync?: PlatformMethod;
|
||||
readonly getFreeDiskStorageAsync?: PlatformMethod;
|
||||
readonly getTotalDiskCapacityAsync?: PlatformMethod;
|
||||
startObserving?: () => void;
|
||||
stopObserving?: () => void;
|
||||
addListener: (eventName: string) => void;
|
||||
removeListeners: (count: number) => void;
|
||||
}
|
||||
export {};
|
25
node_modules/expo-file-system/build/FileSystem.types.js
generated
vendored
Normal file
25
node_modules/expo-file-system/build/FileSystem.types.js
generated
vendored
Normal file
@ -0,0 +1,25 @@
|
||||
export var FileSystemSessionType;
|
||||
(function (FileSystemSessionType) {
|
||||
/*
|
||||
* Using this mode means that the downloading/uploading session on the native side will work even if the application is moved to background.
|
||||
*
|
||||
* If the task completes while the application is in background, the Promise will be either resolved immediately or (if the application execution has already been stopped) once the app is moved to foreground again.
|
||||
*/
|
||||
FileSystemSessionType[FileSystemSessionType["BACKGROUND"] = 0] = "BACKGROUND";
|
||||
/*
|
||||
* Using this mode means that downloading/uploading session on the native side will be terminated once the application becomes inactive (e.g. when it goes to background).
|
||||
* Bringing the application to foreground again would trigger Promise rejection.
|
||||
*/
|
||||
FileSystemSessionType[FileSystemSessionType["FOREGROUND"] = 1] = "FOREGROUND";
|
||||
})(FileSystemSessionType || (FileSystemSessionType = {}));
|
||||
export var FileSystemUploadType;
|
||||
(function (FileSystemUploadType) {
|
||||
FileSystemUploadType[FileSystemUploadType["BINARY_CONTENT"] = 0] = "BINARY_CONTENT";
|
||||
FileSystemUploadType[FileSystemUploadType["MULTIPART"] = 1] = "MULTIPART";
|
||||
})(FileSystemUploadType || (FileSystemUploadType = {}));
|
||||
export var EncodingType;
|
||||
(function (EncodingType) {
|
||||
EncodingType["UTF8"] = "utf8";
|
||||
EncodingType["Base64"] = "base64";
|
||||
})(EncodingType || (EncodingType = {}));
|
||||
//# sourceMappingURL=FileSystem.types.js.map
|
1
node_modules/expo-file-system/build/FileSystem.types.js.map
generated
vendored
Normal file
1
node_modules/expo-file-system/build/FileSystem.types.js.map
generated
vendored
Normal file
@ -0,0 +1 @@
|
||||
{"version":3,"file":"FileSystem.types.js","sourceRoot":"","sources":["../src/FileSystem.types.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,qBAYX;AAZD,WAAY,qBAAqB;IAC/B;;;;OAIG;IACH,6EAAc,CAAA;IACd;;;OAGG;IACH,6EAAc,CAAA;AAChB,CAAC,EAZW,qBAAqB,KAArB,qBAAqB,QAYhC;AAED,MAAM,CAAN,IAAY,oBAGX;AAHD,WAAY,oBAAoB;IAC9B,mFAAkB,CAAA;IAClB,yEAAa,CAAA;AACf,CAAC,EAHW,oBAAoB,KAApB,oBAAoB,QAG/B;AAgFD,MAAM,CAAN,IAAY,YAGX;AAHD,WAAY,YAAY;IACtB,6BAAa,CAAA;IACb,iCAAiB,CAAA;AACnB,CAAC,EAHW,YAAY,KAAZ,YAAY,QAGvB","sourcesContent":["export enum FileSystemSessionType {\n /*\n * Using this mode means that the downloading/uploading session on the native side will work even if the application is moved to background.\n *\n * If the task completes while the application is in background, the Promise will be either resolved immediately or (if the application execution has already been stopped) once the app is moved to foreground again.\n */\n BACKGROUND = 0,\n /*\n * Using this mode means that downloading/uploading session on the native side will be terminated once the application becomes inactive (e.g. when it goes to background).\n * Bringing the application to foreground again would trigger Promise rejection.\n */\n FOREGROUND = 1,\n}\n\nexport enum FileSystemUploadType {\n BINARY_CONTENT = 0,\n MULTIPART = 1,\n}\n\nexport type DownloadOptions = {\n md5?: boolean;\n cache?: boolean;\n headers?: Record<string, string>;\n /*\n * iOS only\n */\n sessionType?: FileSystemSessionType;\n};\n\nexport type FileSystemHttpResult = {\n headers: Record<string, string>;\n status: number;\n mimeType: string | null;\n};\n\nexport type FileSystemDownloadResult = FileSystemHttpResult & {\n uri: string;\n md5?: string;\n};\n\n/**\n * @deprecated Use `FileSystemDownloadResult` instead.\n */\nexport type DownloadResult = FileSystemDownloadResult;\n\nexport type FileSystemUploadOptions = (\n | {\n uploadType?: FileSystemUploadType.BINARY_CONTENT;\n }\n | {\n uploadType: FileSystemUploadType.MULTIPART;\n fieldName?: string;\n mimeType?: string;\n parameters?: Record<string, string>;\n }\n) & {\n headers?: Record<string, string>;\n httpMethod?: FileSystemAcceptedUploadHttpMethod;\n sessionType?: FileSystemSessionType;\n};\n\nexport type FileSystemUploadResult = FileSystemHttpResult & {\n body: string;\n};\n\nexport type DownloadProgressCallback = (data: DownloadProgressData) => void;\n\nexport type DownloadProgressData = {\n totalBytesWritten: number;\n totalBytesExpectedToWrite: number;\n};\n\nexport type DownloadPauseState = {\n url: string;\n fileUri: string;\n options: DownloadOptions;\n resumeData?: string;\n};\n\nexport type FileInfo =\n | {\n exists: true;\n uri: string;\n size: number;\n isDirectory: boolean;\n modificationTime: number;\n md5?: string;\n }\n | {\n exists: false;\n uri: string;\n size: undefined;\n isDirectory: false;\n modificationTime: undefined;\n md5: undefined;\n };\n\nexport enum EncodingType {\n UTF8 = 'utf8',\n Base64 = 'base64',\n}\n\nexport type FileSystemAcceptedUploadHttpMethod = 'POST' | 'PUT' | 'PATCH';\n\nexport type ReadingOptions = {\n encoding?: EncodingType | 'utf8' | 'base64';\n position?: number;\n length?: number;\n};\n\nexport type WritingOptions = {\n encoding?: EncodingType | 'utf8' | 'base64';\n};\n\nexport type ProgressEvent = {\n uuid: string;\n data: {\n totalBytesWritten: number;\n totalBytesExpectedToWrite: number;\n };\n};\n\ntype PlatformMethod = (...args: any[]) => Promise<any>;\n\nexport interface ExponentFileSystemModule {\n readonly name: 'ExponentFileSystem';\n readonly documentDirectory: string | null;\n readonly cacheDirectory: string | null;\n readonly bundledAssets: string | null;\n readonly bundleDirectory: string | null;\n readonly getInfoAsync?: PlatformMethod;\n readonly readAsStringAsync?: PlatformMethod;\n readonly writeAsStringAsync?: PlatformMethod;\n readonly deleteAsync?: PlatformMethod;\n readonly moveAsync?: PlatformMethod;\n readonly copyAsync?: PlatformMethod;\n readonly makeDirectoryAsync?: PlatformMethod;\n readonly readDirectoryAsync?: PlatformMethod;\n readonly downloadAsync?: PlatformMethod;\n readonly uploadAsync?: PlatformMethod;\n readonly downloadResumableStartAsync?: PlatformMethod;\n readonly downloadResumablePauseAsync?: PlatformMethod;\n readonly getContentUriAsync?: PlatformMethod;\n readonly getFreeDiskStorageAsync?: PlatformMethod;\n readonly getTotalDiskCapacityAsync?: PlatformMethod;\n startObserving?: () => void;\n stopObserving?: () => void;\n addListener: (eventName: string) => void;\n removeListeners: (count: number) => void;\n}\n"]}
|
1
node_modules/expo-file-system/build/index.d.ts
generated
vendored
Normal file
1
node_modules/expo-file-system/build/index.d.ts
generated
vendored
Normal file
@ -0,0 +1 @@
|
||||
export * from './FileSystem';
|
2
node_modules/expo-file-system/build/index.js
generated
vendored
Normal file
2
node_modules/expo-file-system/build/index.js
generated
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
export * from './FileSystem';
|
||||
//# sourceMappingURL=index.js.map
|
1
node_modules/expo-file-system/build/index.js.map
generated
vendored
Normal file
1
node_modules/expo-file-system/build/index.js.map
generated
vendored
Normal file
@ -0,0 +1 @@
|
||||
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC","sourcesContent":["export * from './FileSystem';\n"]}
|
Reference in New Issue
Block a user