Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/ray/kotlin-1.12.1-beta10' into g…
Browse files Browse the repository at this point in the history
…h-pages

* origin/ray/kotlin-1.12.1-beta10:
  Update documentation
  • Loading branch information
rjrjr committed Jul 1, 2024
2 parents 915b0fa + 15e785e commit 8fd09c2
Show file tree
Hide file tree
Showing 137 changed files with 4,165 additions and 731 deletions.
4 changes: 2 additions & 2 deletions faq/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -679,7 +679,7 @@

<li class="md-nav__item">
<a href="#isnt-this-basically-reactelm" class="md-nav__link">
Isn't this basically React/Elm?
Isn&rsquo;t this basically React/Elm?
</a>

</li>
Expand Down Expand Up @@ -808,7 +808,7 @@

<li class="md-nav__item">
<a href="#isnt-this-basically-reactelm" class="md-nav__link">
Isn't this basically React/Elm?
Isn&rsquo;t this basically React/Elm?
</a>

</li>
Expand Down
4 changes: 2 additions & 2 deletions glossary/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -797,7 +797,7 @@

<li class="md-nav__item">
<a href="#immutable-state" class="md-nav__link">
"Immutable" State
&ldquo;Immutable&rdquo; State
</a>

</li>
Expand Down Expand Up @@ -1137,7 +1137,7 @@

<li class="md-nav__item">
<a href="#immutable-state" class="md-nav__link">
"Immutable" State
&ldquo;Immutable&rdquo; State
</a>

</li>
Expand Down
95 changes: 55 additions & 40 deletions kotlin/api/htmlMultiModule/navigation.html

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion kotlin/api/htmlMultiModule/scripts/pages.json

Large diffs are not rendered by default.

