This commit is contained in:
InsanusMokrassar 2023-06-14 07:59:14 +00:00
parent 33c1dcb693
commit 692284153b
2 changed files with 3 additions and 3 deletions

Binary file not shown.

View File

@ -1423,9 +1423,9 @@
<h2 id="main-parts-of-behaviour-builder">Main parts of Behaviour Builder<a class="headerlink" href="#main-parts-of-behaviour-builder" title="Permanent link">&para;</a></h2> <h2 id="main-parts-of-behaviour-builder">Main parts of Behaviour Builder<a class="headerlink" href="#main-parts-of-behaviour-builder" title="Permanent link">&para;</a></h2>
<p>There are several things you should know for better understanding of behaviour builder:</p> <p>There are several things you should know for better understanding of behaviour builder:</p>
<ul> <ul>
<li><a href="https://github.com/InsanusMokrassar/TelegramBotAPI/blob/master/tgbotapi.behaviour_builder/src/commonMain/kotlin/dev/inmo/tgbotapi/extensions/behaviour_builder/BehaviourContext.kt#L33">BehaviourContext</a> - it is the thing which contains all necessary tools for working with bots</li> <li><a href="https://github.com/InsanusMokrassar/TelegramBotAPI/blob/master/tgbotapi.behaviour_builder/src/commonMain/kotlin/dev/inmo/tgbotapi/extensions/behaviour_builder/BehaviourContext.kt#L34">BehaviourContext</a> - it is the thing which contains all necessary tools for working with bots</li>
<li><a href="https://tgbotapi.inmo.dev/docs/dev.inmo.tgbotapi.extensions.behaviour_builder.triggers_handling/index.html">Triggers</a> - <code>on*</code> extensions for <code>BehaviourContext</code> which allow you to create reaction on some update</li> <li><a href="https://tgbotapi.inmo.dev/tgbotapi.behaviour_builder/dev.inmo.tgbotapi.extensions.behaviour_builder.triggers_handling/index.html">Triggers</a> - <code>on*</code> extensions for <code>BehaviourContext</code> which allow you to create reaction on some update</li>
<li><a href="https://tgbotapi.inmo.dev/docs/dev.inmo.tgbotapi.extensions.behaviour_builder.expectations/index.html">Expectations</a> (or waiters) - <code>wait*</code> extensions which you <strong>may</strong> use in <a href="https://tgbotapi.inmo.dev/docs/dev.inmo.tgbotapi.extensions.behaviour_builder/build-behaviour.html">buildBehaviour</a> function, but <strong><em>it is recommended</em></strong> to use it in bodies of triggers</li> <li><a href="https://tgbotapi.inmo.dev/tgbotapi.behaviour_builder/dev.inmo.tgbotapi.extensions.behaviour_builder.expectations/index.html">Expectations</a> (or waiters) - <code>wait*</code> extensions which you <strong>may</strong> use in <a href="https://tgbotapi.inmo.dev/docs/dev.inmo.tgbotapi.extensions.behaviour_builder/build-behaviour.html">buildBehaviour</a> function, but <strong><em>it is recommended</em></strong> to use it in bodies of triggers</li>
</ul> </ul>
<h2 id="initialization">Initialization<a class="headerlink" href="#initialization" title="Permanent link">&para;</a></h2> <h2 id="initialization">Initialization<a class="headerlink" href="#initialization" title="Permanent link">&para;</a></h2>
<p>As was said above, there is <a href="https://tgbotapi.inmo.dev/docs/dev.inmo.tgbotapi.extensions.behaviour_builder/build-behaviour.html">buildBehaviour</a> function which allow you set up your bot logic. Let&rsquo;s see an example:</p> <p>As was said above, there is <a href="https://tgbotapi.inmo.dev/docs/dev.inmo.tgbotapi.extensions.behaviour_builder/build-behaviour.html">buildBehaviour</a> function which allow you set up your bot logic. Let&rsquo;s see an example:</p>