File tree Expand file tree Collapse file tree 5 files changed +1
-23
lines changed
android/capacitor/src/main/java/com/getcapacitor/plugin
example/src/pages/filesystem
ios/Capacitor/Capacitor/Plugins
site/docs-md/apis/filesystem Expand file tree Collapse file tree 5 files changed +1
-23
lines changed Original file line number Diff line number Diff line change @@ -65,8 +65,6 @@ private Charset getEncoding(String encoding) {
65
65
private File getDirectory (String directory ) {
66
66
Context c = bridge .getContext ();
67
67
switch (directory ) {
68
- case "APPLICATION" :
69
- return c .getFilesDir ();
70
68
case "DOCUMENTS" :
71
69
return Environment .getExternalStoragePublicDirectory (Environment .DIRECTORY_DOCUMENTS );
72
70
case "DATA" :
Original file line number Diff line number Diff line change @@ -566,10 +566,6 @@ export interface FilesystemPlugin extends Plugin {
566
566
}
567
567
568
568
export enum FilesystemDirectory {
569
- /**
570
- * The Application directory
571
- */
572
- Application = 'APPLICATION' ,
573
569
/**
574
570
* The Documents directory
575
571
*/
Original file line number Diff line number Diff line change @@ -109,7 +109,7 @@ export class FilesystemPage {
109
109
try {
110
110
let ret = await Plugins . Filesystem . getUri ( {
111
111
path : 'text.txt' ,
112
- directory : FilesystemDirectory . Application
112
+ directory : FilesystemDirectory . Data
113
113
} ) ;
114
114
alert ( ret . uri ) ;
115
115
} catch ( e ) {
Original file line number Diff line number Diff line change @@ -12,8 +12,6 @@ public class CAPFilesystemPlugin : CAPPlugin {
12
12
switch directory {
13
13
case " DOCUMENTS " :
14
14
return . documentDirectory
15
- case " APPLICATION " :
16
- return . applicationDirectory
17
15
case " CACHE " :
18
16
return . cachesDirectory
19
17
default :
Original file line number Diff line number Diff line change @@ -137,20 +137,6 @@ async rename() {
137
137
}
138
138
}
139
139
140
- async copy () {
141
- try {
142
- // This example copies a file from the app directory to the documents directory
143
- let ret = await Filesystem .copy ({
144
- from: ' assets/icon.png' ,
145
- to: ' icon.png' ,
146
- directory: FilesystemDirectory .Application ,
147
- toDirectory: FilesystemDirectory .Documents
148
- });
149
- } catch (e ) {
150
- console .error (' Unable to copy file' , e );
151
- }
152
- }
153
-
154
140
async copy () {
155
141
try {
156
142
// This example copies a file within the documents directory
You can’t perform that action at this time.
0 commit comments