95 changes: 55 additions & 40 deletions kotlin/api/htmlMultiModule/trace-encoder/navigation.html

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@
<div class="cover ">
<h1 class="cover"><span>action</span><wbr><span><span>Sink</span></span></h1>
</div>
<div class="platform-hinted " data-platform-hinted="data-platform-hinted"><div class="content sourceset-dependent-content" data-active="" data-togglable=":workflow-core:dokkaHtmlPartial/commonMain"><div class="symbol monospace"><span class="token keyword">abstract </span><span class="token keyword"></span><span class="token keyword">val </span><a href="action-sink.html">actionSink</a><span class="token operator">: </span><a href="../-sink/index.html">Sink</a><span class="token operator">&lt;</span><span class="token keyword"></span><a href="../-workflow-action/index.html">WorkflowAction</a><span class="token operator">&lt;</span><span class="token keyword"></span><a href="index.html">PropsT</a><span class="token punctuation">, </span><span class="token keyword"></span><a href="index.html">StateT</a><span class="token punctuation">, </span><span class="token keyword"></span><a href="index.html">OutputT</a><span class="token operator">&gt;</span><span class="token operator">&gt;</span><span class="clearfix"><span class="floating-right">(<a href="https://github.com/square/workflow-kotlin/blob/main/workflow-core/src/commonMain/kotlin/com/squareup/workflow1/BaseRenderContext.kt#L52">source</a>)</span></span></div><p class="paragraph">Accepts a single <a href="../-workflow-action/index.html">WorkflowAction</a>, invokes that action by calling <a href="../-workflow-action/apply.html">WorkflowAction.apply</a> to update the current state, and optionally emits the returned output value if it is non-null.</p></div></div>
<div class="platform-hinted " data-platform-hinted="data-platform-hinted"><div class="content sourceset-dependent-content" data-active="" data-togglable=":workflow-core:dokkaHtmlPartial/commonMain"><div class="symbol monospace"><span class="token keyword">abstract </span><span class="token keyword"></span><span class="token keyword">val </span><a href="action-sink.html">actionSink</a><span class="token operator">: </span><a href="../-sink/index.html">Sink</a><span class="token operator">&lt;</span><span class="token keyword"></span><a href="../-workflow-action/index.html">WorkflowAction</a><span class="token operator">&lt;</span><span class="token keyword"></span><a href="index.html">PropsT</a><span class="token punctuation">, </span><span class="token keyword"></span><a href="index.html">StateT</a><span class="token punctuation">, </span><span class="token keyword"></span><a href="index.html">OutputT</a><span class="token operator">&gt;</span><span class="token operator">&gt;</span><span class="clearfix"><span class="floating-right">(<a href="https://github.com/square/workflow-kotlin/blob/main/workflow-core/src/commonMain/kotlin/com/squareup/workflow1/BaseRenderContext.kt#L56">source</a>)</span></span></div><p class="paragraph">Accepts a single <a href="../-workflow-action/index.html">WorkflowAction</a>, invokes that action by calling <a href="../-workflow-action/apply.html">WorkflowAction.apply</a> to update the current state, and optionally emits the returned output value if it is non-null.</p></div></div>
</div>
<div class="footer">
<span class="go-to-top-icon"><a href="#content" id="go-to-top-link"></a></span><span>© 2024 Copyright</span><span class="pull-right"><span>Generated by </span><a href="https://github.com/Kotlin/dokka"><span>dokka</span><span class="padded-icon"></span></a></span>
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
<div class="breadcrumbs"><a href="../../index.html">workflow-core</a><span class="delimiter">/</span><a href="../index.html">com.squareup.workflow1</a><span class="delimiter">/</span><span class="current">BaseRenderContext</span></div>
<div class="cover ">
<h1 class="cover"><span>Base</span><wbr><span>Render</span><wbr><span><span>Context</span></span></h1>
<div class="platform-hinted " data-platform-hinted="data-platform-hinted"><div class="content sourceset-dependent-content" data-active="" data-togglable=":workflow-core:dokkaHtmlPartial/commonMain"><div class="symbol monospace"><span class="token keyword">interface </span><a href="index.html">BaseRenderContext</a><span class="token operator">&lt;</span><span class="token keyword">out </span><a href="index.html">PropsT</a><span class="token punctuation">, </span><span class="token keyword"></span><a href="index.html">StateT</a><span class="token punctuation">, </span><span class="token keyword">in </span><a href="index.html">OutputT</a><span class="token operator">&gt;</span><span class="clearfix"><span class="floating-right">(<a href="https://github.com/square/workflow-kotlin/blob/main/workflow-core/src/commonMain/kotlin/com/squareup/workflow1/BaseRenderContext.kt#L46">source</a>)</span></span></div><p class="paragraph">Facilities for a <a href="../-workflow/index.html">Workflow</a> to interact with other <a href="../-workflow/index.html">Workflow</a>s and the outside world from inside a <code class="lang-kotlin">render</code> function.</p><h2 class=""> Handling events from the UI</h2><p class="paragraph">While a workflow's rendering can represent whatever you need it to, it is common for the rendering to contain the data for some part of your UI. In addition to shuttling data to the UI, the rendering can also contain functions that the UI can call to send events to the workflow.</p><p class="paragraph">E.g.</p><div class="sample-container"><pre><code class="block lang-kotlin" theme="idea">data class Rendering(<br> val radioButtonTexts: List&lt;String&gt;,<br> val onSelected: (index: Int) -&gt; Unit<br>)</code></pre><span class="top-right-position"><span class="copy-icon"></span><div class="copy-popup-wrapper popup-to-left"><span class="copy-popup-icon"></span><span>Content copied to clipboard</span></div></span></div><p class="paragraph">To create populate such functions from your <code class="lang-kotlin">render</code> method, you first need to define a <a href="../-workflow-action/index.html">WorkflowAction</a> to handle the event by changing state, emitting an output, or both. Then, just pass a lambda to your rendering that instantiates the action and passes it to <a href="../-sink/send.html">actionSink.send</a>.</p><h2 class=""> Performing asynchronous work</h2><p class="paragraph">See <a href="../running-worker.html">runningWorker</a>.</p><h2 class=""> Composing children</h2><p class="paragraph">See <a href="render-child.html">renderChild</a>.</p><h4 class="">Inheritors</h4><div class="table"><div class="table-row" data-filterable-current=":workflow-core:dokkaHtmlPartial/commonMain" data-filterable-set=":workflow-core:dokkaHtmlPartial/commonMain"><div class="main-subrow keyValue "><div class=""><span class="inline-flex"><div><a href="../-stateful-workflow/-render-context/index.html">RenderContext</a></div></span></div><div></div></div></div><div class="table-row" data-filterable-current=":workflow-core:dokkaHtmlPartial/commonMain" data-filterable-set=":workflow-core:dokkaHtmlPartial/commonMain"><div class="main-subrow keyValue "><div class=""><span class="inline-flex"><div><a href="../-stateless-workflow/-render-context/index.html">RenderContext</a></div></span></div><div></div></div></div></div></div></div>
<div class="platform-hinted " data-platform-hinted="data-platform-hinted"><div class="content sourceset-dependent-content" data-active="" data-togglable=":workflow-core:dokkaHtmlPartial/commonMain"><div class="symbol monospace"><span class="token keyword">interface </span><a href="index.html">BaseRenderContext</a><span class="token operator">&lt;</span><span class="token keyword">out </span><a href="index.html">PropsT</a><span class="token punctuation">, </span><span class="token keyword"></span><a href="index.html">StateT</a><span class="token punctuation">, </span><span class="token keyword">in </span><a href="index.html">OutputT</a><span class="token operator">&gt;</span><span class="clearfix"><span class="floating-right">(<a href="https://github.com/square/workflow-kotlin/blob/main/workflow-core/src/commonMain/kotlin/com/squareup/workflow1/BaseRenderContext.kt#L50">source</a>)</span></span></div><p class="paragraph">Facilities for a <a href="../-workflow/index.html">Workflow</a> to interact with other <a href="../-workflow/index.html">Workflow</a>s and the outside world from inside a <code class="lang-kotlin">render</code> function.</p><h2 class=""> Handling events from the UI</h2><p class="paragraph">While a workflow's rendering can represent whatever you need it to, it is common for the rendering to contain the data for some part of your UI. In addition to shuttling data to the UI, the rendering can also contain functions that the UI can call to send events to the workflow.</p><p class="paragraph">E.g.</p><div class="sample-container"><pre><code class="block lang-kotlin" theme="idea">data class Rendering(<br> val radioButtonTexts: List&lt;String&gt;,<br> val onSelected: (index: Int) -&gt; Unit<br>)</code></pre><span class="top-right-position"><span class="copy-icon"></span><div class="copy-popup-wrapper popup-to-left"><span class="copy-popup-icon"></span><span>Content copied to clipboard</span></div></span></div><p class="paragraph">To create populate such functions from your <code class="lang-kotlin">render</code> method, you first need to define a <a href="../-workflow-action/index.html">WorkflowAction</a> to handle the event by changing state, emitting an output, or both. Then, just pass a lambda to your rendering that instantiates the action and passes it to <a href="../-sink/send.html">actionSink.send</a>.</p><h2 class=""> Performing asynchronous work</h2><p class="paragraph">See <a href="../running-worker.html">runningWorker</a>.</p><h2 class=""> Composing children</h2><p class="paragraph">See <a href="render-child.html">renderChild</a>.</p><h4 class="">Inheritors</h4><div class="table"><div class="table-row" data-filterable-current=":workflow-core:dokkaHtmlPartial/commonMain" data-filterable-set=":workflow-core:dokkaHtmlPartial/commonMain"><div class="main-subrow keyValue "><div class=""><span class="inline-flex"><div><a href="../-stateful-workflow/-render-context/index.html">RenderContext</a></div></span></div><div></div></div></div><div class="table-row" data-filterable-current=":workflow-core:dokkaHtmlPartial/commonMain" data-filterable-set=":workflow-core:dokkaHtmlPartial/commonMain"><div class="main-subrow keyValue "><div class=""><span class="inline-flex"><div><a href="../-stateless-workflow/-render-context/index.html">RenderContext</a></div></span></div><div></div></div></div></div></div></div>
</div>
<div class="tabbedcontent">
<div class="tabs-section" tabs-section="tabs-section"><button class="section-tab" data-active="" data-togglable="CONSTRUCTOR,TYPE,PROPERTY,FUNCTION">Members</button><button class="section-tab" data-togglable="CONSTRUCTOR,TYPE,PROPERTY,FUNCTION,EXTENSION_PROPERTY,EXTENSION_FUNCTION">Members &amp; Extensions</button></div>
Expand Down
Loading

0 comments on commit 8fd09c2

Please sign in to comment.