Skip to content

Commit 38b0517

Browse files
a-sullyannevk
andauthored
Editorial: modernize getters and setters
Fixes #64. Co-authored-by: Anne van Kesteren <[email protected]>
1 parent 114593e commit 38b0517

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

index.bs

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -229,12 +229,11 @@ Their [=deserialization steps=], given |serialized| and |value| are:
229229
:: Returns the [=entry/name=] of the entry represented by |handle|.
230230
</div>
231231

232-
The <dfn attribute for=FileSystemHandle>kind</dfn> attribute must
233-
return {{FileSystemHandleKind/"file"}} if the associated [=FileSystemHandle/entry=] is a [=file entry=],
234-
and return {{FileSystemHandleKind/"directory"}} otherwise.
232+
The <dfn attribute for=FileSystemHandle>kind</dfn> getter steps are to return
233+
{{FileSystemHandleKind/"file"}} if [=this=] is a [=file entry=]; otherwise
234+
{{FileSystemHandleKind/"directory"}}.
235235

236-
The <dfn attribute for=FileSystemHandle>name</dfn> attribute must return the [=entry/name=] of the
237-
associated [=FileSystemHandle/entry=].
236+
The <dfn attribute for=FileSystemHandle>name</dfn> getter steps are to return [=this=]'s [=entry/name=].
238237

239238
### The {{FileSystemHandle/isSameEntry()}} method ### {#api-filesystemhandle-issameentry}
240239

@@ -299,9 +298,9 @@ The <dfn method for=FileSystemFileHandle>getFile()</dfn> method steps are:
299298
1. Let |f| be a new {{File}}.
300299
1. Set |f|'s <a spec=FileAPI>snapshot state</a> to the current state of |entry|.
301300
1. Set |f|'s underlying byte sequence to a copy of |entry|'s [=binary data=].
302-
1. Initialize the value of |f|'s {{File/name}} attribute to |entry|'s [=entry/name=].
303-
1. Initialize the value of |f|'s {{File/lastModified}} attribute to |entry|'s [=file entry/modification timestamp=].
304-
1. Initialize the value of |f|'s {{Blob/type}} attribute to an [=implementation-defined=] value, based on for example |entry|'s [=entry/name=] or its file extension.
301+
1. Set |f|.{{File/name}} to |entry|'s [=entry/name=].
302+
1. Set |f|.{{File/lastModified}} to |entry|'s [=file entry/modification timestamp=].
303+
1. Set |f|.{{Blob/type}} to an [=implementation-defined=] value, based on for example |entry|'s [=entry/name=] or its file extension.
305304

306305
Issue: The reading and snapshotting behavior needs to be better specified in the [[FILE-API]] spec,
307306
for now this is kind of hand-wavy.

0 commit comments

Comments
 (0)