ocaml-containers/dev/containers-data/CCPersistentHashtbl/index.html
2021-10-19 02:39:54 +00:00

2 lines
No EOL
4.2 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"><head><title>CCPersistentHashtbl (containers-data.CCPersistentHashtbl)</title><link rel="stylesheet" href="../../odoc.css"/><meta charset="utf-8"/><meta name="generator" content="odoc 2.0.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">containers-data</a> &#x00BB; CCPersistentHashtbl</nav><header class="odoc-preamble"><h1>Module <code><span>CCPersistentHashtbl</span></code></h1></header><nav class="odoc-toc"><ul><li><a href="#persistent-hash-table-on-top-of-ocaml's-hashtables">Persistent hash-table on top of OCaml's hashtables</a><ul><li><a href="#signature-of-such-a-hashtable">Signature of such a hashtable</a></li><li><a href="#implementation">Implementation</a></li></ul></li></ul></nav><div class="odoc-content"><h2 id="persistent-hash-table-on-top-of-ocaml's-hashtables"><a href="#persistent-hash-table-on-top-of-ocaml's-hashtables" class="anchor"></a>Persistent hash-table on top of OCaml's hashtables</h2><p>Almost as efficient as the regular Hashtbl type, but with a persistent interface (rewinding changes to get back in the past history). This is mostly useful for backtracking-like uses, or forward uses (never using old values).</p><p>This module is not thread-safe.</p><div class="odoc-spec"><div class="spec type" id="type-iter" class="anchored"><a href="#type-iter" class="anchor"></a><code><span><span class="keyword">type</span> <span>'a iter</span></span><span> = <span><span>(<span><span class="type-var">'a</span> <span class="arrow">&#45;&gt;</span></span> unit)</span> <span class="arrow">&#45;&gt;</span></span> unit</span></code></div></div><div class="odoc-spec"><div class="spec type" id="type-printer" class="anchored"><a href="#type-printer" class="anchor"></a><code><span><span class="keyword">type</span> <span>'a printer</span></span><span> = <span><span class="xref-unresolved">Stdlib</span>.Format.formatter <span class="arrow">&#45;&gt;</span></span> <span><span class="type-var">'a</span> <span class="arrow">&#45;&gt;</span></span> unit</span></code></div></div><div class="odoc-spec"><div class="spec type" id="type-equal" class="anchored"><a href="#type-equal" class="anchor"></a><code><span><span class="keyword">type</span> <span>'a equal</span></span><span> = <span><span class="type-var">'a</span> <span class="arrow">&#45;&gt;</span></span> <span><span class="type-var">'a</span> <span class="arrow">&#45;&gt;</span></span> bool</span></code></div></div><div class="odoc-spec"><div class="spec module-type" id="module-type-HashedType" class="anchored"><a href="#module-type-HashedType" class="anchor"></a><code><span><span class="keyword">module</span> <span class="keyword">type</span> </span><span><a href="module-type-HashedType/index.html">HashedType</a></span><span> = <span class="keyword">sig</span> ... <span class="keyword">end</span></span></code></div></div><h3 id="signature-of-such-a-hashtable"><a href="#signature-of-such-a-hashtable" class="anchor"></a>Signature of such a hashtable</h3><div class="odoc-spec"><div class="spec module-type" id="module-type-S" class="anchored"><a href="#module-type-S" class="anchor"></a><code><span><span class="keyword">module</span> <span class="keyword">type</span> </span><span><a href="module-type-S/index.html">S</a></span><span> = <span class="keyword">sig</span> ... <span class="keyword">end</span></span></code></div></div><h3 id="implementation"><a href="#implementation" class="anchor"></a>Implementation</h3><div class="odoc-spec"><div class="spec module" id="module-Make" class="anchored"><a href="#module-Make" class="anchor"></a><code><span><span class="keyword">module</span> </span><span><a href="Make/index.html">Make</a></span><span> (<a href="Make/argument-1-H/index.html">H</a> : <a href="module-type-HashedType/index.html">HashedType</a>) : <a href="module-type-S/index.html">S</a> <span class="keyword">with</span> <span><span class="keyword">type</span> <a href="module-type-S/index.html#type-key">key</a> = <a href="Make/argument-1-H/index.html#type-t">H.t</a></span></span></code></div></div></div></body></html>