Skip to content

Commit

Permalink
build struct
Browse files Browse the repository at this point in the history
  • Loading branch information
rubberyuzu committed Jul 10, 2023
1 parent 1e42096 commit 499b44b
Showing 1 changed file with 32 additions and 26 deletions.
58 changes: 32 additions & 26 deletions source
Original file line number Diff line number Diff line change
Expand Up @@ -93140,6 +93140,19 @@ interface <dfn interface>NotRestoredReasons</dfn> {
data-x="dom-not-restored-reasons-reasons">reasons</span>'s <span>backing list</span> with
<var>backingStruct</var>'s <span data-x="dom-not-restored-reasons-reasons">reasons</span>.</p></li>

<li><p>If <var>backingStruct</var>'s <span data-x="dom-not-restored-reasons-children">children</span>
is null, set <var>notRestoredReasons</var>'s <span
data-x="dom-not-restored-reasons-children">children</span> to null. If not, <span
data-x="list iterate">for each</span> <var>child</var> of <var>backingStruct</var>'s <span
data-x="dom-not-restored-reasons-children">children</span>:</p>
<ol>
<li><p><span>Create a <code>NotRestoredReasons</code> object</span> given <var>child</var> and
<var>realm</var> and <span data-x="list append">append</span> it to <var>notRestoredReasons</var>'s
<span data-x="dom-not-restored-reasons-children">children</span>'s <span>backing list</span>.</p></li>
</ol>
</li>

<li><p>Return <var>notRestoredReasons</var>.</p></li>
</ol>

<p>A <dfn data-x="nrr-struct">not restored reasons</dfn> is a <span>struct</span> with the
Expand Down Expand Up @@ -95114,7 +95127,7 @@ interface <dfn interface>NotRestoredReasons</dfn> {
name</dfn> string, initially the empty string.</p></li>

<li><p>A <dfn data-x="document-state-not-restored-reasons">notRestoredReasons</dfn>, a
<code>NotRestoredReasons</code> or null, initially null.</p></li>
<code data-x="nrr-struct">not restored reasons</code> or null, initially null.</p></li>
</ul>

<p>User agents may <span data-x="destroy a Document">destroy</span> the <span
Expand Down Expand Up @@ -99833,13 +99846,12 @@ location.href = '#foo';</code></pre>
state to false.</p></li>
</ol>

<p>To <dfn>build NotRestoredReasons object for document</dfn> given <code>Document</code>
<p>To <dfn>build not restored reasons for document</dfn> given <code>Document</code>
<var>document</var>:</p>

<ol>
<li><p>Let <var>notRestoredReasonsForDocument</var> be a new <code>NotRestoredReasons</code>
object, created in the <span data-x="concept-relevant-realm">relevant realm</span> of
<var>document</var>.</p></li>
<li><p>Let <var>notRestoredReasonsForDocument</var> be a new <code
data-x="nrr-struct">not restored reasons</code>.</p></li>

<li><p>Set <var>notRestoredReasonsForDocument</var>'s <span
data-x="dom-not-restored-reasons-url">URL</span> to <var>document</var>'s <span
Expand All @@ -99849,38 +99861,34 @@ location.href = '#foo';</code></pre>
data-x="nav-container">container</span> is an <code>iframe</code> element, then:</p>
<ol>
<li><p>Set the value of <var>notRestoredReasonsForDocument</var>'s <span
data-x="dom-not-restored-reasons-src">src</span> attribute to <var>document</var>'s
<span>node navigable</span>'s <span data-x="nav-container">container</span>'s
<code data-x="attr-iframe-src">src</code> attribute.</p></li>
data-x="nrr-src">src</span> to <var>document</var>'s <span>node navigable</span>'s <span
data-x="nav-container">container</span>'s <code data-x="attr-iframe-src">src</code> attribute.</p></li>

<li><p>Set the value of <var>notRestoredReasonsForDocument</var>'s <span
data-x="dom-not-restored-reasons-id">id</span> attribute to <var>document</var>'s
<span>node navigable</span>'s <span data-x="nav-container">container</span>'s
<code data-x="attr-id">id</code> attribute.</p></li>
data-x="nrr-id">id</span> to <var>document</var>'s <span>node navigable</span>'s <span
data-x="nav-container">container</span>'s <code data-x="attr-id">id</code> attribute.</p></li>

<li><p>Set the value of <var>notRestoredReasonsForDocument</var>'s <span
data-x="dom-not-restored-reasons-name">name</span> attribute to <var>document</var>'s
<span>node navigable</span>'s <span data-x="nav-container">container</span>'s
<code data-x="attr-iframe-name">name</code> attribute.</p></li>
data-x="nrr-name">name</span> to <var>document</var>'s <span>node navigable</span>'s <span
data-x="nav-container">container</span>'s <code data-x="attr-iframe-name">name</code> attribute.</p></li>
</ol>
</li>

<li><p><span data-x="list iterate">For each</span> <var>reason</var> of <var>document</var>'s
<span data-x="concept-document-bfcache-blocking-reasons">bfcache blocking reasons</span>:</p>
<ol>
<li><p><span data-x="list append">Append</span> <var>reason</var> to
<var>notRestoredReasonsForDocument</var>'s <code
data-x="dom-not-restored-reasons-reasons">reasons</code>'s <span>backing list</span>.</p></li>
<var>notRestoredReasonsForDocument</var>'s <code data-x="nrr-reasons">reasons</code>.</p></li>
</ol>
</li>

<li><p>If <var>document</var>'s <span
data-x="concept-document-bfcache-blocking-reasons">bfcache blocking reasons</span> are empty, set
<var>notRestoredReasonsForDocument</var>'s <span
data-x="concept-not-restored-reasons-prevented-bfcache-state">prevented bfcache state</span>
to "<code data-x="dom-PreventedBackForwardCache-no">no</code>". If not, set
data-x="nrr-prevented-bfcache-state">prevented bfcache state</span> to "<code
data-x="dom-PreventedBackForwardCache-no">no</code>". If not, set
<var>notRestoredReasonsForDocument</var>'s <span
data-x="concept-not-restored-reasons-prevented-bfcache-state">prevented bfcache state</span>
data-x="nrr-prevented-bfcache-state">prevented bfcache state</span>
to "<code data-x="dom-PreventedBackForwardCache-yes">yes</code>".</p></li>

<li><p><span data-x="list iterate">For each</span> <var>navigable</var> of <var>document</var>'s
Expand All @@ -99890,15 +99898,13 @@ location.href = '#foo';</code></pre>
<li><p>Let <var>childDocument</var> be <var>navigable</var>'s <span
data-x="nav-document">active document</span>.</p></li>

<li><p><span>Build NotRestoredReasons object for document</span> given <var>childDocument</var>.
</p></li>
<li><p><span>Build not restored reasons for document</span> given <var>childDocument</var>.</p></li>

<li><p><span data-x="list append">Append</span> <var>childDocument</var>'s <span>node
navigable</span>'s <span data-x="nav-active-history-entry">active session history entry</span>'s
<span data-x="she-document-state">document state</span>'s <span
data-x="document-state-not-restored-reasons">notRestoredReasons</span> to
<var>notRestoredReasonsForDocument</var>'s <code
data-x="dom-not-restored-reasons-children">children</code>'s <span>backing list</span>.</p></li>
<var>notRestoredReasonsForDocument</var>'s <code data-x="nrr-children">children</code>.</p></li>
</ol>
</li>

Expand All @@ -99909,10 +99915,10 @@ location.href = '#foo';</code></pre>
<var>notRestoredReasonsForDocument</var>.</p></li>
</ol>

<p>To <dfn>build NotRestoredReasons object for a top-level traversal and its descendants</dfn>
<p>To <dfn>build not restored reasons for a top-level traversal and its descendants</dfn>
given <span>navigable</span> <var>navigable</var>:
<ol>
<li><p><span>Build NotRestoredReasons object for document</span> given <var>navigable</var>'s
<li><p><span>Build not restored reasons for document</span> given <var>navigable</var>'s
<span data-x="nav-document">active document</span>.</p></li>

<li><p>Let <var>crossOriginDescendants</var> be an empty <span>list</span>.</p></li>
Expand Down Expand Up @@ -101074,7 +101080,7 @@ new PaymentRequest(&hellip;); // Allowed to use
defined by this specification and <span>other applicable specifications</span>.</p></li>

<li><p>If <var>oldDocument</var>'s <span>node navigable</span> is a <span>top-level
traversable</span>, <span>build NotRestoredReasons object for a top-level traversal and its
traversable</span>, <span>build not restored reasons for a top-level traversal and its
descendants</span> given <var>oldDocument</var>'s <span>node navigable</span>.</p></li>

<li><p>If <var>oldDocument</var>'s <i data-x="concept-document-salvageable">salvageable</i> state
Expand Down

0 comments on commit 499b44b

Please sign in to comment.