Skip to content

Commit 823f60a

Browse files
committed
chore: use TD 1.1 REC instead of custom reference
1 parent fc93e2d commit 823f60a

File tree

1 file changed

+30
-36
lines changed

1 file changed

+30
-36
lines changed

index.html

Lines changed: 30 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -53,14 +53,8 @@
5353
],
5454
xref: ["web-platform", "HTML", "INFRA", "URL", "WEBIDL", "DOM", "FETCH",
5555
"ecmascript", "streams",
56-
"wot-architecture11", "wot-thing-description", "wot-binding-templates"],
56+
"wot-architecture11", "wot-thing-description11", "wot-binding-templates"],
5757
localBiblio: {
58-
"WOT-TD" : {
59-
href:"https://www.w3.org/TR/2023/CR-wot-thing-description11-20230119/",
60-
title: "Web of Things (WoT) Thing Description 1.1",
61-
publisher: "W3C",
62-
date: "19 January 2023"
63-
},
6458
"WOT-DISCOVERY" : {
6559
href:"https://www.w3.org/TR/2023/CR-wot-discovery-20230119/",
6660
title: "Web of Things (WoT) Discovery",
@@ -177,7 +171,7 @@
177171
This specification describes an application programming interface (API) representing the <a>WoT Interface</a> that allows scripts to discover, operate <a>Thing</a>s and to expose locally defined <a>Thing</a>s characterized by <a> WoT Interactions</a> specified by a script.
178172
</p>
179173
<p>
180-
The APIs defined in this document deliberately follow the [[[WOT-TD]]] specification closely. It is possible to implement more abstract APIs on top of them, or implementing directly the WoT network facing interface (i.e. the <a>WoT Interface</a>).
174+
The APIs defined in this document deliberately follow the [[[wot-thing-description11]]] specification closely. It is possible to implement more abstract APIs on top of them, or implementing directly the WoT network facing interface (i.e. the <a>WoT Interface</a>).
181175
</p>
182176
<p class="ednote">
183177
This specification is implemented at least by the <a href="https://www.thingweb.io/">Eclipse Thingweb</a>
@@ -380,13 +374,13 @@
380374
<section> <h2>Terminology and conventions</h2>
381375
<p>
382376
The generic WoT terminology is defined in [[!wot-architecture11]]: <dfn data-lt="Things">Thing</dfn>, <dfn data-lt="Thing Descriptions">Thing Description</dfn> (in short <dfn>TD</dfn>), <dfn>Partial TD</dfn>, <dfn>Web of Things</dfn> (in short <b><i>WoT</i></b>), <dfn>WoT Interface</dfn>, <dfn>Protocol Bindings</dfn>, <dfn>WoT Runtime</dfn>, <dfn data-lt="consume|consume a TD|consuming a TD">Consuming a Thing Description</dfn>, <dfn>TD Directory</dfn>, <dfn data-lt="Properties">Property</dfn>, <dfn data-lt="Actions">Action</dfn>, <dfn data-lt="Events|WoT-Event">Event</dfn>,
383-
<a data-cite="WOT-TD#dataschema">
384-
<dfn>DataSchema</dfn></a>, <a data-cite="WOT-TD#form"><dfn data-lt="Forms">Form</dfn></a>,
385-
<a data-cite="WOT-TD#securityscheme"><dfn>SecurityScheme</dfn></a>, <a data-cite="WOT-TD#nosecurityscheme"><dfn>NoSecurityScheme</dfn></a> etc.
377+
<a data-cite="wot-thing-description11#dataschema">
378+
<dfn>DataSchema</dfn></a>, <a data-cite="wot-thing-description11#form"><dfn data-lt="Forms">Form</dfn></a>,
379+
<a data-cite="wot-thing-description11#securityscheme"><dfn>SecurityScheme</dfn></a>, <a data-cite="wot-thing-description11#nosecurityscheme"><dfn>NoSecurityScheme</dfn></a> etc.
386380
</p>
387381
<p>
388382
<dfn data-plurals="WoT Interactions">WoT Interaction</dfn> is a synonym for <a data-cite="wot-architecture11#dfn-interaction-affordance"><dfn>Interaction Affordance</dfn></a>.
389-
An <a>Interaction Affordance</a> (or shortly, affordance) is the term used in [[!WOT-TD]]
383+
An <a>Interaction Affordance</a> (or shortly, affordance) is the term used in [[!wot-thing-description11]]
390384
when referring to <a>Thing</a> capabilities, as explained in
391385
<a href="https://github.com/w3c/wot-thing-description/issues/282">TD issue 282</a>.
392386
However, this term is not well understood outside the <a>TD</a> semantic context.
@@ -479,9 +473,9 @@ <h2>The <dfn>ThingDescription</dfn> type</h2>
479473

480474
<p>
481475
Represents a <a>Thing Description</a> (<a>TD</a>) as
482-
<a data-cite="WOT-TD#">defined</a> in
483-
[[!WOT-TD]]. It is expected to be
484-
a <a data-cite="infra#parse-json-bytes-to-a-javascript-value">parsed JSON object</a> that is validated using <a data-cite="WOT-TD#json-schema-for-validation">JSON Schema validation</a>.
476+
<a data-cite="wot-thing-description11#">defined</a> in
477+
[[!wot-thing-description11]]. It is expected to be
478+
a <a data-cite="infra#parse-json-bytes-to-a-javascript-value">parsed JSON object</a> that is validated using <a data-cite="wot-thing-description11#json-schema-for-validation">JSON Schema validation</a>.
485479
</p>
486480
<section> <h3> Requesting a Thing Description</h3>
487481
<p>
@@ -503,31 +497,31 @@ <h2>The <dfn>ThingDescription</dfn> type</h2>
503497

504498
<section> <h3>Expanding a Thing Description</h3>
505499
<p>
506-
Note that the [[[WOT-TD]]] specification allows using a shortened <a>Thing Description</a>
507-
by the means of <a data-cite="WOT-TD#sec-default-values">defaults</a> and requiring clients to expand them with default values specified in the
508-
[[[WOT-TD]]] specification for the properties that are not explicitly defined in a given
500+
Note that the [[[wot-thing-description11]]] specification allows using a shortened <a>Thing Description</a>
501+
by the means of <a data-cite="wot-thing-description11#sec-default-values">defaults</a> and requiring clients to expand them with default values specified in the
502+
[[[wot-thing-description11]]] specification for the properties that are not explicitly defined in a given
509503
<a>TD</a>.
510504
</p>
511505
<div>
512506
To <dfn>expand a TD</dfn> given |td:ThingDescription|, run the following steps:
513507
<ol>
514508
<li>
515-
For each item in the <a data-cite="WOT-TD#sec-default-values">TD default values</a> table from [[!WOT-TD]], if the term is not defined in |td|, add the term definition with the default value specified in [[!WOT-TD]].
509+
For each item in the <a data-cite="wot-thing-description11#sec-default-values">TD default values</a> table from [[!wot-thing-description11]], if the term is not defined in |td|, add the term definition with the default value specified in [[!wot-thing-description11]].
516510
</li>
517511
</ol>
518512
</div>
519513
</section>
520514

521515
<section> <h3>Validating a Thing Description</h3>
522516
<p>
523-
The [[!WOT-TD]] specification defines how a <a>TD</a> should be validated.
517+
The [[!wot-thing-description11]] specification defines how a <a>TD</a> should be validated.
524518
Therefore, this API expects the {{ThingDescription}} objects be validated before used as parameters. This specification defines a basic <a>TD</a> validation as follows.
525519
</p>
526520
<div>
527521
To <dfn>validate a TD</dfn> given |td:ThingDescription|, run the following steps:
528522
<ol>
529523
<li>
530-
If <a data-cite="WOT-TD#json-schema-for-validation">JSON Schema
524+
If <a data-cite="wot-thing-description11#json-schema-for-validation">JSON Schema
531525
validation</a> fails on |td|, [= exception/throw =] a {{"TypeError"}} and stop.
532526
</li>
533527
</ol>
@@ -568,7 +562,7 @@ <h2>The <dfn>WOT</dfn> namespace</dfn></h2>
568562
Let |thing:ConsumedThing| be a new {{ConsumedThing}} object constructed from |td|.
569563
</li>
570564
<li>
571-
Set up the <a>WoT Interactions</a> based on introspecting <a>td</a> as explained in [[!WOT-TD]] and [[!WOT-PROTOCOL-BINDINGS]]. Make a request to the underlying platform to initialize the <a>Protocol Bindings</a>.
565+
Set up the <a>WoT Interactions</a> based on introspecting <a>td</a> as explained in [[!wot-thing-description11]] and [[!WOT-PROTOCOL-BINDINGS]]. Make a request to the underlying platform to initialize the <a>Protocol Bindings</a>.
572566
<p class="ednote">
573567
Implementations encapsulate the complexity of how to use the
574568
<a>Protocol Bindings</a> for implementing <a>WoT interactions</a>.
@@ -650,7 +644,7 @@ <h3>Expand an ExposedThingInit</h3>
650644
</ol>
651645
</li>
652646
<li>Search for missing required properties in |td| accordingly to
653-
<a data-cite="WOT-TD#json-schema-for-validation">TD JSON
647+
<a data-cite="wot-thing-description11#json-schema-for-validation">TD JSON
654648
Schema</a>.
655649
<p class="ednote">The editors find this step vague. It will be improved or removed in the next iteration. </p>
656650
</li>
@@ -681,7 +675,7 @@ <h3>Validating an ExposedThingInit</h3>
681675
To <dfn>validate an ExposedThingInit</dfn> given |init:ExposedThingInit|, run the following steps:
682676
<ol class="algorithm">
683677
<li>
684-
Parse <a data-cite="WOT-TD#json-schema-for-validation">TD JSON
678+
Parse <a data-cite="wot-thing-description11#json-schema-for-validation">TD JSON
685679
Schema</a>
686680
and load it in object called |exposedThingInitSchema:object|
687681
</li>
@@ -861,10 +855,10 @@ <h3>Validating an ExposedThingInit</h3>
861855

862856
<section data-cite="webidl"> <h2>Handling interaction data</h2>
863857
<p>
864-
As specified in the [[[WOT-TD]]] specification, <a>WoT interactions</a> extend <a>DataSchema</a>
858+
As specified in the [[[wot-thing-description11]]] specification, <a>WoT interactions</a> extend <a>DataSchema</a>
865859
and include a number of possible <a>Form</a>s, out of which one is selected
866860
for the interaction. The
867-
<a data-cite="WOT-TD#form">
861+
<a data-cite="wot-thing-description11#form">
868862
Form</a> contains a `contentType` to describe the data.
869863
For certain content types, a <a>DataSchema</a> is defined, based on
870864
<a>JSON Schema</a>, making possible to represent these contents as
@@ -883,7 +877,7 @@ <h2>The <dfn>InteractionInput</dfn> type</h2>
883877
</p>
884878
<p>
885879
<dfn>DataSchemaValue</dfn> is an
886-
<a data-cite="ECMASCRIPT#sec-ecmascript-data-types-and-values">ECMAScript value</a> that is accepted for <a>DataSchema</a> defined in [[WoT-TD]].
880+
<a data-cite="ECMASCRIPT#sec-ecmascript-data-types-and-values">ECMAScript value</a> that is accepted for <a>DataSchema</a> defined in [[wot-thing-description11]].
887881
The possible values MUST be of type <a data-cite="ECMASCRIPT#sec-ecmascript-language-types-null-type">null</a>, <a data-cite="ECMASCRIPT#sec-ecmascript-language-types-boolean-type">boolean</a>, <a data-cite="ECMASCRIPT#sec-ecmascript-language-types-number-type">number</a>, <a data-cite="ECMASCRIPT#sec-ecmascript-language-types-string-type">string</a>, <a data-cite="ECMASCRIPT#sec-array-objects">array</a>, or <a data-cite="ECMASCRIPT#sec-object-type">object</a>.
888882
</p>
889883
<p>
@@ -949,7 +943,7 @@ <h2>The <dfn>InteractionOutput</dfn> interface</h2>
949943
</p>
950944
<p>
951945
The <dfn>schema</dfn> attribute represents the <a>DataSchema</a>
952-
(defined in [[WoT-TD]]) of the payload as a {{JSON}} object, initially `null`.
946+
(defined in [[wot-thing-description11]]) of the payload as a {{JSON}} object, initially `null`.
953947
</p>
954948
<p>
955949
The <dfn data-lt="value">[[\value]]</dfn> internal slot represents the parsed value of
@@ -2169,10 +2163,10 @@ <h3>
21692163
The <dfn>uriVariables</dfn> property if defined, represents the URI
21702164
template variables to be used with the WoT Interaction that are represented
21712165
as <a data-cite="infra#parse-json-bytes-to-a-javascript-value">
2172-
parsed JSON objects</a> defined in [[!WOT-TD]].
2166+
parsed JSON objects</a> defined in [[!wot-thing-description11]].
21732167
</p>
21742168
<p class="ednote">
2175-
The support for URI variables comes from the need, exposed by the [[[WOT-TD]]] specification, to be able to describe
2169+
The support for URI variables comes from the need, exposed by the [[[wot-thing-description11]]] specification, to be able to describe
21762170
existing RESTful endpoints that use them. However, it should be possible to write a Thing Description that would use
21772171
<a>Action</a>s for representing this kind of interactions and model the URI variables as action parameters. In that case,
21782172
implementations can serialize the parameters as URI variables, and therefore, the |options| parameter could be
@@ -3600,7 +3594,7 @@ <h3>The <dfn>EventSubscriptionHandler</dfn> callback</h3>
36003594
</li>
36013595
<li>
36023596
Set up the <a>WoT Interactions</a> based on introspecting {{ExposedThing/[[td]]}}
3603-
as explained in [[!WOT-TD]] and [[!WOT-PROTOCOL-BINDINGS]].
3597+
as explained in [[!wot-thing-description11]] and [[!WOT-PROTOCOL-BINDINGS]].
36043598
Make a request to the underlying platform to initialize the
36053599
<a>Protocol Bindings</a> and then start serving external requests
36063600
for <a>WoT Interactions</a> (read, write and observe <a>Properties</a>,
@@ -4261,7 +4255,7 @@ <h2>API design rationale</h2>
42614255
lock.open('withThisKey');
42624256
</pre>
42634257
</section>
4264-
<section> <h3>This API, aligned with the [[[WOT-TD]]] specification</h3>
4258+
<section> <h3>This API, aligned with the [[[wot-thing-description11]]] specification</h3>
42654259
<p>
42664260
Since the direct mapping of <a>Thing</a>s to software objects have had
42674261
some challenges, this specification takes another approach that
@@ -4286,11 +4280,11 @@ <h2>API design rationale</h2>
42864280
</section>
42874281
<p>
42884282
In conclusion, the WoT WG decided to explore the third option that
4289-
closely follows the [[[WOT-TD]]] specification. Based on this, a simple
4283+
closely follows the [[[wot-thing-description11]]] specification. Based on this, a simple
42904284
API can also be implemented.
42914285
Since Scripting is an optional module in WoT, this leaves room for
42924286
applications that only use the <a>WoT network interface</a>.
4293-
Therefore all three approaches above are supported by the [[[WOT-TD]]] specification.
4287+
Therefore all three approaches above are supported by the [[[wot-thing-description11]]] specification.
42944288
</p>
42954289
<p>
42964290
Moreover, the <a>WoT network interface</a> can be implemented in many languages
@@ -4313,7 +4307,7 @@ <h4>Requesting and validating a TD</h4>
43134307
HTTP client library, which offer already standardized options on
43144308
specifying fetch details.
43154309
In these cases, the user is required to perform validation manually as
4316-
described by the [[[WOT-TD]]] specification.
4310+
described by the [[[wot-thing-description11]]] specification.
43174311
</p>
43184312
<p class="ednote" title="Extending the `requestThingDescription()` method">
43194313
In the future, `requestThingDescription()` might be extended with an
@@ -4353,7 +4347,7 @@ <h4>Requesting and validating a TD</h4>
43534347
</section>
43544348
<section> <h4>Polymorphic functions</h4>
43554349
<p>
4356-
The reason to use function names like <code>readProperty()</code>, <code>readMultipleProperties()</code> etc. instead of a generic polymorphic <code>read()</code> function is that the current names map exactly to the <code>"op"</code> vocabulary from the <a data-cite="WOT-TD#form">Form</a> definition in the [[[WOT-TD]]] specification.
4350+
The reason to use function names like <code>readProperty()</code>, <code>readMultipleProperties()</code> etc. instead of a generic polymorphic <code>read()</code> function is that the current names map exactly to the <code>"op"</code> vocabulary from the <a data-cite="wot-thing-description11#form">Form</a> definition in the [[[wot-thing-description11]]] specification.
43574351
</p>
43584352
</section>
43594353
</section>

0 commit comments

Comments
 (0)