1
0
forked from bot/app
LiteyukiBot/assets/observer.html-Ba-N6Xuq.js

89 lines
28 KiB
JavaScript
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import{_ as n,o as e,c as a,e as s}from"./app-SlpTmndF.js";const t={},o=s(`<h3 id="def-debounce-wait-any-none" tabindex="-1"><a class="header-anchor" href="#def-debounce-wait-any-none"><span><em><strong>def</strong></em> <code>debounce(wait: Any) -&gt; None</code></span></a></h3><p>防抖函数</p><details><summary>源代码</summary><div class="language-python line-numbers-mode" data-ext="py" data-title="py"><pre class="language-python"><code><span class="token keyword">def</span> <span class="token function">debounce</span><span class="token punctuation">(</span>wait<span class="token punctuation">)</span><span class="token punctuation">:</span>
<span class="token triple-quoted-string string">&quot;&quot;&quot;
防抖函数
&quot;&quot;&quot;</span>
<span class="token keyword">def</span> <span class="token function">decorator</span><span class="token punctuation">(</span>func<span class="token punctuation">)</span><span class="token punctuation">:</span>
<span class="token keyword">def</span> <span class="token function">wrapper</span><span class="token punctuation">(</span><span class="token operator">*</span>args<span class="token punctuation">,</span> <span class="token operator">**</span>kwargs<span class="token punctuation">)</span><span class="token punctuation">:</span>
<span class="token keyword">nonlocal</span> last_call_time
current_time <span class="token operator">=</span> time<span class="token punctuation">.</span>time<span class="token punctuation">(</span><span class="token punctuation">)</span>
<span class="token keyword">if</span> current_time <span class="token operator">-</span> last_call_time <span class="token operator">&gt;</span> wait<span class="token punctuation">:</span>
last_call_time <span class="token operator">=</span> current_time
<span class="token keyword">return</span> func<span class="token punctuation">(</span><span class="token operator">*</span>args<span class="token punctuation">,</span> <span class="token operator">**</span>kwargs<span class="token punctuation">)</span>
last_call_time <span class="token operator">=</span> <span class="token boolean">None</span>
<span class="token keyword">return</span> wrapper
<span class="token keyword">return</span> decorator
</code></pre><div class="line-numbers" aria-hidden="true"><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div></div></div></details><h3 id="def-on-file-system-event-directories-tuple-str-recursive-bool-event-filter-filter-func-callable-callback-func-callback-func" tabindex="-1"><a class="header-anchor" href="#def-on-file-system-event-directories-tuple-str-recursive-bool-event-filter-filter-func-callable-callback-func-callback-func"><span><em><strong>def</strong></em> <code>on_file_system_event(directories: tuple[str], recursive: bool, event_filter: FILTER_FUNC) -&gt; Callable[[CALLBACK_FUNC], CALLBACK_FUNC]</code></span></a></h3><p>注册文件系统变化监听器</p><p>Args:</p><pre><code>directories: 监听目录们
recursive: 是否递归监听子目录
event_filter: 事件过滤器, 返回True则执行回调函数
</code></pre><p>Returns:</p><pre><code>装饰器,装饰一个函数在接收到数据后执行
</code></pre><details><summary>源代码</summary><div class="language-python line-numbers-mode" data-ext="py" data-title="py"><pre class="language-python"><code><span class="token keyword">def</span> <span class="token function">on_file_system_event</span><span class="token punctuation">(</span>directories<span class="token punctuation">:</span> <span class="token builtin">tuple</span><span class="token punctuation">[</span><span class="token builtin">str</span><span class="token punctuation">]</span><span class="token punctuation">,</span> recursive<span class="token punctuation">:</span> <span class="token builtin">bool</span><span class="token operator">=</span><span class="token boolean">True</span><span class="token punctuation">,</span> event_filter<span class="token punctuation">:</span> FILTER_FUNC<span class="token operator">=</span><span class="token boolean">None</span><span class="token punctuation">)</span> <span class="token operator">-</span><span class="token operator">&gt;</span> Callable<span class="token punctuation">[</span><span class="token punctuation">[</span>CALLBACK_FUNC<span class="token punctuation">]</span><span class="token punctuation">,</span> CALLBACK_FUNC<span class="token punctuation">]</span><span class="token punctuation">:</span>
<span class="token triple-quoted-string string">&quot;&quot;&quot;
注册文件系统变化监听器
Args:
directories: 监听目录们
recursive: 是否递归监听子目录
event_filter: 事件过滤器, 返回True则执行回调函数
Returns:
装饰器,装饰一个函数在接收到数据后执行
&quot;&quot;&quot;</span>
<span class="token keyword">def</span> <span class="token function">decorator</span><span class="token punctuation">(</span>func<span class="token punctuation">:</span> CALLBACK_FUNC<span class="token punctuation">)</span> <span class="token operator">-</span><span class="token operator">&gt;</span> CALLBACK_FUNC<span class="token punctuation">:</span>
<span class="token keyword">def</span> <span class="token function">wrapper</span><span class="token punctuation">(</span>event<span class="token punctuation">:</span> FileSystemEvent<span class="token punctuation">)</span><span class="token punctuation">:</span>
<span class="token keyword">if</span> event_filter <span class="token keyword">is</span> <span class="token keyword">not</span> <span class="token boolean">None</span> <span class="token keyword">and</span> <span class="token punctuation">(</span><span class="token keyword">not</span> event_filter<span class="token punctuation">(</span>event<span class="token punctuation">)</span><span class="token punctuation">)</span><span class="token punctuation">:</span>
<span class="token keyword">return</span>
func<span class="token punctuation">(</span>event<span class="token punctuation">)</span>
code_modified_handler <span class="token operator">=</span> CodeModifiedHandler<span class="token punctuation">(</span><span class="token punctuation">)</span>
code_modified_handler<span class="token punctuation">.</span>on_modified <span class="token operator">=</span> wrapper
<span class="token keyword">for</span> directory <span class="token keyword">in</span> directories<span class="token punctuation">:</span>
observer<span class="token punctuation">.</span>schedule<span class="token punctuation">(</span>code_modified_handler<span class="token punctuation">,</span> directory<span class="token punctuation">,</span> recursive<span class="token operator">=</span>recursive<span class="token punctuation">)</span>
<span class="token keyword">return</span> func
<span class="token keyword">return</span> decorator
</code></pre><div class="line-numbers" aria-hidden="true"><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div></div></div></details><h3 id="def-decorator-func-any-none" tabindex="-1"><a class="header-anchor" href="#def-decorator-func-any-none"><span><em><strong>def</strong></em> <code>decorator(func: Any) -&gt; None</code></span></a></h3><details><summary>源代码</summary><div class="language-python line-numbers-mode" data-ext="py" data-title="py"><pre class="language-python"><code><span class="token keyword">def</span> <span class="token function">decorator</span><span class="token punctuation">(</span>func<span class="token punctuation">)</span><span class="token punctuation">:</span>
<span class="token keyword">def</span> <span class="token function">wrapper</span><span class="token punctuation">(</span><span class="token operator">*</span>args<span class="token punctuation">,</span> <span class="token operator">**</span>kwargs<span class="token punctuation">)</span><span class="token punctuation">:</span>
<span class="token keyword">nonlocal</span> last_call_time
current_time <span class="token operator">=</span> time<span class="token punctuation">.</span>time<span class="token punctuation">(</span><span class="token punctuation">)</span>
<span class="token keyword">if</span> current_time <span class="token operator">-</span> last_call_time <span class="token operator">&gt;</span> wait<span class="token punctuation">:</span>
last_call_time <span class="token operator">=</span> current_time
<span class="token keyword">return</span> func<span class="token punctuation">(</span><span class="token operator">*</span>args<span class="token punctuation">,</span> <span class="token operator">**</span>kwargs<span class="token punctuation">)</span>
last_call_time <span class="token operator">=</span> <span class="token boolean">None</span>
<span class="token keyword">return</span> wrapper
</code></pre><div class="line-numbers" aria-hidden="true"><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div></div></div></details><h3 id="def-decorator-func-callback-func-callback-func" tabindex="-1"><a class="header-anchor" href="#def-decorator-func-callback-func-callback-func"><span><em><strong>def</strong></em> <code>decorator(func: CALLBACK_FUNC) -&gt; CALLBACK_FUNC</code></span></a></h3><details><summary>源代码</summary><div class="language-python line-numbers-mode" data-ext="py" data-title="py"><pre class="language-python"><code><span class="token keyword">def</span> <span class="token function">decorator</span><span class="token punctuation">(</span>func<span class="token punctuation">:</span> CALLBACK_FUNC<span class="token punctuation">)</span> <span class="token operator">-</span><span class="token operator">&gt;</span> CALLBACK_FUNC<span class="token punctuation">:</span>
<span class="token keyword">def</span> <span class="token function">wrapper</span><span class="token punctuation">(</span>event<span class="token punctuation">:</span> FileSystemEvent<span class="token punctuation">)</span><span class="token punctuation">:</span>
<span class="token keyword">if</span> event_filter <span class="token keyword">is</span> <span class="token keyword">not</span> <span class="token boolean">None</span> <span class="token keyword">and</span> <span class="token punctuation">(</span><span class="token keyword">not</span> event_filter<span class="token punctuation">(</span>event<span class="token punctuation">)</span><span class="token punctuation">)</span><span class="token punctuation">:</span>
<span class="token keyword">return</span>
func<span class="token punctuation">(</span>event<span class="token punctuation">)</span>
code_modified_handler <span class="token operator">=</span> CodeModifiedHandler<span class="token punctuation">(</span><span class="token punctuation">)</span>
code_modified_handler<span class="token punctuation">.</span>on_modified <span class="token operator">=</span> wrapper
<span class="token keyword">for</span> directory <span class="token keyword">in</span> directories<span class="token punctuation">:</span>
observer<span class="token punctuation">.</span>schedule<span class="token punctuation">(</span>code_modified_handler<span class="token punctuation">,</span> directory<span class="token punctuation">,</span> recursive<span class="token operator">=</span>recursive<span class="token punctuation">)</span>
<span class="token keyword">return</span> func
</code></pre><div class="line-numbers" aria-hidden="true"><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div></div></div></details><h3 id="def-wrapper-none" tabindex="-1"><a class="header-anchor" href="#def-wrapper-none"><span><em><strong>def</strong></em> <code>wrapper() -&gt; None</code></span></a></h3><details><summary>源代码</summary><div class="language-python line-numbers-mode" data-ext="py" data-title="py"><pre class="language-python"><code><span class="token keyword">def</span> <span class="token function">wrapper</span><span class="token punctuation">(</span><span class="token operator">*</span>args<span class="token punctuation">,</span> <span class="token operator">**</span>kwargs<span class="token punctuation">)</span><span class="token punctuation">:</span>
<span class="token keyword">nonlocal</span> last_call_time
current_time <span class="token operator">=</span> time<span class="token punctuation">.</span>time<span class="token punctuation">(</span><span class="token punctuation">)</span>
<span class="token keyword">if</span> current_time <span class="token operator">-</span> last_call_time <span class="token operator">&gt;</span> wait<span class="token punctuation">:</span>
last_call_time <span class="token operator">=</span> current_time
<span class="token keyword">return</span> func<span class="token punctuation">(</span><span class="token operator">*</span>args<span class="token punctuation">,</span> <span class="token operator">**</span>kwargs<span class="token punctuation">)</span>
</code></pre><div class="line-numbers" aria-hidden="true"><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div></div></div></details><h3 id="def-wrapper-event-filesystemevent-none" tabindex="-1"><a class="header-anchor" href="#def-wrapper-event-filesystemevent-none"><span><em><strong>def</strong></em> <code>wrapper(event: FileSystemEvent) -&gt; None</code></span></a></h3><details><summary>源代码</summary><div class="language-python line-numbers-mode" data-ext="py" data-title="py"><pre class="language-python"><code><span class="token keyword">def</span> <span class="token function">wrapper</span><span class="token punctuation">(</span>event<span class="token punctuation">:</span> FileSystemEvent<span class="token punctuation">)</span><span class="token punctuation">:</span>
<span class="token keyword">if</span> event_filter <span class="token keyword">is</span> <span class="token keyword">not</span> <span class="token boolean">None</span> <span class="token keyword">and</span> <span class="token punctuation">(</span><span class="token keyword">not</span> event_filter<span class="token punctuation">(</span>event<span class="token punctuation">)</span><span class="token punctuation">)</span><span class="token punctuation">:</span>
<span class="token keyword">return</span>
func<span class="token punctuation">(</span>event<span class="token punctuation">)</span>
</code></pre><div class="line-numbers" aria-hidden="true"><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div></div></div></details><h3 id="class-codemodifiedhandler-filesystemeventhandler" tabindex="-1"><a class="header-anchor" href="#class-codemodifiedhandler-filesystemeventhandler"><span><em><strong>class</strong></em> <code>CodeModifiedHandler(FileSystemEventHandler)</code></span></a></h3><p>Handler for code file changes</p><h3 id="def-on-modified-self-event-any-none" tabindex="-1"><a class="header-anchor" href="#def-on-modified-self-event-any-none"><span> <em><strong>def</strong></em> <code>on_modified(self, event: Any) -&gt; None</code></span></a></h3><p></p><details><summary>源代码</summary><div class="language-python line-numbers-mode" data-ext="py" data-title="py"><pre class="language-python"><code><span class="token decorator annotation punctuation">@debounce</span><span class="token punctuation">(</span><span class="token number">1</span><span class="token punctuation">)</span>
<span class="token keyword">def</span> <span class="token function">on_modified</span><span class="token punctuation">(</span>self<span class="token punctuation">,</span> event<span class="token punctuation">)</span><span class="token punctuation">:</span>
<span class="token keyword">raise</span> NotImplementedError<span class="token punctuation">(</span><span class="token string">&#39;on_modified must be implemented&#39;</span><span class="token punctuation">)</span>
</code></pre><div class="line-numbers" aria-hidden="true"><div class="line-number"></div><div class="line-number"></div><div class="line-number"></div></div></div></details><h3 id="def-on-created-self-event-any-none" tabindex="-1"><a class="header-anchor" href="#def-on-created-self-event-any-none"><span> <em><strong>def</strong></em> <code>on_created(self, event: Any) -&gt; None</code></span></a></h3><p></p><details><summary>源代码</summary><div class="language-python line-numbers-mode" data-ext="py" data-title="py"><pre class="language-python"><code><span class="token keyword">def</span> <span class="token function">on_created</span><span class="token punctuation">(</span>self<span class="token punctuation">,</span> event<span class="token punctuation">)</span><span class="token punctuation">:</span>
self<span class="token punctuation">.</span>on_modified<span class="token punctuation">(</span>event<span class="token punctuation">)</span>
</code></pre><div class="line-numbers" aria-hidden="true"><div class="line-number"></div><div class="line-number"></div></div></div></details><h3 id="def-on-deleted-self-event-any-none" tabindex="-1"><a class="header-anchor" href="#def-on-deleted-self-event-any-none"><span> <em><strong>def</strong></em> <code>on_deleted(self, event: Any) -&gt; None</code></span></a></h3><p></p><details><summary>源代码</summary><div class="language-python line-numbers-mode" data-ext="py" data-title="py"><pre class="language-python"><code><span class="token keyword">def</span> <span class="token function">on_deleted</span><span class="token punctuation">(</span>self<span class="token punctuation">,</span> event<span class="token punctuation">)</span><span class="token punctuation">:</span>
self<span class="token punctuation">.</span>on_modified<span class="token punctuation">(</span>event<span class="token punctuation">)</span>
</code></pre><div class="line-numbers" aria-hidden="true"><div class="line-number"></div><div class="line-number"></div></div></div></details><h3 id="def-on-moved-self-event-any-none" tabindex="-1"><a class="header-anchor" href="#def-on-moved-self-event-any-none"><span> <em><strong>def</strong></em> <code>on_moved(self, event: Any) -&gt; None</code></span></a></h3><p></p><details><summary>源代码</summary><div class="language-python line-numbers-mode" data-ext="py" data-title="py"><pre class="language-python"><code><span class="token keyword">def</span> <span class="token function">on_moved</span><span class="token punctuation">(</span>self<span class="token punctuation">,</span> event<span class="token punctuation">)</span><span class="token punctuation">:</span>
self<span class="token punctuation">.</span>on_modified<span class="token punctuation">(</span>event<span class="token punctuation">)</span>
</code></pre><div class="line-numbers" aria-hidden="true"><div class="line-number"></div><div class="line-number"></div></div></div></details><h3 id="def-on-any-event-self-event-any-none" tabindex="-1"><a class="header-anchor" href="#def-on-any-event-self-event-any-none"><span> <em><strong>def</strong></em> <code>on_any_event(self, event: Any) -&gt; None</code></span></a></h3><p></p><details><summary>源代码</summary><div class="language-python line-numbers-mode" data-ext="py" data-title="py"><pre class="language-python"><code><span class="token keyword">def</span> <span class="token function">on_any_event</span><span class="token punctuation">(</span>self<span class="token punctuation">,</span> event<span class="token punctuation">)</span><span class="token punctuation">:</span>
self<span class="token punctuation">.</span>on_modified<span class="token punctuation">(</span>event<span class="token punctuation">)</span>
</code></pre><div class="line-numbers" aria-hidden="true"><div class="line-number"></div><div class="line-number"></div></div></div></details><h3 id="var-liteyuki-bot-get-bot" tabindex="-1"><a class="header-anchor" href="#var-liteyuki-bot-get-bot"><span><em><strong>var</strong></em> <code>liteyuki_bot = get_bot()</code></span></a></h3><h3 id="var-observer-observer" tabindex="-1"><a class="header-anchor" href="#var-observer-observer"><span><em><strong>var</strong></em> <code>observer = Observer()</code></span></a></h3><h3 id="var-last-call-time-none" tabindex="-1"><a class="header-anchor" href="#var-last-call-time-none"><span><em><strong>var</strong></em> <code>last_call_time = None</code></span></a></h3><h3 id="var-code-modified-handler-codemodifiedhandler" tabindex="-1"><a class="header-anchor" href="#var-code-modified-handler-codemodifiedhandler"><span><em><strong>var</strong></em> <code>code_modified_handler = CodeModifiedHandler()</code></span></a></h3><h3 id="var-current-time-time-time" tabindex="-1"><a class="header-anchor" href="#var-current-time-time-time"><span><em><strong>var</strong></em> <code>current_time = time.time()</code></span></a></h3><h3 id="var-last-call-time-current-time" tabindex="-1"><a class="header-anchor" href="#var-last-call-time-current-time"><span><em><strong>var</strong></em> <code>last_call_time = current_time</code></span></a></h3>`,41),l=[o];function p(i,c){return e(),a("div",null,l)}const d=n(t,[["render",p],["__file","observer.html.vue"]]),u=JSON.parse('{"path":"/en/dev/api/dev/observer.html","title":"liteyuki.dev.observer","lang":"en-US","frontmatter":{"title":"liteyuki.dev.observer","order":1,"icon":"laptop-code","category":"API","description":"def debounce(wait: Any) -> None 防抖函数 源代码 def on_file_system_event(directories: tuple[str], recursive: bool, event_filter: FILTER_FUNC) -> Callable[[CALLBACK_FUNC], CALLBACK_FUNC...","head":[["link",{"rel":"alternate","hreflang":"zh-cn","href":"https://vuepress-theme-hope-docs-demo.netlify.app/dev/api/dev/observer.html"}],["meta",{"property":"og:url","content":"https://vuepress-theme-hope-docs-demo.netlify.app/en/dev/api/dev/observer.html"}],["meta",{"property":"og:site_name","content":"LiteyukiBot"}],["meta",{"property":"og:title","content":"liteyuki.dev.observer"}],["meta",{"property":"og:description","content":"def debounce(wait: Any) -> None 防抖函数 源代码 def on_file_system_event(directories: tuple[str], recursive: bool, event_filter: FILTER_FUNC) -> Callable[[CALLBACK_FUNC], CALLBACK_FUNC..."}],["meta",{"property":"og:type","content":"article"}],["meta",{"property":"og:locale","content":"en-US"}],["meta",{"property":"og:locale:alternate","content":"zh-CN"}],["meta",{"property":"og:updated_time","content":"2024-08-21T09:59:21.000Z"}],["meta",{"property":"article:modified_time","content":"2024-08-21T09:59:21.000Z"}],["script",{"type":"application/ld+json"},"{\\"@context\\":\\"https://schema.org\\",\\"@type\\":\\"Article\\",\\"headline\\":\\"liteyuki.dev.observer\\",\\"image\\":[\\"\\"],\\"dateModified\\":\\"2024-08-21T09:59:21.000Z\\",\\"author\\":[]}"]]},"headers":[{"level":3,"title":"def debounce(wait: Any) -> None","slug":"def-debounce-wait-any-none","link":"#def-debounce-wait-any-none","children":[]},{"level":3,"title":"def on_file_system_event(directories: tuple[str], recursive: bool, event_filter: FILTER_FUNC) -> Callable[[CALLBACK_FUNC], CALLBACK_FUNC]","slug":"def-on-file-system-event-directories-tuple-str-recursive-bool-event-filter-filter-func-callable-callback-func-callback-func","link":"#def-on-file-system-event-directories-tuple-str-recursive-bool-event-filter-filter-func-callable-callback-func-callback-func","children":[]},{"level":3,"title":"def decorator(func: Any) -> None","slug":"def-decorator-func-any-none","link":"#def-decorator-func-any-none","children":[]},{"level":3,"title":"def decorator(func: CALLBACK_FUNC) -> CALLBACK_FUNC","slug":"def-decorator-func-callback-func-callback-func","link":"#def-decorator-func-callback-func-callback-func","children":[]},{"level":3,"title":"def wrapper() -> None","slug":"def-wrapper-none","link":"#def-wrapper-none","children":[]},{"level":3,"title":"def wrapper(event: FileSystemEvent) -> None","slug":"def-wrapper-event-filesystemevent-none","link":"#def-wrapper-event-filesystemevent-none","children":[]},{"level":3,"title":"class CodeModifiedHandler(FileSystemEventHandler)","slug":"class-codemodifiedhandler-filesystemeventhandler","link":"#class-codemodifiedhandler-filesystemeventhandler","children":[]},{"level":3,"title":"def on_modified(self, event: Any) -> None","slug":"def-on-modified-self-event-any-none","link":"#def-on-modified-self-event-any-none","children":[]},{"level":3,"title":"def on_created(self, event: Any) -> None","slug":"def-on-created-self-event-any-none","link":"#def-on-created-self-event-any-none","children":[]},{"level":3,"title":"def on_deleted(self, event: Any) -> None","slug":"def-on-deleted-self-event-any-none","link":"#def-on-deleted-self-event-any-none","children":[]},{"level":3,"title":"def on_moved(self, event: Any) -> None","slug":"def-on-moved-self-event-any-none","link":"#def-on-moved-self-event-any-none","children":[]},{"level":3,"title":"def on_any_event(self, event: Any) -> None","slug":"def-on-any-event-self-event-any-none","link":"#def-on-any-event-self-event-any-none","children":[]},{"level":3,"title":"var liteyuki_bot = get_bot()","slug":"var-liteyuki-bot-get-bot","link":"#var-liteyuki-bot-get-bot","children":[]},{"level":3,"title":"var observer = Observer()","slug":"var-observer-observer","link":"#var-observer-observer","children":[]},{"level":3,"title":"var last_call_time = None","slug":"var-last-call-time-none","link":"#var-last-call-time-none","children":[]},{"level":3,"title":"var code_modified_handler = CodeModifiedHandler()","slug":"var-code-modified-handler-codemodifiedhandler","link":"#var-code-modified-handler-codemodifiedhandler","children":[]},{"level":3,"title":"var current_time = time.time()","slug":"var-current-time-time-time","link":"#var-current-time-time-time","children":[]},{"level":3,"title":"var last_call_time = current_time","slug":"var-last-call-time-current-time","link":"#var-last-call-time-current-time","children":[]}],"git":{"createdTime":1724234361000,"updatedTime":1724234361000,"contributors":[{"name":"snowy","email":"snowykami@outlook.com","commits":1}]},"readingTime":{"minutes":1.82,"words":545},"filePathRelative":"en/dev/api/dev/observer.md","localizedDate":"August 21, 2024","autoDesc":true}');export{d as comp,u as data};