mirror of
https://github.com/c-cube/linol.git
synced 2025-12-06 11:15:46 -05:00
2 lines
3.7 KiB
HTML
2 lines
3.7 KiB
HTML
<!DOCTYPE html>
|
||
<html xmlns="http://www.w3.org/1999/xhtml"><head><title>Enter_iter_hooks (lwt.Lwt_main.Enter_iter_hooks)</title><meta charset="utf-8"/><link rel="stylesheet" href="../../../_odoc-theme/odoc.css"/><meta name="generator" content="odoc 3.1.0"/><meta name="viewport" content="width=device-width,initial-scale=1.0"/><script src="../../../highlight.pack.js"></script><script>hljs.initHighlightingOnLoad();</script></head><body class="odoc"><nav class="odoc-nav"><a href="../index.html">Up</a> – <a href="../../../index.html">Index</a> » <a href="../../index.html">lwt</a> » <a href="../index.html">Lwt_main</a> » Enter_iter_hooks</nav><header class="odoc-preamble"><h1>Module <code><span>Lwt_main.Enter_iter_hooks</span></code></h1><p>Hooks, of type <code>unit -> unit</code>, that are called before each iteration of the Lwt main loop.</p><ul class="at-tags"><li class="since"><span class="at-tag">since</span> 4.2.0</li></ul></header><div class="odoc-content"><div class="odoc-spec"><div class="spec type anchored" id="type-kind"><a href="#type-kind" class="anchor"></a><code><span><span class="keyword">type</span> <span>'return_value kind</span></span><span> = <span class="type-var">'return_value</span></span></code></div><div class="spec-doc"><p>Hooks are functions of either type <code>unit -> unit</code> or <code>unit -> unit Lwt.t</code>; this type constructor is used only to express both possibilities in one signature.</p></div></div><div class="odoc-spec"><div class="spec type anchored" id="type-hook"><a href="#type-hook" class="anchor"></a><code><span><span class="keyword">type</span> hook</span></code></div><div class="spec-doc"><p>Values of type <code>hook</code> represent hooks that have been added, so that they can be removed later (if needed).</p></div></div><div class="odoc-spec"><div class="spec value anchored" id="val-add_first"><a href="#val-add_first" class="anchor"></a><code><span><span class="keyword">val</span> add_first : <span><span>(<span>unit <span class="arrow">-></span></span> <span>unit <a href="#type-kind">kind</a></span>)</span> <span class="arrow">-></span></span> <a href="#type-hook">hook</a></span></code></div><div class="spec-doc"><p>Adds a hook to the hook sequence underlying this module, to be run <em>first</em>, before any other hooks already added.</p></div></div><div class="odoc-spec"><div class="spec value anchored" id="val-add_last"><a href="#val-add_last" class="anchor"></a><code><span><span class="keyword">val</span> add_last : <span><span>(<span>unit <span class="arrow">-></span></span> <span>unit <a href="#type-kind">kind</a></span>)</span> <span class="arrow">-></span></span> <a href="#type-hook">hook</a></span></code></div><div class="spec-doc"><p>Adds a hook to the hook sequence underlying this module, to be run <em>last</em>, after any other hooks already added.</p></div></div><div class="odoc-spec"><div class="spec value anchored" id="val-remove"><a href="#val-remove" class="anchor"></a><code><span><span class="keyword">val</span> remove : <span><a href="#type-hook">hook</a> <span class="arrow">-></span></span> unit</span></code></div><div class="spec-doc"><p>Removes a hook added by <a href="#val-add_first"><code>add_first</code></a> or <a href="#val-add_last"><code>add_last</code></a>.</p></div></div><div class="odoc-spec"><div class="spec value anchored" id="val-remove_all"><a href="#val-remove_all" class="anchor"></a><code><span><span class="keyword">val</span> remove_all : <span>unit <span class="arrow">-></span></span> unit</span></code></div><div class="spec-doc"><p>Removes all hooks from the hook sequence underlying this module.</p></div></div></div></body></html>
|