Skip to content

Commit 69cf44b

Browse files
author
Nathan Memmott
committed
Define File System concept
Pulls out some implementation-defined concepts into a file system concept. This is so that the file system concept can be extended further in the future.
1 parent f1c7d6f commit 69cf44b

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

index.bs

+11-11
Original file line numberDiff line numberDiff line change
@@ -325,9 +325,9 @@ To <dfn for="file system locator" id=locator-resolve>resolve</dfn> a
325325
The <dfn export data-lt="locating an entry">locate an entry</dfn> algorithm given a
326326
[=/file system locator=] |locator| runs the following steps:
327327

328-
1. Let |file system| be |locator|'s [=file system locator/file system=].
328+
1. Let |fileSystem| be |locator|'s [=file system locator/file system=].
329329
1. Let |path| be |locator|'s [=file system locator/path=].
330-
1. Let |entry| be the result of running |file system|'s
330+
1. Let |entry| be the result of running |fileSystem|'s
331331
[=file system/locate an entry=] given |path|.
332332
1. If |entry| is null, return null.
333333
1. If |locator| is a [=file locator=], [=Assert=]: |entry| is a [=file entry=].
@@ -340,11 +340,11 @@ The <dfn export data-lt="locating an entry">locate an entry</dfn> algorithm give
340340
The <dfn export data-lt="getting the locator">get the locator</dfn> algorithm given a
341341
[=/file system entry=] |entry| runs the following steps:
342342

343-
1. Let |file system| be |entry|'s [=file system entry/file system=].
344-
1. Let |path| be the result of running |file system|'s
343+
1. Let |fileSystem| be |entry|'s [=file system entry/file system=].
344+
1. Let |path| be the result of running |fileSystem|'s
345345
[=file system/get the path=] given |entry|.
346346
1. Let |locator| be a [=file system locator=] whose [=file system locator/path=]
347-
is |path| and whose [=file system locator/file system=] is |file system|.
347+
is |path| and whose [=file system locator/file system=] is |fileSystem|.
348348
1. If |entry| is a [=file entry=], set |locator|'s [=file system locator/kind=] to "file".
349349
1. If |entry| is a [=directory entry=], set |locator|'s [=file system locator/kind=] to "directory".
350350
1. Return |entry|.
@@ -495,13 +495,13 @@ given a [=directory locator=] |parentLocator| and a string |name| in a [=/Realm=
495495
<div algorithm>
496496
To
497497
<dfn export data-lt="creating a new FileSystemFileHandle">create a new `FileSystemFileHandle`</dfn>
498-
given a [=/file system=] |file system| and a [=/file system path=] |path|
498+
given a [=/file system=] |fileSystem| and a [=/file system path=] |path|
499499
in a [=/Realm=] |realm|:
500500

501501
1. Let |handle| be a [=new=] {{FileSystemFileHandle}} in |realm|.
502502
1. Set |handle|'s [=FileSystemHandle/locator=] to a [=/file system locator=] whose
503503
[=file system locator/kind=] is "{{FileSystemHandleKind/file}}",
504-
[=file system locator/file system=] is |file system|, and
504+
[=file system locator/file system=] is |fileSystem|, and
505505
[=file system locator/path=] is |path|.
506506
1. Return |handle|.
507507

@@ -750,13 +750,13 @@ given a [=directory locator=] |parentLocator| and a string |name| in a [=/Realm=
750750
<div algorithm>
751751
To
752752
<dfn export data-lt="creating a new FileSystemDirectoryHandle">create a new `FileSystemDirectoryHandle`</dfn>
753-
given a [=/file system=] |file system| and a [=/file system path=] |path|
753+
given a [=/file system=] |fileSystem| and a [=/file system path=] |path|
754754
in a [=/Realm=] |realm|:
755755

756756
1. Let |handle| be a [=new=] {{FileSystemDirectoryHandle}} in |realm|.
757757
1. Set |handle|'s [=FileSystemHandle/locator=] to a [=/file system locator=] whose
758758
[=file system locator/kind=] is "{{FileSystemHandleKind/directory}}",
759-
[=file system locator/file system=] is |file system|, and
759+
[=file system locator/file system=] is |fileSystem|, and
760760
[=file system locator/path=] is |path|.
761761
1. Return |handle|.
762762

@@ -1764,10 +1764,10 @@ The <dfn method for=StorageManager>getDirectory()</dfn> method steps are:
17641764
1. Set |dir|'s [=directory entry/children=] to an empty [=/set=].
17651765
1. Set |map|["root"] to |dir|.
17661766

1767-
1. Let |file system| be [=/bucket file system=]'s [=file system/root=].
1767+
1. Let |fileSystem| be [=/bucket file system=]'s [=file system/root=].
17681768
1. Let |path| be « the empty string ».
17691769
1. Let |handle| be the result of <a>creating a new `FileSystemDirectoryHandle`</a>.
1770-
given |file system| and |path| in the [=current realm=].
1770+
given |fileSystem| and |path| in the [=current realm=].
17711771

17721772
1. Assert: [=locating an entry=] given |handle|'s [=FileSystemHandle/locator=]
17731773
returns a [=directory entry=] that is [=the same entry as=] |map|["root"].

0 commit comments

Comments
 (0)