@@ -132,7 +132,11 @@ public Builder allowHostIO(HostIO b) {
132
132
133
133
/**
134
134
* The mount point for the virtual filesystem on Windows. This mount point shadows any real
135
- * filesystem, so should be chosen to avoid clashes with the users machine.
135
+ * filesystem, so should be chosen to avoid clashes with the users machine, e.g. if set to
136
+ * "X:\graalpy_vfs", then a resource with path /org.graalvm.python.vfs/xyz/abc is visible as
137
+ * "X:\graalpy_vfs\xyz\abc". This needs to be an absolute path with platform-specific
138
+ * separators without any trailing separator. If that file or directory actually exists, it
139
+ * will not be accessible.
136
140
*/
137
141
public Builder windowsMountPoint (String s ) {
138
142
windowsMountPoint = s ;
@@ -141,7 +145,11 @@ public Builder windowsMountPoint(String s) {
141
145
142
146
/**
143
147
* The mount point for the virtual filesystem on Unices. This mount point shadows any real
144
- * filesystem, so should be chosen to avoid clashes with the users machine.
148
+ * filesystem, so should be chosen to avoid clashes with the users machine, e.g. if set to
149
+ * "/graalpy_vfs", then a resource with path /org.graalvm.python.vfs/xyz/abc is visible as
150
+ * "/graalpy_vfs/xyz/abc". This needs to be an absolute path with platform-specific
151
+ * separators without any trailing separator. If that file or directory actually exists, it
152
+ * will not be accessible.
145
153
*/
146
154
public Builder unixMountPoint (String s ) {
147
155
unixMountPoint = s ;
@@ -259,7 +267,7 @@ public DirEntry(String platformPath) {
259
267
260
268
/*
261
269
* Determines where the virtual filesystem lives in the real filesystem, e.g. if set to
262
- * "X:\graalpy_vfs", then a resource with path /vfs/xyz/abc is visible as
270
+ * "X:\graalpy_vfs", then a resource with path /org.graalvm.python. vfs/xyz/abc is visible as
263
271
* "X:\graalpy_vfs\xyz\abc". This needs to be an absolute path with platform-specific separators
264
272
* without any trailing separator. If that file or directory actually exists, it will not be
265
273
* accessible.
@@ -493,12 +501,14 @@ private BaseEntry getEntry(Path inputPath) throws IOException {
493
501
return vfsEntries .get (toCaseComparable (path .toString ()));
494
502
}
495
503
496
- public String getPrefix () {
497
- return this .vfsPrefix ;
498
- }
499
-
500
- public String getFileListPath () {
501
- return this .filesListPath ;
504
+ /**
505
+ * The mount point for the virtual filesystem.
506
+ *
507
+ * @see Builder#windowsMountPoint(String)
508
+ * @see Builder#unixMountPoint(String)
509
+ */
510
+ public String getMountPoint () {
511
+ return this .mountPoint .toString ();
502
512
}
503
513
504
514
private boolean pathIsInVfs (Path path ) {
@@ -514,8 +524,8 @@ private boolean shouldExtract(Path path) {
514
524
515
525
/**
516
526
* Extracts a file or directory from the resource to the temporary directory and returns the
517
- * path to the extracted file. Inexisting parent directories will also be created (recursively).
518
- * If the extracted file or directory already exists, nothing will be done.
527
+ * path to the extracted file. Nonexistent parent directories will also be created
528
+ * (recursively). If the extracted file or directory already exists, nothing will be done.
519
529
*/
520
530
private Path getExtractedPath (Path path ) {
521
531
assert extractDir != null ;
0 commit comments