mirror of
https://github.com/c-cube/ocaml-containers.git
synced 2025-12-07 11:45:31 -05:00
2 lines
No EOL
5.6 KiB
HTML
2 lines
No EOL
5.6 KiB
HTML
<!DOCTYPE html>
|
||
<html xmlns="http://www.w3.org/1999/xhtml"><head><title>CCTrie (containers.CCTrie)</title><link rel="stylesheet" href="../../odoc.css"/><meta charset="utf-8"/><meta name="viewport" content="width=device-width,initial-scale=1.0"/><script src="../../highlight.pack.js"></script><script>hljs.initHighlightingOnLoad();</script></head><body><div class="content"><header><nav><a href="../index.html">Up</a> – <a href="../index.html">containers</a> » CCTrie</nav><h1>Module <code>CCTrie</code></h1><h2 id="prefix-tree"><a href="#prefix-tree" class="anchor"></a>Prefix Tree</h2><nav class="toc"><ul><li><a href="#signatures">Signatures</a><ul><li><a href="#a-composite-word">A Composite Word</a></li></ul></li><li><a href="#implementation">Implementation</a></li></ul></nav></header><dl><dt class="spec type" id="type-sequence"><a href="#type-sequence" class="anchor"></a><code><span class="keyword">type </span>'a sequence</code><code><span class="keyword"> = </span>(<span class="type-var">'a</span> <span>-></span> unit) <span>-></span> unit</code></dt><dt class="spec type" id="type-ktree"><a href="#type-ktree" class="anchor"></a><code><span class="keyword">type </span>'a ktree</code><code><span class="keyword"> = </span>unit <span>-></span> [ `Nil<span class="keyword"> | </span>`Node of <span class="type-var">'a</span><span class="keyword"> * </span><span class="type-var">'a</span> <a href="index.html#type-ktree">ktree</a> list ]</code></dt></dl><section><header><h2 id="signatures"><a href="#signatures" class="anchor"></a>Signatures</h2></header><section><header><h4 id="a-composite-word"><a href="#a-composite-word" class="anchor"></a>A Composite Word</h4><p>Words are made of characters, who belong to a total order</p></header><div class="spec module-type" id="module-type-WORD"><a href="#module-type-WORD" class="anchor"></a><code><span class="keyword">module type </span><a href="module-type-WORD/index.html">WORD</a> = <span class="keyword">sig</span> ... <span class="keyword">end</span></code></div><div class="spec module-type" id="module-type-S"><a href="#module-type-S" class="anchor"></a><code><span class="keyword">module type </span><a href="module-type-S/index.html">S</a> = <span class="keyword">sig</span> ... <span class="keyword">end</span></code></div></section></section><section><header><h2 id="implementation"><a href="#implementation" class="anchor"></a>Implementation</h2></header><div class="spec module" id="module-Make"><a href="#module-Make" class="anchor"></a><code><span class="keyword">module </span><a href="Make/index.html">Make</a> : <span class="keyword">functor</span> (<a href="Make/argument-1-W/index.html">W</a> : <a href="index.html#module-type-WORD">WORD</a>) <span>-></span> <a href="index.html#module-type-S">S</a><span class="keyword"> with </span><span class="keyword">type </span><a href="Make/index.html#type-key">key</a><span class="keyword"> = </span><a href="Make/argument-1-W/index.html#type-t">W.t</a><span class="keyword"> and </span><span class="keyword">type </span><a href="Make/index.html#type-char_">char_</a><span class="keyword"> = </span><a href="Make/argument-1-W/index.html#type-char_">W.char_</a></code></div><div class="spec module-type" id="module-type-ORDERED"><a href="#module-type-ORDERED" class="anchor"></a><code><span class="keyword">module type </span><a href="module-type-ORDERED/index.html">ORDERED</a> = <span class="keyword">sig</span> ... <span class="keyword">end</span></code></div><div class="spec module" id="module-MakeArray"><a href="#module-MakeArray" class="anchor"></a><code><span class="keyword">module </span><a href="MakeArray/index.html">MakeArray</a> : <span class="keyword">functor</span> (<a href="MakeArray/argument-1-X/index.html">X</a> : <a href="index.html#module-type-ORDERED">ORDERED</a>) <span>-></span> <a href="index.html#module-type-S">S</a><span class="keyword"> with </span><span class="keyword">type </span><a href="MakeArray/index.html#type-key">key</a><span class="keyword"> = </span><a href="MakeArray/argument-1-X/index.html#type-t">X.t</a> array<span class="keyword"> and </span><span class="keyword">type </span><a href="MakeArray/index.html#type-char_">char_</a><span class="keyword"> = </span><a href="MakeArray/argument-1-X/index.html#type-t">X.t</a></code></div><div class="spec module" id="module-MakeList"><a href="#module-MakeList" class="anchor"></a><code><span class="keyword">module </span><a href="MakeList/index.html">MakeList</a> : <span class="keyword">functor</span> (<a href="MakeList/argument-1-X/index.html">X</a> : <a href="index.html#module-type-ORDERED">ORDERED</a>) <span>-></span> <a href="index.html#module-type-S">S</a><span class="keyword"> with </span><span class="keyword">type </span><a href="MakeList/index.html#type-key">key</a><span class="keyword"> = </span><a href="MakeList/argument-1-X/index.html#type-t">X.t</a> list<span class="keyword"> and </span><span class="keyword">type </span><a href="MakeList/index.html#type-char_">char_</a><span class="keyword"> = </span><a href="MakeList/argument-1-X/index.html#type-t">X.t</a></code></div><div class="spec module" id="module-String"><a href="#module-String" class="anchor"></a><code><span class="keyword">module </span><a href="String/index.html">String</a> : <a href="index.html#module-type-S">S</a><span class="keyword"> with </span><span class="keyword">type </span><a href="module-type-S/index.html#type-key">key</a><span class="keyword"> = </span>string<span class="keyword"> and </span><span class="keyword">type </span><a href="module-type-S/index.html#type-char_">char_</a><span class="keyword"> = </span>char</code></div></section></div></body></html> |