You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The following are the [=event handlers=] (and their corresponding [=event handler event types=]) that must be supported, as [=event handler IDL attributes=], by all {{CreateMonitor}} objects:
Every [=interface=][=interface/including=] the {{DestroyableModel}} interface mixin has a <dfn export for="DestroyableModel">destruction abort controller</dfn>, an {{AbortController}}, set by the [=initialize as a destroyable=] algorithm.
95
-
96
-
<p class="note">The [=DestroyableModel/destruction abort controller=] is only used internally, as a way of tracking calls to {{DestroyableModel/destroy()}}. Since it is easy to combine multiple {{AbortSignal}}s using [=create a dependent abort signal=], this lets us centralize handling of any {{AbortSignal}} the web developer provides to specific method calls, with any calls to {{DestroyableModel/destroy()}}.
97
-
98
-
<div algorithm>
99
-
To <dfn>initialize as a destroyable</dfn> an {{DestroyableModel}} object |destroyable|:
100
-
101
-
1. Let |controller| be a [=new=]{{AbortController}} created in |destroyable|'s [=relevant realm=].
102
-
103
-
1. Set |controller|'s [=AbortController/signal=] to a [=new=] {{AbortSignal}} created in |destroyable|'s [=relevant realm=].
104
-
105
-
1. Set |destroyable|'s [=DestroyableModel/destruction abort controller=] to |controller|.
106
-
</div>
107
-
108
-
<div algorithm>
109
-
<p>The <dfn method for="DestroyableModel">destroy()</dfn> method steps are to [=DestroyableModel/destroy=][=this=] given a new "{{AbortError}}" {{DOMException}}.
110
-
</div>
111
-
112
-
<div algorithm>
113
-
To <dfn for="DestroyableModel">destroy</dfn> an {{DestroyableModel}} |destroyable|, given a JavaScript value |reason|:
114
-
115
-
1. [=AbortController/Signal abort=] given |destroyable|'s [=DestroyableModel/destruction abort controller=] and |reason|.
116
-
117
-
1. The user agent should release any resources associated with |destroyable|, such as AI models loaded to support its operation, as long as those resources are not needed for other ongoing operations.
118
-
</div>
119
-
120
-
121
55
<h2 id="summarizer-api">The summarizer API</h2>
122
56
123
57
<xmp class="idl">
@@ -1720,6 +1654,71 @@ Access to the rewriter API is gated behind the [=policy-controlled feature=] "<d
The following are the [=event handlers=] (and their corresponding [=event handler event types=]) that must be supported, as [=event handler IDL attributes=], by all {{CreateMonitor}} objects:
Every [=interface=][=interface/including=] the {{DestroyableModel}} interface mixin has a <dfn export for="DestroyableModel">destruction abort controller</dfn>, an {{AbortController}}, set by the [=initialize as a destroyable=] algorithm.
1697
+
1698
+
<p class="note">The [=DestroyableModel/destruction abort controller=] is only used internally, as a way of tracking calls to {{DestroyableModel/destroy()}}. Since it is easy to combine multiple {{AbortSignal}}s using [=create a dependent abort signal=], this lets us centralize handling of any {{AbortSignal}} the web developer provides to specific method calls, with any calls to {{DestroyableModel/destroy()}}.
1699
+
1700
+
<div algorithm>
1701
+
To <dfn>initialize as a destroyable</dfn> an {{DestroyableModel}} object |destroyable|:
1702
+
1703
+
1. Let |controller| be a [=new=]{{AbortController}} created in |destroyable|'s [=relevant realm=].
1704
+
1705
+
1. Set |controller|'s [=AbortController/signal=] to a [=new=] {{AbortSignal}} created in |destroyable|'s [=relevant realm=].
1706
+
1707
+
1. Set |destroyable|'s [=DestroyableModel/destruction abort controller=] to |controller|.
1708
+
</div>
1709
+
1710
+
<div algorithm>
1711
+
<p>The <dfn method for="DestroyableModel">destroy()</dfn> method steps are to [=DestroyableModel/destroy=][=this=] given a new "{{AbortError}}" {{DOMException}}.
1712
+
</div>
1713
+
1714
+
<div algorithm>
1715
+
To <dfn for="DestroyableModel">destroy</dfn> an {{DestroyableModel}} |destroyable|, given a JavaScript value |reason|:
1716
+
1717
+
1. [=AbortController/Signal abort=] given |destroyable|'s [=DestroyableModel/destruction abort controller=] and |reason|.
1718
+
1719
+
1. The user agent should release any resources associated with |destroyable|, such as AI models loaded to support its operation, as long as those resources are not needed for other ongoing operations.
0 commit comments