Added cabal and vim dir

This commit is contained in:
hellerve committed 2015-04-05 17:47:08 +02:00
1 parent 1e73d5652c
commit ae5a30a4a4
2440 files changed
+40465

No files matched your search

@@ -0,0 +1,22 @@
ConfigFile
Copyright (C) 2004-2010 John Goerzen <jgoerzen@complete.org>
This program is free software; you can redistribute it and/or modify
it under the terms of either:
a) the GNU Lesser General Public License as published by the Free
Software Foundation; either version 2.1 (see the file LGPL-2.1),
or (at your option) any later version, or
b) the 3-clause BSD License (see the file BSD3).
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
You should have received a copy of the GNU Lesser General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
If these licenses are unacceptable for your uses, please e-mail me;
alternative terms can be negotiated for your project.
@@ -0,0 +1,12 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.ConfigFile.Monadic</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-ConfigFile-Monadic.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">ConfigFile-1.1.4: Configuration file reading &amp; writing</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.ConfigFile.Monadic</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Overview</a></li></ul></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:simpleAccess">simpleAccess</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; m <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:interpolatingAccess">interpolatingAccess</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; m <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:readfile">readfile</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/MissingH-1.3.0.1/html/System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (m <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a>)</li><li class="src short"><a href="#v:readhandle">readhandle</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a> -&gt; <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (m <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a>)</li><li class="src short"><a href="#v:readstring">readstring</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; m <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a></li><li class="src short"><a href="#v:has_section">has_section</a> :: <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li class="src short"><a href="#v:options">options</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; m [<a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a>]</li><li class="src short"><a href="#v:has_option">has_option</a> :: <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li class="src short"><a href="#v:items">items</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; m [(<a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)]</li><li class="src short"><a hreLine truncated
cp &lt;- add_section cp &quot;sect1&quot;
cp &lt;- set cp &quot;sect1&quot; &quot;opt1&quot; &quot;foo&quot;
cp &lt;- set cp &quot;sect1&quot; &quot;opt2&quot; &quot;bar&quot;
options cp &quot;sect1&quot;</pre><p>as</p><pre>return emptyCP &gt;&gt;=
add_section &quot;sect1&quot; &gt;&gt;=
set &quot;sect1&quot; &quot;opt1&quot; &quot;foo&quot; &gt;&gt;=
set &quot;sect1&quot; &quot;opt2&quot; &quot;bar&quot; &gt;&gt;=
options &quot;sect1&quot;</pre><p>which may be more elegant in some cases. A future development might be to chain the <code><a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a></code> implicitly with a state monad, which would be yet more elegant.</p></div><div class="top"><p class="src"><a name="v:simpleAccess" class="def">simpleAccess</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; m <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p></div><div class="top"><p class="src"><a name="v:interpolatingAccess" class="def">interpolatingAccess</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; m <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p></div><div class="top"><p class="src"><a name="v:readfile" class="def">readfile</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/MissingH-1.3.0.1/html/System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (m <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a>)</p></div><div class="top"><p class="src"><a name="v:readhandle" class="def">readhandle</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a> -&gt; <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (m <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a>)</p></div><div class="top"><p class="src"><a name="v:readstring" class="def">readstring</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; m <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a></p></div><div class="top"><p class="src"><a name="v:has_section" class="def">has_section</a> :: <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p></div><div class="top"><p class="src"><a name="v:options" class="def">options</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; m [<a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a>]</p></div><div class="top"><p class="src"><a name="v:has_option" class="def">has_option</a> :: <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p></div><div class="top"><p class="src"><a name="v:items" class="def">items</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; m [(<a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)]</p></div><div class="top"><p class="src"><a name="v:set" class="def">set</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:OptionSLine truncated
@@ -0,0 +1,7 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.ConfigFile.Parser</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-ConfigFile-Parser.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">ConfigFile-1.1.4: Configuration file reading &amp; writing</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2008 John Goerzen</td></tr><tr><th>License</th><td>Either LGPL or BSD3, as specified in the COPYRIGHT file.</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.ConfigFile.Parser</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Parser support for <a href="Data-ConfigFile.html">Data.ConfigFile</a>. This module is not intended to be
used directly by your programs.</p><p>Copyright (c) 2004-2008 John Goerzen, jgoerzen@complete.org</p><p>This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:parse_string">parse_string</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; m <a href="Data-ConfigFile-Parser.html#t:ParseOutput">ParseOutput</a></li><li class="src short"><a href="#v:parse_file">parse_file</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/MissingH-1.3.0.1/html/System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (m <a href="Data-ConfigFile-Parser.html#t:ParseOutput">ParseOutput</a>)</li><li class="src short"><a href="#v:parse_handle">parse_handle</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (m <a href="Data-ConfigFile-Parser.html#t:ParseOutput">ParseOutput</a>)</li><li class="src short"><a href="#v:interpmain">interpmain</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>) -&gt; Parser <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><span class="keyword">type</span> <a href="#t:ParseOutput">ParseOutput</a> = [(<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, [(<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)])]</li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:parse_string" class="def">parse_string</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; m <a href="Data-ConfigFile-Parser.html#t:ParseOutput">ParseOutput</a></p></div><div class="top"><p class="src"><a name="v:parse_file" class="def">parse_file</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/MissingH-1.3.0.1/html/System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (m <a href="Data-ConfigFile-Parser.html#t:ParseOutput">ParseOutput</a>)</p></div><div class="top"><p class="src"><a name="v:parse_handle" class="def">parse_handle</a> :: MonadError <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> m =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (m <a href="Data-ConfigFile-Parser.html#t:ParseOutput">ParseOutput</a>)</p></div><div class="top"><p class="src"><a name="v:interpmain" class="def">interpmain</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>) -&gt; Parser <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:ParseOutput" class="def">ParseOutput</a> = [(<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.hLine truncated
@@ -0,0 +1,18 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.ConfigFile.Types</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-ConfigFile-Types.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">ConfigFile-1.1.4: Configuration file reading &amp; writing</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2008 John Goerzen</td></tr><tr><th>License</th><td>Either LGPL or BSD3, as specified in the COPYRIGHT file.</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.ConfigFile.Types</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Internal types for <a href="Data-ConfigFile.html">Data.ConfigFile</a>. This module is not intended to be
used directly by your programs.</p><p>Copyright (c) 2004-2008 John Goerzen, jgoerzen@complete.org</p><p>This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">type</span> <a href="#t:CPOptions">CPOptions</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> <a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><span class="keyword">type</span> <a href="#t:CPData">CPData</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a> <a href="Data-ConfigFile-Types.html#t:CPOptions">CPOptions</a></li><li class="src short"><span class="keyword">data</span> <a href="#t:CPErrorData">CPErrorData</a><ul class="subs"><li>= <a href="#v:ParseError">ParseError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li>| <a href="#v:SectionAlreadyExists">SectionAlreadyExists</a> <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a></li><li>| <a href="#v:NoSection">NoSection</a> <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a></li><li>| <a href="#v:NoOption">NoOption</a> <a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a></li><li>| <a href="#v:OtherProblem">OtherProblem</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li>| <a href="#v:InterpolationError">InterpolationError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li></ul></li><li class="src short"><span class="keyword">type</span> <a href="#t:CPError">CPError</a> = (<a href="Data-ConfigFile-Types.html#t:CPErrorData">CPErrorData</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</li><li class="src short"><span class="keyword">data</span> <a href="#t:ConfigParser">ConfigParser</a> = <a href="#v:ConfigParser">ConfigParser</a> {<ul class="subs"><li><a href="#v:content">content</a> :: <a href="Data-ConfigFile-Types.html#t:CPData">CPData</a></li><li><a href="#v:optionxform">optionxform</a> :: <a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a></li><li><a href="#v:defaulthandler">defaulthandler</a> :: <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li><a href="#v:usedefault">usedefault</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li><a href="#v:accessfunc">accessfunc</a> :: <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li></ul>}</li><li class="src short"><span class="keyword">type</span> <a href="#t:SectionSpec">SectionSpec</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><span class="keyword">type</span> <a href="#t:OptionSpec">OptionSpec</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><span class="keyword">type</span> <a href="#t:ParseOutput">ParseOutput</a> = [(<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, [(<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/Line truncated
Data.ConfigFile. You should NEVER access the FiniteMap in a ConfigParser
directly. This type may change in future releases of MissingH, which could
break your programs. Please retrict yourself to the interface in
<code><a href="Data.html#t:ConfigFile">ConfigFile</a></code>.</p></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:CPErrorData" class="def">CPErrorData</a></p><div class="doc"><p>Possible ConfigParser errors. </p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:ParseError" class="def">ParseError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Parse error</p></td></tr><tr><td class="src"><a name="v:SectionAlreadyExists" class="def">SectionAlreadyExists</a> <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a></td><td class="doc"><p>Attempt to create an already-existing ection</p></td></tr><tr><td class="src"><a name="v:NoSection" class="def">NoSection</a> <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a></td><td class="doc"><p>The section does not exist</p></td></tr><tr><td class="src"><a name="v:NoOption" class="def">NoOption</a> <a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a></td><td class="doc"><p>The option does not exist</p></td></tr><tr><td class="src"><a name="v:OtherProblem" class="def">OtherProblem</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Miscellaneous error</p></td></tr><tr><td class="src"><a name="v:InterpolationError" class="def">InterpolationError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Raised by <code><a href="Data-ConfigFile.html#v:interpolatingAccess">interpolatingAccess</a></code> if a request was made for a non-existant option</p></td></tr></table></div><div class="subs instances"><p id="control.i:CPErrorData" class="caption collapser" onclick="toggleSection('i:CPErrorData')">Instances</p><div id="section.i:CPErrorData" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> <a href="Data-ConfigFile-Types.html#t:CPErrorData">CPErrorData</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> <a href="Data-ConfigFile-Types.html#t:CPErrorData">CPErrorData</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="Data-ConfigFile-Types.html#t:CPErrorData">CPErrorData</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/transformers-0.4.2.0/Control-Monad-Trans-Error.html#t:Error">Error</a> <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:CPError" class="def">CPError</a> = (<a href="Data-ConfigFile-Types.html#t:CPErrorData">CPErrorData</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</p><div class="doc"><p>Indicates an error occurred. The String is an explanation of the location
of the error. </p></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:ConfigParser" class="def">ConfigParser</a></p><div class="doc"><p>This is the main record that is used by <code><a href="Data.html#t:ConfigFile">ConfigFile</a></code>.</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:ConfigParser" class="def">ConfigParser</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div class="subs fields"><p class="caption">Fields</p><dl><dt class="src"><a name="v:content" class="def">content</a> :: <a href="Data-ConfigFile-Types.html#t:CPData">CPData</a></dt><dd class="doc"><p>The data itself</p></dd><dt class="src"><a name="v:optionxform" class="def">optionxform</a> :: <a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a></dt><dd class="doc"><p>How to transform an option into a standard representation</p></dd><dt class="src"><a name="v:defaulthandler" class="def">defaulthandler</a> :: <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></dt><dd class="doc"><p>Function to look up an option, considering a default value
if <code><a href="Data-ConfigFile-Types.html#v:usedefault">usedefault</a></code> is True; or ignoring a default value otherwise.
The option specification is assumed to be already transformed.</p></dd><dt class="src"><a name="v:usedefault" class="def">usedefault</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></dt><dd class="doc"><p>Whether or not to seek out a default action when no match
is found.</p></dd><dt class="src"><a name="v:accessfunc" class="def">accessfunc</a> :: <a href="Data-ConfigFile-Types.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile-Types.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile-Types.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> <a href="Data-ConfigFile-Types.html#t:CPError">CPError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></dt><dd class="doc"><p>Function that is used to perform lookups, do optional
interpolation, etc. It is assumed that accessfunc
will internally call defaulthandler to do the underlying lookup.
The option value is not assumed to be transformed.</p></dd></dl><div class="clear"></div></div></td></tr></table></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:SectionSpec" class="def">SectionSpec</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Names of sections </p></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:OptionSpec" class="def">OptionSpec</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Names of options </p></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:ParseOutput" class="def">ParseOutput</a> = [(<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, [(<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)])]</p><div class="doc"><p>Internal output from parser </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,221 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.ConfigFile</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-ConfigFile.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">ConfigFile-1.1.4: Configuration file reading &amp; writing</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2008 John Goerzen</td></tr><tr><th>License</th><td>Either LGPL or BSD3, as specified in the COPYRIGHT file.</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.ConfigFile</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Introduction</a><ul><li><a href="#g:2">Features</a></li><li><a href="#g:3">History</a></li></ul></li><li><a href="#g:4">Configuration File Format</a><ul><li><a href="#g:5">White Space</a></li><li><a href="#g:6">Comments</a></li><li><a href="#g:7">Case Sensitivity</a></li><li><a href="#g:8">Interpolation</a></li></ul></li><li><a href="#g:9">Usage Examples</a><ul><li><a href="#g:10">Non-Monadic Usage</a></li><li><a href="#g:11">Error Monad Usage</a></li><li><a href="#g:12">Combined Error/IO Monad Usage</a></li></ul></li><li><a href="#g:13">Types</a></li><li><a href="#g:14">Initialization</a></li><li><a href="#g:15">Configuring the ConfigParser</a><ul><li><a href="#g:16">Access Functions</a></li></ul></li><li><a href="#g:17">Reading</a></li><li><a href="#g:18">Accessing Data</a></li><li><a href="#g:19">Modifying Data</a></li><li><a href="#g:20">Output Data</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Configuration file parsing, generation, and manipulation</p><p>Copyright (c) 2004-2008 John Goerzen, jgoerzen@complete.org</p><p>This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.</p><p>This module contains extensive documentation. Please scroll down to the Introduction section to continue reading.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">type</span> <a href="#t:SectionSpec">SectionSpec</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><span class="keyword">type</span> <a href="#t:OptionSpec">OptionSpec</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><span class="keyword">data</span> <a href="#t:ConfigParser">ConfigParser</a> = <a href="#v:ConfigParser">ConfigParser</a> {<ul class="subs"><li><a href="#v:content">content</a> :: <a href="Data-ConfigFile-Types.html#t:CPData">CPData</a></li><li><a href="#v:optionxform">optionxform</a> :: <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a></li><li><a href="#v:defaulthandler">defaulthandler</a> :: <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> <a href="Data-ConfigFile.html#t:CPError">CPError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li><a href="#v:usedefault">usedefault</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li><a href="#v:accessfunc">accessfunc</a> :: <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> <a href="Data-ConfigFile.html#t:CPError">CPError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li></ul>}</li><li class="src short"><span class="keyword">data</span> <a href="#t:CPErrorData">CPErrorData</a><ul class="subs"><li>= <a href="#v:ParseError">ParseError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li>| <a href="#v:SectionAlreadyExists">SectionAlreadyExists</a> <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a></li><li>| <a href="#v:NoSection">NoSection</a> <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a></li><li>| <a href="#v:NoOption">NoOption</a> <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a></li><li>| <a href="#v:OtherProblem">OtherProblem</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li>| <a href="#v:InterpolationError">InterpolationError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li></ul></li><li class="src short"><span class="keyword">type</span> <a href="#t:CPError">CPError</a> = (<a href="Data-ConfigFile.html#t:CPErrorData">CPErrorData</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</li><li class="src short"><a href="#v:emptyCP">emptyCP</a> :: <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></li><li class="src short"><a href="#v:simpleAccess">simpleAccess</a> :: MonadError <a href="Data-ConfigFile.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a> -&gt; m <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:interpolatingAccess">interpolatingAccess</a> :: MonadError <a href="Data-ConfigFile.html#t:CPError">CPError</a> m =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a> -&gt; m <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8Line truncated
typically used to configure certain runtime behaviors that need to be
saved across sessions. Various different configuration file formats
exist.</p><p>The ConfigParser module attempts to define a standard format that is
easy for the user to edit, easy for the programmer to work with, yet
remains powerful and flexible.</p></div><h2 id="g:2">Features</h2><div class="doc"><p>For the programmer, this module provides:</p><ul><li>Simple calls to both read <em>and write</em> configuration files</li><li>Call that can generate a string version of a file that is
re-parsable by this module (useful for, for instance, sending the
file down a network)</li><li>Segmented configuration files that let you separate configuration
into distinct sections, each with its own namespace. This can be
used to configure multiple modules in one file, to configure
multiple instances of a single object, etc.</li><li>On-the-fly parsing of integer, boolean, float, multi-line string values,
and anything else Haskell's read can deal with</li><li>It is possible to make a configuration file parsable by this
module, the Unix shell, and/or Unix make, though some feautres are,
of course, not compatible with these other tools.</li><li>Syntax checking with error reporting including line numbers</li><li>Implemented in pure Haskell. No dependencies on modules outside
the standard library distributed with Haskell compilers or interpreters.
All calls except those that read directly from a handle are pure calls
and can be used outside the IO monad.</li><li>Comprehensive documentation</li><li>Extensible API</li><li>Complete compatibility with Python's ConfigParser module, or my
ConfigParser module for OCaml, part of my MissingLib package.</li></ul><p>For the user, this module provides:</p><ul><li>Easily human-editable configuration files with a clear, concise,
and consistent format</li><li>Configuration file format consistent with other familiar formats
(/etc/passwd is a valid ConfigParser file)</li><li>No need to understand semantics of markup languages like XML</li></ul></div><h2 id="g:3">History</h2><div class="doc"><p>This module is based on Python's ConfigParser module at
<a href="http://www.python.org/doc/current/lib/module-ConfigParser.html">http://www.python.org/doc/current/lib/module-ConfigParser.html</a>. I had
earlier developed an OCaml implementation as part of my MissingLib library
at <a href="gopher://gopher.quux.org/devel/missinglib">gopher://gopher.quux.org/devel/missinglib</a>.</p><p>While the API of these three modules is similar, and the aim is to preserve all
useful features of the original Python module, there are some differences
in the implementation details. This module is a complete, clean re-implementation
in Haskell, not a Haskell translation of a Python program. As such, the feature
set is slightly different.</p></div><h1 id="g:4">Configuration File Format</h1><div class="doc"><p>The basic configuration file format resembles that of an old-style
Windows .INI file. Here are two samples:</p><pre>debug = yes
inputfile = /etc/passwd
names = Peter, Paul, Mary, George, Abrahaham, John, Bill, Gerald, Richard,
Franklin, Woodrow
color = red</pre><p>This defines a file without any explicit section, so all items will
occur within the default section <code>DEFAULT</code>. The <code>debug</code> option can be read
as a boolean or a string. The remaining items can be read as a string
only. The <code>names</code> entry spans two lines -- any line starting with
whitespace, and containing something other than whitespace or
comments, is taken as a continuation of the previous line.</p><p>Here's another example:</p><pre># Default options
[DEFAULT]
hostname: localhost
# Options for the first file
[file1]
location: /usr/local
user: Fred
uid: 1000
optionaltext: Hello, this entire string is included
[file2]
location: /opt
user: Fred
uid: 1001</pre><p>This file defines three sections. The <code>DEFAULT</code> section specifies an
entry <code>hostname</code>. If you attempt to read the hostname option in any
section, and that section doesn't define <code>hostname</code>, you will get the
value from <code>DEFAULT</code> instead. This is a nice time-saver. You can also
note that you can use colons instead of the = character to separate
option names from option entries.</p></div><h2 id="g:5">White Space</h2><div class="doc"><p>Whitespace (spaces, tabs, etc) is automatically stripped from the
beginning and end of all strings. Thus, users can insert whitespace
before/after the colon or equal sign if they like, and it will be
automatically stripped.</p><p>Blank lines or lines consisting solely of whitespace are ignored.</p><p>A line giving an option or a section name may not begin with white space.
This requirement is necessary so there is no ambiguity between such lines
and continuation lines for multi-line options.</p></div><h2 id="g:6">Comments</h2><div class="doc"><p>Comments are introduced with the pound sign <code>#</code> or the semicolon <code>;</code>. They
cause the parser to ignore everything from that character to the end
of the line.</p><p>Comments <em>may not</em> occur within the definitions of options; that is, you
may not place a comment in the middle of a line such as <code>user: Fred</code>.
That is because the parser considers the comment characters part
of the string; otherwise, you'd be unable to use those characters in
your strings. You can, however, &quot;comment out&quot; options by putting the
comment character at the start of the line.</p></div><h2 id="g:7">Case Sensitivity</h2><div class="doc"><p>By default, section names are case-sensitive but option names are
not. The latter can be adjusted by adjusting <code><a href="Data-ConfigFile.html#v:optionxform">optionxform</a></code>. </p></div><h2 id="g:8">Interpolation</h2><div class="doc"><p>Interpolation is an optional feature, disabled by default. If you replace
the default <code><a href="Data-ConfigFile.html#v:accessfunc">accessfunc</a></code> (<code><a href="Data-ConfigFile.html#v:simpleAccess">simpleAccess</a></code>) with <code><a href="Data-ConfigFile.html#v:interpolatingAccess">interpolatingAccess</a></code>,
then you get interpolation support with <code><a href="Data-ConfigFile.html#v:get">get</a></code> and the other <code><a href="Data-ConfigFile.html#v:get">get</a></code>-based functions.</p><p>As an example, consider the following file:</p><pre>arch = i386
project = test
filename = test_%(arch)s.c
dir = /usr/src/%(filename)s
percent = 5%%</pre><p>With interpolation, you would get these results:</p><pre>get cp &quot;DEFAULT&quot; &quot;filename&quot; -&gt; &quot;test_i386.c&quot;
get cp &quot;DEFAULT&quot; &quot;dir&quot; -&gt; &quot;/usr/src/test_i386.c&quot;
get cp &quot;DEFAULT&quot; &quot;percent&quot; -&gt; &quot;5%&quot;</pre><p>For more details on interpolation, please see the documentation for the
<code><a href="Data-ConfigFile.html#v:interpolatingAccess">interpolatingAccess</a></code> function.</p></div><h1 id="g:9">Usage Examples</h1><div class="doc"><p>The basic theory of working with ConfigParser is this:</p><ol><li>Parse or build a <code><a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></code> object</li><li>Work with it in one of several ways</li><li>To make changes, you discard the original object and use a new one.
Changes can be &quot;chained&quot; through one of several monads.</li></ol><p>The default <code><a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></code> object that you always start with is <code><a href="Data-ConfigFile.html#v:emptyCP">emptyCP</a></code>.
From here, you load data into it (merging data into the empty object),
set up structures yourself, or adjust options.</p><p>Let's take a look at some basic use cases.</p></div><h2 id="g:10">Non-Monadic Usage</h2><div class="doc"><p>You'll notice that many functions in this module return a
<code>MonadError <code><a href="Data-ConfigFile.html#t:CPError">CPError</a></code></code> over some
type. Although its definition is not this simple, you can consider this to be
the same as returning <code>Either CPError a</code>.</p><p>That is, these functions will return <code>Left error</code> if there's a problem
or <code>Right result</code> if things are fine. The documentation for individual
functions describes the specific circumstances in which an error may occur in
more detail.</p><p>Some people find it annoying to have to deal with errors manually.
You can transform errors into exceptions in your code by using
<code><a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/MissingH-1.3.0.1/html/Data-Either-Utils.html#v:forceEither">forceEither</a></code>. Here's an example of this style of programming:</p><pre>import Data.Either.Utils
do
val &lt;- readfile emptyCP &quot;/etc/foo.cfg&quot;
let cp = forceEither val
putStrLn &quot;Your setting is:&quot;
putStrLn $ forceEither $ get cp &quot;sect1&quot; &quot;opt1&quot;</pre><p>In short, you can just put <code>forceEither $</code> in front of every call that returns
something that is a MonadError.
This is still a pure functional call, so it can be used outside
of the IO monads. The exception, however, can only be caught in the IO
monad.</p><p>If you don't want to bother with <code><a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/MissingH-1.3.0.1/html/Data-Either-Utils.html#v:forceEither">forceEither</a></code>, you can use the error monad. It's simple and better... read on.</p></div><h2 id="g:11">Error Monad Usage</h2><div class="doc"><p>The return type is actually defined in terms of the Error monad, which is
itself based on the Either data type.</p><p>Here's a neat example of chaining together calls to build up a <code><a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></code>
object:</p><pre>do let cp = emptyCP
cp &lt;- add_section cp &quot;sect1&quot;
cp &lt;- set cp &quot;sect1&quot; &quot;opt1&quot; &quot;foo&quot;
cp &lt;- set cp &quot;sect1&quot; &quot;opt2&quot; &quot;bar&quot;
options cp &quot;sect1&quot;</pre><p>The return value of this little snippet is <code>Right [&quot;opt1&quot;, &quot;opt2&quot;]</code>.
(Note to beginners: unlike the IO monad, you <em>can</em> escape from the Error
monad.)</p><p>Although it's not obvious, there actually was error checking there. If
any of those calls would have generated an error, processing would have
stopped immediately and a <code>Left</code> value would have been returned. Consider
this example:</p><pre>do let cp = emptyCP
cp &lt;- add_section cp &quot;sect1&quot;
cp &lt;- set cp &quot;sect1&quot; &quot;opt1&quot; &quot;foo&quot;
cp &lt;- set cp &quot;sect2&quot; &quot;opt2&quot; &quot;bar&quot;
options cp &quot;sect1&quot;</pre><p>The return value from this is <code>Left (<code><a href="Data-ConfigFile.html#v:NoSection">NoSection</a></code> &quot;sect2&quot;, &quot;set&quot;)</code>. The
second call to <code><a href="Data-ConfigFile.html#v:set">set</a></code> failed, so the final call was skipped, and the result
of the entire computation was considered to be an error.</p><p>You can combine this with the non-monadic style to get a final, pure value
out of it:</p><pre>forceEither $ do let cp = emptyCP
cp &lt;- add_section cp &quot;sect1&quot;
cp &lt;- set cp &quot;sect1&quot; &quot;opt1&quot; &quot;foo&quot;
cp &lt;- set cp &quot;sect1&quot; &quot;opt2&quot; &quot;bar&quot;
options cp &quot;sect1&quot;</pre><p>This returns <code>[&quot;opt1&quot;, &quot;opt2&quot;]</code>. A quite normal value.</p></div><h2 id="g:12">Combined Error/IO Monad Usage</h2><div class="doc"><p>You've seen a nice way to use this module in the Error monad and get an Either
value out. But that's the Error monad, so IO is not permitted.
Using Haskell's monad transformers, you can run it in the combined
Error/IO monad. That is, you will get an IO result back. Here is a full
standalone example of doing that:</p><pre>import Data.ConfigFile
import Control.Monad.Error
main = do
rv &lt;- runErrorT $
do
cp &lt;- join $ liftIO $ readfile emptyCP &quot;/etc/passwd&quot;
let x = cp
liftIO $ putStrLn &quot;In the test&quot;
nb &lt;- get x &quot;DEFAULT&quot; &quot;nobody&quot;
liftIO $ putStrLn nb
foo &lt;- get x &quot;DEFAULT&quot; &quot;foo&quot;
liftIO $ putStrLn foo
return &quot;done&quot;
print rv</pre><p>On my system, this prints:</p><pre>In the test
x:65534:65534:nobody:/nonexistent:/bin/sh
Left (NoOption &quot;foo&quot;,&quot;get&quot;)</pre><p>That is, my <code>/etc/passwd</code> file contains a <code>nobody</code> user but not a <code>foo</code> user.</p><p>Let's look at how that works.</p><p>First, <code>main</code> always runs in the IO monad only, so we take the result from
the later calls and put it in <code>rv</code>. Note that the combined block
is started with <code>runErrorT $ do</code> instead of just <code>do</code>.</p><p>To get something out of the call to <code><a href="Data-ConfigFile.html#v:readfile">readfile</a></code>, we use
<code>join $ liftIO $ readfile</code>. This will bring the result out of the IO monad
into the combined monad and process it like usual. From here on,
everything looks normal, except for IO calls. They are all executed under
<code>liftIO</code> so that the result value is properly brought into the combined
monad. This finally returns <code>&quot;done&quot;</code>. Since we are in the Error monad, that means that the literal value is <code>Right &quot;done&quot;</code>. Since we are also in the IO
monad, this is wrapped in IO. So the final return type after applying
<code>runErrorT</code> is <code>IO (Either CPError String)</code>.</p><p>In this case, there was an error, and processing stopped at that point just
like the example of the pure Error monad. We print out the return value,
so you see the error displayed as a <code>Left</code> value.</p><p>It all works quite easily.</p></div><h1 id="g:13">Types</h1><div class="doc"><p>The code used to say this:</p><pre>type CPResult a = MonadError CPError m =&gt; m a
simpleAccess :: ConfigParser -&gt; SectionSpec -&gt; OptionSpec -&gt; CPResult String</pre><p>But Hugs did not support that type declaration. Therefore, types are now
given like this:</p><pre>simpleAccess :: MonadError CPError m =&gt;
ConfigParser -&gt; SectionSpec -&gt; OptionSpec -&gt; m String</pre><p>Although it looks more confusing than before, it still means the same.
The return value can still be treated as <code>Either CPError String</code> if you so
desire.</p></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:SectionSpec" class="def">SectionSpec</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Names of sections </p></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:OptionSpec" class="def">OptionSpec</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Names of options </p></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:ConfigParser" class="def">ConfigParser</a></p><div class="doc"><p>This is the main record that is used by <code><a href="Data.html#t:ConfigFile">ConfigFile</a></code>.</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:ConfigParser" class="def">ConfigParser</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div class="subs fields"><p class="caption">Fields</p><dl><dt class="src"><a name="v:content" class="def">content</a> :: <a href="Data-ConfigFile-Types.html#t:CPData">CPData</a></dt><dd class="doc"><p>The data itself</p></dd><dt class="src"><a name="v:optionxform" class="def">optionxform</a> :: <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a></dt><dd class="doc"><p>How to transform an option into a standard representation</p></dd><dt class="src"><a name="v:defaulthandler" class="def">defaulthandler</a> :: <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> <a href="Data-ConfigFile.html#t:CPError">CPError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></dt><dd class="doc"><p>Function to look up an option, considering a default value
if <code><a href="Data-ConfigFile.html#v:usedefault">usedefault</a></code> is True; or ignoring a default value otherwise.
The option specification is assumed to be already transformed.</p></dd><dt class="src"><a name="v:usedefault" class="def">usedefault</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></dt><dd class="doc"><p>Whether or not to seek out a default action when no match
is found.</p></dd><dt class="src"><a name="v:accessfunc" class="def">accessfunc</a> :: <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> <a href="Data-ConfigFile.html#t:CPError">CPError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></dt><dd class="doc"><p>Function that is used to perform lookups, do optional
interpolation, etc. It is assumed that accessfunc
will internally call defaulthandler to do the underlying lookup.
The option value is not assumed to be transformed.</p></dd></dl><div class="clear"></div></div></td></tr></table></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:CPErrorData" class="def">CPErrorData</a></p><div class="doc"><p>Possible ConfigParser errors. </p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:ParseError" class="def">ParseError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Parse error</p></td></tr><tr><td class="src"><a name="v:SectionAlreadyExists" class="def">SectionAlreadyExists</a> <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a></td><td class="doc"><p>Attempt to create an already-existing ection</p></td></tr><tr><td class="src"><a name="v:NoSection" class="def">NoSection</a> <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a></td><td class="doc"><p>The section does not exist</p></td></tr><tr><td class="src"><a name="v:NoOption" class="def">NoOption</a> <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a></td><td class="doc"><p>The option does not exist</p></td></tr><tr><td class="src"><a name="v:OtherProblem" class="def">OtherProblem</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Miscellaneous error</p></td></tr><tr><td class="src"><a name="v:InterpolationError" class="def">InterpolationError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Raised by <code><a href="Data-ConfigFile.html#v:interpolatingAccess">interpolatingAccess</a></code> if a request was made for a non-existant option</p></td></tr></table></div><div class="subs instances"><p id="control.i:CPErrorData" class="caption collapser" onclick="toggleSection('i:CPErrorData')">Instances</p><div id="section.i:CPErrorData" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> <a href="Data-ConfigFile.html#t:CPErrorData">CPErrorData</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> <a href="Data-ConfigFile.html#t:CPErrorData">CPErrorData</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="Data-ConfigFile.html#t:CPErrorData">CPErrorData</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/transformers-0.4.2.0/Control-Monad-Trans-Error.html#t:Error">Error</a> <a href="Data-ConfigFile.html#t:CPError">CPError</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:CPError" class="def">CPError</a> = (<a href="Data-ConfigFile.html#t:CPErrorData">CPErrorData</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</p><div class="doc"><p>Indicates an error occurred. The String is an explanation of the location
of the error. </p></div></div><h1 id="g:14">Initialization</h1><div class="top"><p class="src"><a name="v:emptyCP" class="def">emptyCP</a> :: <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></p><div class="doc"><p>The default empty <code><a href="Data.html#t:ConfigFile">ConfigFile</a></code> object.</p><p>The content contains only an empty mandatory <code>DEFAULT</code> section.</p><p><code><a href="Data-ConfigFile.html#v:optionxform">optionxform</a></code> is set to <code>map toLower</code>.</p><p><code><a href="Data-ConfigFile.html#v:usedefault">usedefault</a></code> is set to <code>True</code>.</p><p><code><a href="Data-ConfigFile.html#v:accessfunc">accessfunc</a></code> is set to <code><a href="Data-ConfigFile.html#v:simpleAccess">simpleAccess</a></code>.</p></div></div><h1 id="g:15">Configuring the ConfigParser</h1><div class="doc"><p>You may notice that the <code><a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></code> object has some configurable parameters,
such as <code><a href="Data-ConfigFile.html#v:usedefault">usedefault</a></code>. In case you're not familiar with the Haskell syntax
for working with these, you can use syntax like this to set these options:</p><pre>let cp2 = cp { usedefault = False }</pre><p>This will create a new <code><a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></code> that is the same as <code>cp</code> except for
the <code><a href="Data-ConfigFile.html#v:usedefault">usedefault</a></code> field, which is now always False. The new object will be
called <code>cp2</code> in this example.</p></div><h2 id="g:16">Access Functions</h2><div class="top"><p class="src"><a name="v:simpleAccess" class="def">simpleAccess</a> :: MonadError <a href="Data-ConfigFile.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a> -&gt; m <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Default (non-interpolating) access function </p></div></div><div class="top"><p class="src"><a name="v:interpolatingAccess" class="def">interpolatingAccess</a> :: MonadError <a href="Data-ConfigFile.html#t:CPError">CPError</a> m =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a> -&gt; m <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Interpolating access function. Please see the Interpolation section
above for a background on interpolation.</p><p>Although the format string looks similar to one used by <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Printf.html">Text.Printf</a>,
it is not the same. In particular, only the %(...)s format is supported.
No width specifiers are supported and no conversions other than s are supported.</p><p>To use this function, you must specify a maximum recursion depth for
interpolation. This is used to prevent a stack overflow in the event that
the configuration file contains an endless interpolation loop. Values of 10
or so are usually more than enough, though you could probably go into the
hundreds or thousands before you have actual problems.</p><p>A value less than one will cause an instant error every time you attempt
a lookup.</p><p>This access method can cause <code><a href="Data-ConfigFile.html#v:get">get</a></code> and friends to return a new <code><a href="Data-ConfigFile.html#t:CPError">CPError</a></code>:
<code><a href="Data-ConfigFile.html#v:InterpolationError">InterpolationError</a></code>. This error would be returned when:</p><ul><li>The configuration file makes a reference to an option that does
not exist</li><li>The maximum interpolation depth is exceeded</li><li>There is a syntax error processing a %-directive in the configuration
file</li></ul><p>An interpolation lookup name specifies an option only. There is no provision
to specify a section. Interpolation variables are looked up in the current
section, and, if <code><a href="Data-ConfigFile.html#v:usedefault">usedefault</a></code> is True, in <code>DEFAULT</code> according to the normal
logic.</p><p>To use a literal percent sign, you must place <code>%%</code> in the configuration
file when interpolation is used.</p><p>Here is how you might enable interpolation:</p><pre>let cp2 = cp {accessfunc = interpolatingAccess 10}</pre><p>The <code>cp2</code> object will now support interpolation with a maximum depth of 10.</p></div></div><h1 id="g:17">Reading</h1><div class="doc"><p>You can use these functions to read data from a file.</p><p>A common idiom for loading a new object from stratch is:</p><pre>cp &lt;- <code><a href="Data-ConfigFile.html#v:readfile">readfile</a></code> <code><a href="Data-ConfigFile.html#v:emptyCP">emptyCP</a></code> &quot;/etc/foo.cfg&quot;</pre><p>Note the use of <code><a href="Data-ConfigFile.html#v:emptyCP">emptyCP</a></code>; this will essentially cause the file's data
to be merged with the empty <code><a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></code>.</p></div><div class="top"><p class="src"><a name="v:readfile" class="def">readfile</a> :: MonadError <a href="Data-ConfigFile.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/MissingH-1.3.0.1/html/System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (m <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a>)</p><div class="doc"><p>Loads data from the specified file. It is then combined with the
given <code><a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></code> using the semantics documented under <code><a href="Data-ConfigFile.html#v:merge">merge</a></code> with the
new data taking precedence over the old. However, unlike
<code><a href="Data-ConfigFile.html#v:merge">merge</a></code>, all the options
as set in the old object are preserved since the on-disk representation
does not convey those options.</p><p>May return an error if there is a syntax error. May raise an exception if the file could not be accessed.</p></div></div><div class="top"><p class="src"><a name="v:readhandle" class="def">readhandle</a> :: MonadError <a href="Data-ConfigFile.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (m <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a>)</p><div class="doc"><p>Like <code><a href="Data-ConfigFile.html#v:readfile">readfile</a></code>, but uses an already-open handle. You should
use <code><a href="Data-ConfigFile.html#v:readfile">readfile</a></code> instead of this if possible, since it will be able to
generate better error messages.</p><p>Errors would be returned on a syntax error.</p></div></div><div class="top"><p class="src"><a name="v:readstring" class="def">readstring</a> :: MonadError <a href="Data-ConfigFile.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; m <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></p><div class="doc"><p>Like <code><a href="Data-ConfigFile.html#v:readfile">readfile</a></code>, but uses a string. You should use <code><a href="Data-ConfigFile.html#v:readfile">readfile</a></code>
instead of this if you are processing a file, since it can generate
better error messages.</p><p>Errors would be returned on a syntax error.</p></div></div><h1 id="g:18">Accessing Data</h1><div class="top"><p class="src"><span class="keyword">class</span> <a name="t:Get_C" class="def">Get_C</a> a <span class="keyword">where</span></p><div class="doc"><p>The class representing the data types that can be returned by &quot;get&quot;.</p></div><div class="subs methods"><p class="caption">Methods</p><p class="src"><a name="v:get" class="def">get</a> :: MonadError <a href="Data-ConfigFile.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a> -&gt; m a</p><div class="doc"><p>Retrieves a string from the configuration file.</p><p>When used in a context where a String is expected, returns that string verbatim.</p><p>When used in a context where a Bool is expected, parses the string to
a Boolean value (see logic below).</p><p>When used in a context where anything that is an instance of Read is expected,
calls read to parse the item.</p><p>An error will be returned of no such option could be found or if it could
not be parsed as a boolean (when returning a Bool).</p><p>When parsing to a Bool, strings are case-insentively converted as follows:</p><p>The following will produce a True value:</p><ul><li>1</li><li>yes</li><li>on</li><li>enabled</li><li>true</li></ul><p>The following will produce a False value:</p><ul><li>0</li><li>no</li><li>off</li><li>disabled</li><li>false </li></ul></div></div><div class="subs instances"><p id="control.i:Get_C" class="caption collapser" onclick="toggleSection('i:Get_C')">Instances</p><div id="section.i:Get_C" class="show"><table><tr><td class="src"><a href="Data-ConfigFile.html#t:Get_C">Get_C</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Data-ConfigFile.html#t:Get_C">Get_C</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> t =&gt; <a href="Data-ConfigFile.html#t:Get_C">Get_C</a> t</td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><a name="v:sections" class="def">sections</a> :: <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; [<a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a>]</p><div class="doc"><p>Returns a list of sections in your configuration file. Never includes
the always-present section <code>DEFAULT</code>. </p></div></div><div class="top"><p class="src"><a name="v:has_section" class="def">has_section</a> :: <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>Indicates whether the given section exists.</p><p>No special <code>DEFAULT</code> processing is done. </p></div></div><div class="top"><p class="src"><a name="v:options" class="def">options</a> :: MonadError <a href="Data-ConfigFile.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a> -&gt; m [<a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a>]</p><div class="doc"><p>Returns a list of the names of all the options present in the
given section.</p><p>Returns an error if the given section does not exist.</p></div></div><div class="top"><p class="src"><a name="v:has_option" class="def">has_option</a> :: <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>Indicates whether the given option is present. Returns True
only if the given section is present AND the given option is present
in that section. No special <code>DEFAULT</code> processing is done. No
exception could be raised or error returned.</p></div></div><div class="top"><p class="src"><a name="v:items" class="def">items</a> :: MonadError <a href="Data-ConfigFile.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a> -&gt; m [(<a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)]</p><div class="doc"><p>Returns a list of <code>(optionname, value)</code> pairs representing the content
of the given section. Returns an error the section is invalid. </p></div></div><h1 id="g:19">Modifying Data</h1><div class="top"><p class="src"><a name="v:set" class="def">set</a> :: MonadError <a href="Data-ConfigFile.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; m <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></p><div class="doc"><p>Sets the option to a new value, replacing an existing one if it exists.</p><p>Returns an error if the section does not exist. </p></div></div><div class="top"><p class="src"><a name="v:setshow" class="def">setshow</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a, MonadError <a href="Data-ConfigFile.html#t:CPError">CPError</a> m) =&gt; <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a> -&gt; a -&gt; m <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></p><div class="doc"><p>Sets the option to a new value, replacing an existing one if it exists.
It requires only a showable value as its parameter.
This can be used with bool values, as well as numeric ones.</p><p>Returns an error if the section does not exist. </p></div></div><div class="top"><p class="src"><a name="v:remove_option" class="def">remove_option</a> :: MonadError <a href="Data-ConfigFile.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a> -&gt; <a href="Data-ConfigFile.html#t:OptionSpec">OptionSpec</a> -&gt; m <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></p><div class="doc"><p>Removes the specified option. Returns a <code><a href="Data-ConfigFile.html#v:NoSection">NoSection</a></code> error if the
section does not exist and a <code><a href="Data-ConfigFile.html#v:NoOption">NoOption</a></code> error if the option does not
exist. Otherwise, returns the new <code><a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></code> object.</p></div></div><div class="top"><p class="src"><a name="v:add_section" class="def">add_section</a> :: MonadError <a href="Data-ConfigFile.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a> -&gt; m <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></p><div class="doc"><p>Adds the specified section name. Returns a
<code><a href="Data-ConfigFile.html#v:SectionAlreadyExists">SectionAlreadyExists</a></code> error if the
section was already present. Otherwise, returns the new
<code><a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></code> object.</p></div></div><div class="top"><p class="src"><a name="v:remove_section" class="def">remove_section</a> :: MonadError <a href="Data-ConfigFile.html#t:CPError">CPError</a> m =&gt; <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:SectionSpec">SectionSpec</a> -&gt; m <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></p><div class="doc"><p>Removes the specified section. Returns a <code><a href="Data-ConfigFile.html#v:NoSection">NoSection</a></code> error if
the section does not exist; otherwise, returns the new <code><a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></code>
object.</p><p>This call may not be used to remove the <code>DEFAULT</code> section. Attempting to do
so will always cause a <code><a href="Data-ConfigFile.html#v:NoSection">NoSection</a></code> error.</p></div></div><div class="top"><p class="src"><a name="v:merge" class="def">merge</a> :: <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></p><div class="doc"><p>Combines two <code><a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></code>s into one.</p><p>Any duplicate options are resolved to contain the value specified in
the second parser.</p><p>The <code><a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></code> options in the resulting object will be set as they
are in the second one passed to this function. </p></div></div><h1 id="g:20">Output Data</h1><div class="top"><p class="src"><a name="v:to_string" class="def">to_string</a> :: <a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Converts the <code><a href="Data-ConfigFile.html#t:ConfigParser">ConfigParser</a></code> to a string representation that could be
later re-parsed by this module or modified by a human.</p><p>Note that this does not necessarily re-create a file that was originally
loaded. Things may occur in a different order, comments will be removed,
etc. The conversion makes an effort to make the result human-editable,
but it does not make an effort to make the result identical to the original
input.</p><p>The result is, however, guaranteed to parse the same as the original input.</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>ConfigFile-1.1.4: Configuration file reading &amp; writing (Index)</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">ConfigFile-1.1.4: Configuration file reading &amp; writing</p></div><div id="content"><div id="index"><p class="caption">Index</p><table><tr><td class="src">accessfunc</td><td class="module"><a href="Data-ConfigFile-Types.html#v:accessfunc">Data.ConfigFile.Types</a>, <a href="Data-ConfigFile.html#v:accessfunc">Data.ConfigFile</a>, Data.ConfigFile.Monadic</td></tr><tr><td class="src">add_section</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Function)</td><td class="module"><a href="Data-ConfigFile.html#v:add_section">Data.ConfigFile</a></td></tr><tr><td class="alt">2 (Function)</td><td class="module"><a href="Data-ConfigFile-Monadic.html#v:add_section">Data.ConfigFile.Monadic</a></td></tr><tr><td class="src">ConfigParser</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Type/Class)</td><td class="module"><a href="Data-ConfigFile-Types.html#t:ConfigParser">Data.ConfigFile.Types</a>, <a href="Data-ConfigFile.html#t:ConfigParser">Data.ConfigFile</a>, Data.ConfigFile.Monadic</td></tr><tr><td class="alt">2 (Data Constructor)</td><td class="module"><a href="Data-ConfigFile-Types.html#v:ConfigParser">Data.ConfigFile.Types</a>, <a href="Data-ConfigFile.html#v:ConfigParser">Data.ConfigFile</a>, Data.ConfigFile.Monadic</td></tr><tr><td class="src">content</td><td class="module"><a href="Data-ConfigFile-Types.html#v:content">Data.ConfigFile.Types</a>, <a href="Data-ConfigFile.html#v:content">Data.ConfigFile</a>, Data.ConfigFile.Monadic</td></tr><tr><td class="src">CPData</td><td class="module"><a href="Data-ConfigFile-Types.html#t:CPData">Data.ConfigFile.Types</a></td></tr><tr><td class="src">CPError</td><td class="module"><a href="Data-ConfigFile-Types.html#t:CPError">Data.ConfigFile.Types</a>, <a href="Data-ConfigFile.html#t:CPError">Data.ConfigFile</a>, Data.ConfigFile.Monadic</td></tr><tr><td class="src">CPErrorData</td><td class="module"><a href="Data-ConfigFile-Types.html#t:CPErrorData">Data.ConfigFile.Types</a>, <a href="Data-ConfigFile.html#t:CPErrorData">Data.ConfigFile</a>, Data.ConfigFile.Monadic</td></tr><tr><td class="src">CPOptions</td><td class="module"><a href="Data-ConfigFile-Types.html#t:CPOptions">Data.ConfigFile.Types</a></td></tr><tr><td class="src">defaulthandler</td><td class="module"><a href="Data-ConfigFile-Types.html#v:defaulthandler">Data.ConfigFile.Types</a>, <a href="Data-ConfigFile.html#v:defaulthandler">Data.ConfigFile</a>, Data.ConfigFile.Monadic</td></tr><tr><td class="src">emptyCP</td><td class="module"><a href="Data-ConfigFile.html#v:emptyCP">Data.ConfigFile</a>, Data.ConfigFile.Monadic</td></tr><tr><td class="src">get</td><td class="module"><a href="Data-ConfigFile.html#v:get">Data.ConfigFile</a>, Data.ConfigFile.Monadic</td></tr><tr><td class="src">Get_C</td><td class="module"><a href="Data-ConfigFile.html#t:Get_C">Data.ConfigFile</a>, Data.ConfigFile.Monadic</td></tr><tr><td class="src">has_option</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Function)</td><td class="module"><a href="Data-ConfigFile.html#v:has_option">Data.ConfigFile</a></td></tr><tr><td class="alt">2 (Function)</td><td class="module"><a href="Data-ConfigFile-Monadic.html#v:has_option">Data.ConfigFile.Monadic</a></td></tr><tr><td class="src">has_section</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Function)</td><td class="module"><a href="Data-ConfigFile.html#v:has_section">Data.ConfigFile</a></td></tr><tr><td class="alt">2 (Function)</td><td class="module"><a href="Data-ConfigFile-Monadic.html#v:has_section">Data.ConfigFile.Monadic</a></td></tr><tr><td class="src">interpmain</td><td class="module"><a href="Data-ConfigFile-Parser.html#v:interpmain">Data.ConfigFile.Parser</a></td></tr><tr><td class="src">interpolatingAccess</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Function)</td><td class="module"><a href="Data-ConfigFile.html#v:interpolatingAccess">Data.ConfigFile</a></td></tr><tr><td class="alt">2 (Function)</td><td class="module"><a href="Data-ConfigFile-Monadic.html#v:interpolatingAccess">Data.ConfigFile.Monadic</a></td></tr><tr><td class="src">InterpolationError</td><td class="module"><a href="Data-ConfigFile-Types.html#v:InterpolationError">Data.ConfigFile.Types</a>, <a href="Data-ConfigFile.html#v:InterpolationError">Data.ConfigFile</a></td></tr><tr><td class="src">items</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Function)</td><td class="module"><a href="Data-ConfigFile.html#v:items">Data.ConfigFile</a></td></tr><tr><td class="alt">2 (Function)</td><td class="module"><a href="Data-ConfigFile-Monadic.html#v:items">Data.ConfigFile.Monadic</a></td></tr><tr><td class="src">merge</td><td class="module"><a href="Data-ConfigFile.html#v:merge">Data.ConfigFile</a>, Data.ConfigFile.Monadic</td></tr><tr><td class="src">NoOption</td><td class="module"><a href="Data-ConfigFile-Types.html#v:NoOption">Data.ConfigFile.Types</a>,Line truncated
@@ -0,0 +1,30 @@
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>
<script src="haddock-util.js" type="text/javascript"></script>
<script type="text/javascript"><!--
/*
The synopsis frame needs to be updated using javascript, so we hide
it by default and only show it if javascript is enabled.
TODO: provide some means to disable it.
*/
function load() {
var d = document.getElementById("inner-fs");
d.rows = "50%,50%";
postReframe();
}
--></script>
</head>
<frameset id="outer-fs" cols="25%,75%" onload="load()">
<frameset id="inner-fs" rows="100%,0%">
<frame src="index-frames.html" name="modules" />
<frame src="" name="synopsis" />
</frameset>
<frame src="index.html" name="main" />
</frameset>
</html>
@@ -0,0 +1,344 @@
// Haddock JavaScript utilities
var rspace = /\s\s+/g,
rtrim = /^\s+|\s+$/g;
function spaced(s) { return (" " + s + " ").replace(rspace, " "); }
function trim(s) { return s.replace(rtrim, ""); }
function hasClass(elem, value) {
var className = spaced(elem.className || "");
return className.indexOf( " " + value + " " ) >= 0;
}
function addClass(elem, value) {
var className = spaced(elem.className || "");
if ( className.indexOf( " " + value + " " ) < 0 ) {
elem.className = trim(className + " " + value);
}
}
function removeClass(elem, value) {
var className = spaced(elem.className || "");
className = className.replace(" " + value + " ", " ");
elem.className = trim(className);
}
function toggleClass(elem, valueOn, valueOff, bool) {
if (bool == null) { bool = ! hasClass(elem, valueOn); }
if (bool) {
removeClass(elem, valueOff);
addClass(elem, valueOn);
}
else {
removeClass(elem, valueOn);
addClass(elem, valueOff);
}
return bool;
}
function makeClassToggle(valueOn, valueOff)
{
return function(elem, bool) {
return toggleClass(elem, valueOn, valueOff, bool);
}
}
toggleShow = makeClassToggle("show", "hide");
toggleCollapser = makeClassToggle("collapser", "expander");
function toggleSection(id)
{
var b = toggleShow(document.getElementById("section." + id));
toggleCollapser(document.getElementById("control." + id), b);
rememberCollapsed(id, b);
return b;
}
var collapsed = {};
function rememberCollapsed(id, b)
{
if(b)
delete collapsed[id]
else
collapsed[id] = null;
var sections = [];
for(var i in collapsed)
{
if(collapsed.hasOwnProperty(i))
sections.push(i);
}
// cookie specific to this page; don't use setCookie which sets path=/
document.cookie = "collapsed=" + escape(sections.join('+'));
}
function restoreCollapsed()
{
var cookie = getCookie("collapsed");
if(!cookie)
return;
var ids = cookie.split('+');
for(var i in ids)
{
if(document.getElementById("section." + ids[i]))
toggleSection(ids[i]);
}
}
function setCookie(name, value) {
document.cookie = name + "=" + escape(value) + ";path=/;";
}
function clearCookie(name) {
document.cookie = name + "=;path=/;expires=Thu, 01-Jan-1970 00:00:01 GMT;";
}
function getCookie(name) {
var nameEQ = name + "=";
var ca = document.cookie.split(';');
for(var i=0;i < ca.length;i++) {
var c = ca[i];
while (c.charAt(0)==' ') c = c.substring(1,c.length);
if (c.indexOf(nameEQ) == 0) {
return unescape(c.substring(nameEQ.length,c.length));
}
}
return null;
}
var max_results = 75; // 50 is not enough to search for map in the base libraries
var shown_range = null;
var last_search = null;
function quick_search()
{
perform_search(false);
}
function full_search()
{
perform_search(true);
}
function perform_search(full)
{
var text = document.getElementById("searchbox").value.toLowerCase();
if (text == last_search && !full) return;
last_search = text;
var table = document.getElementById("indexlist");
var status = document.getElementById("searchmsg");
var children = table.firstChild.childNodes;
// first figure out the first node with the prefix
var first = bisect(-1);
var last = (first == -1 ? -1 : bisect(1));
if (first == -1)
{
table.className = "";
status.innerHTML = "No results found, displaying all";
}
else if (first == 0 && last == children.length - 1)
{
table.className = "";
status.innerHTML = "";
}
else if (last - first >= max_results && !full)
{
table.className = "";
status.innerHTML = "More than " + max_results + ", press Search to display";
}
else
{
// decide what you need to clear/show
if (shown_range)
setclass(shown_range[0], shown_range[1], "indexrow");
setclass(first, last, "indexshow");
shown_range = [first, last];
table.className = "indexsearch";
status.innerHTML = "";
}
function setclass(first, last, status)
{
for (var i = first; i <= last; i++)
{
children[i].className = status;
}
}
// do a binary search, treating 0 as ...
// return either -1 (no 0's found) or location of most far match
function bisect(dir)
{
var first = 0, finish = children.length - 1;
var mid, success = false;
while (finish - first > 3)
{
mid = Math.floor((finish + first) / 2);
var i = checkitem(mid);
if (i == 0) i = dir;
if (i == -1)
finish = mid;
else
first = mid;
}
var a = (dir == 1 ? first : finish);
var b = (dir == 1 ? finish : first);
for (var i = b; i != a - dir; i -= dir)
{
if (checkitem(i) == 0) return i;
}
return -1;
}
// from an index, decide what the result is
// 0 = match, -1 is lower, 1 is higher
function checkitem(i)
{
var s = getitem(i).toLowerCase().substr(0, text.length);
if (s == text) return 0;
else return (s > text ? -1 : 1);
}
// from an index, get its string
// this abstracts over alternates
function getitem(i)
{
for ( ; i >= 0; i--)
{
var s = children[i].firstChild.firstChild.data;
if (s.indexOf(' ') == -1)
return s;
}
return ""; // should never be reached
}
}
function setSynopsis(filename) {
if (parent.window.synopsis) {
if (parent.window.synopsis.location.replace) {
// In Firefox this avoids adding the change to the history.
parent.window.synopsis.location.replace(filename);
} else {
parent.window.synopsis.location = filename;
}
}
}
function addMenuItem(html) {
var menu = document.getElementById("page-menu");
if (menu) {
var btn = menu.firstChild.cloneNode(false);
btn.innerHTML = html;
menu.appendChild(btn);
}
}
function adjustForFrames() {
var bodyCls;
if (parent.location.href == window.location.href) {
// not in frames, so add Frames button
addMenuItem("<a href='#' onclick='reframe();return true;'>Frames</a>");
bodyCls = "no-frame";
}
else {
bodyCls = "in-frame";
}
addClass(document.body, bodyCls);
}
function reframe() {
setCookie("haddock-reframe", document.URL);
window.location = "frames.html";
}
function postReframe() {
var s = getCookie("haddock-reframe");
if (s) {
parent.window.main.location = s;
clearCookie("haddock-reframe");
}
}
function styles() {
var i, a, es = document.getElementsByTagName("link"), rs = [];
for (i = 0; a = es[i]; i++) {
if(a.rel.indexOf("style") != -1 && a.title) {
rs.push(a);
}
}
return rs;
}
function addStyleMenu() {
var as = styles();
var i, a, btns = "";
for(i=0; a = as[i]; i++) {
btns += "<li><a href='#' onclick=\"setActiveStyleSheet('"
+ a.title + "'); return false;\">"
+ a.title + "</a></li>"
}
if (as.length > 1) {
var h = "<div id='style-menu-holder'>"
+ "<a href='#' onclick='styleMenu(); return false;'>Style &#9662;</a>"
+ "<ul id='style-menu' class='hide'>" + btns + "</ul>"
+ "</div>";
addMenuItem(h);
}
}
function setActiveStyleSheet(title) {
var as = styles();
var i, a, found;
for(i=0; a = as[i]; i++) {
a.disabled = true;
// need to do this always, some browsers are edge triggered
if(a.title == title) {
found = a;
}
}
if (found) {
found.disabled = false;
setCookie("haddock-style", title);
}
else {
as[0].disabled = false;
clearCookie("haddock-style");
}
styleMenu(false);
}
function resetStyle() {
var s = getCookie("haddock-style");
if (s) setActiveStyleSheet(s);
}
function styleMenu(show) {
var m = document.getElementById('style-menu');
if (m) toggleShow(m, show);
}
function pageLoad() {
addStyleMenu();
adjustForFrames();
resetStyle();
restoreCollapsed();
}
Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>ConfigFile-1.1.4: Configuration file reading &amp; writing</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body id="mini"><div id="module-list"><p class="caption">Modules</p><ul><li class="module"><a href="Data-ConfigFile.html" target="main">Data.ConfigFile</a></li><li class="module"><a href="Data-ConfigFile-Monadic.html" target="main">Data.ConfigFile.Monadic</a></li><li class="module"><a href="Data-ConfigFile-Parser.html" target="main">Data.ConfigFile.Parser</a></li><li class="module"><a href="Data-ConfigFile-Types.html" target="main">Data.ConfigFile.Types</a></li></ul></div></body></html>
@@ -0,0 +1,12 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>ConfigFile-1.1.4: Configuration file reading &amp; writing</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">ConfigFile-1.1.4: Configuration file reading &amp; writing</p></div><div id="content"><div id="description"><h1>ConfigFile-1.1.4: Configuration file reading &amp; writing</h1><div class="doc"><p>Parser and writer for handling sectioned config files in
Haskell.</p><p>The ConfigFile module works with configuration files in a standard
format that is easy for the user to edit, easy for the programmer
to work with, yet remains powerful and flexible. It is inspired by,
and compatible with, Python's ConfigParser module. It uses files
that resemble Windows .INI-style files, but with numerous
improvements.</p><p>ConfigFile provides simple calls to both read and write config files.
It's possible to make a config file parsable by this module,
the Unix shell, and make.</p></div></div><div id="module-list"><p class="caption">Modules</p><ul><li><span id="control.n.1" class="module collapser" onclick="toggleSection('n.1')">Data</span><ul id="section.n.1" class="show"><li><span class="module"><span id="control.n.1.1" class="collapser" onclick="toggleSection('n.1.1')">&nbsp;</span><a href="Data-ConfigFile.html">Data.ConfigFile</a></span><ul id="section.n.1.1" class="show"><li><span class="module"><a href="Data-ConfigFile-Monadic.html">Data.ConfigFile.Monadic</a></span></li><li><span class="module"><a href="Data-ConfigFile-Parser.html">Data.ConfigFile.Parser</a></span></li><li><span class="module"><a href="Data-ConfigFile-Types.html">Data.ConfigFile.Types</a></span></li></ul></li></ul></li></ul></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.ConfigFile.Monadic</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body id="mini"><div id="module-header"><p class="caption">Data.ConfigFile.Monadic</p></div><div id="interface"><h1>Overview</h1><div class="top"><p class="src"><a href="Data-ConfigFile-Monadic.html#v:simpleAccess" target="main">simpleAccess</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile-Monadic.html#v:interpolatingAccess" target="main">interpolatingAccess</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile-Monadic.html#v:readfile" target="main">readfile</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile-Monadic.html#v:readhandle" target="main">readhandle</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile-Monadic.html#v:readstring" target="main">readstring</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile-Monadic.html#v:has_section" target="main">has_section</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile-Monadic.html#v:options" target="main">options</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile-Monadic.html#v:has_option" target="main">has_option</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile-Monadic.html#v:items" target="main">items</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile-Monadic.html#v:set" target="main">set</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile-Monadic.html#v:setshow" target="main">setshow</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile-Monadic.html#v:remove_option" target="main">remove_option</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile-Monadic.html#v:add_section" target="main">add_section</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile-Monadic.html#v:remove_section" target="main">remove_section</a></p></div></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.ConfigFile.Parser</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body id="mini"><div id="module-header"><p class="caption">Data.ConfigFile.Parser</p></div><div id="interface"><div class="top"><p class="src"><a href="Data-ConfigFile-Parser.html#v:parse_string" target="main">parse_string</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile-Parser.html#v:parse_file" target="main">parse_file</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile-Parser.html#v:parse_handle" target="main">parse_handle</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile-Parser.html#v:interpmain" target="main">interpmain</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a href="Data-ConfigFile-Parser.html#t:ParseOutput" target="main">ParseOutput</a></p></div></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.ConfigFile.Types</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body id="mini"><div id="module-header"><p class="caption">Data.ConfigFile.Types</p></div><div id="interface"><div class="top"><p class="src"><span class="keyword">type</span> <a href="Data-ConfigFile-Types.html#t:CPOptions" target="main">CPOptions</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a href="Data-ConfigFile-Types.html#t:CPData" target="main">CPData</a></p></div><div class="top"><p class="src"><span class="keyword">data</span> <a href="Data-ConfigFile-Types.html#t:CPErrorData" target="main">CPErrorData</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a href="Data-ConfigFile-Types.html#t:CPError" target="main">CPError</a></p></div><div class="top"><p class="src"><span class="keyword">data</span> <a href="Data-ConfigFile-Types.html#t:ConfigParser" target="main">ConfigParser</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a href="Data-ConfigFile-Types.html#t:SectionSpec" target="main">SectionSpec</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a href="Data-ConfigFile-Types.html#t:OptionSpec" target="main">OptionSpec</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a href="Data-ConfigFile-Types.html#t:ParseOutput" target="main">ParseOutput</a></p></div></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.ConfigFile</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body id="mini"><div id="module-header"><p class="caption">Data.ConfigFile</p></div><div id="interface"><h1>Introduction</h1><h2>Features</h2><h2>History</h2><h1>Configuration File Format</h1><h2>White Space</h2><h2>Comments</h2><h2>Case Sensitivity</h2><h2>Interpolation</h2><h1>Usage Examples</h1><h2>Non-Monadic Usage</h2><h2>Error Monad Usage</h2><h2>Combined Error/IO Monad Usage</h2><h1>Types</h1><div class="top"><p class="src"><span class="keyword">type</span> <a href="Data-ConfigFile.html#t:SectionSpec" target="main">SectionSpec</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a href="Data-ConfigFile.html#t:OptionSpec" target="main">OptionSpec</a></p></div><div class="top"><p class="src"><span class="keyword">data</span> <a href="Data-ConfigFile.html#t:ConfigParser" target="main">ConfigParser</a></p></div><div class="top"><p class="src"><span class="keyword">data</span> <a href="Data-ConfigFile.html#t:CPErrorData" target="main">CPErrorData</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a href="Data-ConfigFile.html#t:CPError" target="main">CPError</a></p></div><h1>Initialization</h1><div class="top"><p class="src"><a href="Data-ConfigFile.html#v:emptyCP" target="main">emptyCP</a></p></div><h1>Configuring the ConfigParser</h1><h2>Access Functions</h2><div class="top"><p class="src"><a href="Data-ConfigFile.html#v:simpleAccess" target="main">simpleAccess</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile.html#v:interpolatingAccess" target="main">interpolatingAccess</a></p></div><h1>Reading</h1><div class="top"><p class="src"><a href="Data-ConfigFile.html#v:readfile" target="main">readfile</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile.html#v:readhandle" target="main">readhandle</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile.html#v:readstring" target="main">readstring</a></p></div><h1>Accessing Data</h1><div class="top"><p class="src"><span class="keyword">class</span> <a href="Data-ConfigFile.html#t:Get_C" target="main">Get_C</a> a</p></div><div class="top"><p class="src"><a href="Data-ConfigFile.html#v:sections" target="main">sections</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile.html#v:has_section" target="main">has_section</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile.html#v:options" target="main">options</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile.html#v:has_option" target="main">has_option</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile.html#v:items" target="main">items</a></p></div><h1>Modifying Data</h1><div class="top"><p class="src"><a href="Data-ConfigFile.html#v:set" target="main">set</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile.html#v:setshow" target="main">setshow</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile.html#v:remove_option" target="main">remove_option</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile.html#v:add_section" target="main">add_section</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile.html#v:remove_section" target="main">remove_section</a></p></div><div class="top"><p class="src"><a href="Data-ConfigFile.html#v:merge" target="main">merge</a></p></div><h1>Output Data</h1><div class="top"><p class="src"><a href="Data-ConfigFile.html#v:to_string" target="main">to_string</a></p></div></div></body></html>
Binary file not shown.

After

Width:  |  Height:  |  Size: 56 B

@@ -0,0 +1,587 @@
/* @group Fundamentals */
* { margin: 0; padding: 0 }
/* Is this portable? */
html {
background-color: white;
width: 100%;
height: 100%;
}
body {
background: white;
color: black;
text-align: left;
min-height: 100%;
position: relative;
}
p {
margin: 0.8em 0;
}
ul, ol {
margin: 0.8em 0 0.8em 2em;
}
dl {
margin: 0.8em 0;
}
dt {
font-weight: bold;
}
dd {
margin-left: 2em;
}
a { text-decoration: none; }
a[href]:link { color: rgb(196,69,29); }
a[href]:visited { color: rgb(171,105,84); }
a[href]:hover { text-decoration:underline; }
/* @end */
/* @group Fonts & Sizes */
/* Basic technique & IE workarounds from YUI 3
For reasons, see:
http://yui.yahooapis.com/3.1.1/build/cssfonts/fonts.css
*/
body {
font:13px/1.4 sans-serif;
*font-size:small; /* for IE */
*font:x-small; /* for IE in quirks mode */
}
h1 { font-size: 146.5%; /* 19pt */ }
h2 { font-size: 131%; /* 17pt */ }
h3 { font-size: 116%; /* 15pt */ }
h4 { font-size: 100%; /* 13pt */ }
h5 { font-size: 100%; /* 13pt */ }
select, input, button, textarea {
font:99% sans-serif;
}
table {
font-size:inherit;
font:100%;
}
pre, code, kbd, samp, tt, .src {
font-family:monospace;
*font-size:108%;
line-height: 124%;
}
.links, .link {
font-size: 85%; /* 11pt */
}
#module-header .caption {
font-size: 182%; /* 24pt */
}
.info {
font-size: 85%; /* 11pt */
}
#table-of-contents, #synopsis {
/* font-size: 85%; /* 11pt */
}
/* @end */
/* @group Common */
.caption, h1, h2, h3, h4, h5, h6 {
font-weight: bold;
color: rgb(78,98,114);
margin: 0.8em 0 0.4em;
}
* + h1, * + h2, * + h3, * + h4, * + h5, * + h6 {
margin-top: 2em;
}
h1 + h2, h2 + h3, h3 + h4, h4 + h5, h5 + h6 {
margin-top: inherit;
}
ul.links {
list-style: none;
text-align: left;
float: right;
display: inline-table;
margin: 0 0 0 1em;
}
ul.links li {
display: inline;
border-left: 1px solid #d5d5d5;
white-space: nowrap;
padding: 0;
}
ul.links li a {
padding: 0.2em 0.5em;
}
.hide { display: none; }
.show { display: inherit; }
.clear { clear: both; }
.collapser {
background-image: url(minus.gif);
background-repeat: no-repeat;
}
.expander {
background-image: url(plus.gif);
background-repeat: no-repeat;
}
p.caption.collapser,
p.caption.expander {
background-position: 0 0.4em;
}
.collapser, .expander {
padding-left: 14px;
margin-left: -14px;
cursor: pointer;
}
pre {
padding: 0.25em;
margin: 0.8em 0;
background: rgb(229,237,244);
overflow: auto;
border-bottom: 0.25em solid white;
/* white border adds some space below the box to compensate
for visual extra space that paragraphs have between baseline
and the bounding box */
}
.src {
background: #f0f0f0;
padding: 0.2em 0.5em;
}
.keyword { font-weight: normal; }
.def { font-weight: bold; }
/* @end */
/* @group Page Structure */
#content {
margin: 0 auto;
padding: 0 2em 6em;
}
#package-header {
background: rgb(41,56,69);
border-top: 5px solid rgb(78,98,114);
color: #ddd;
padding: 0.2em;
position: relative;
text-align: left;
}
#package-header .caption {
background: url(hslogo-16.png) no-repeat 0em;
color: white;
margin: 0 2em;
font-weight: normal;
font-style: normal;
padding-left: 2em;
}
#package-header a:link, #package-header a:visited { color: white; }
#package-header a:hover { background: rgb(78,98,114); }
#module-header .caption {
color: rgb(78,98,114);
font-weight: bold;
border-bottom: 1px solid #ddd;
}
table.info {
float: right;
padding: 0.5em 1em;
border: 1px solid #ddd;
color: rgb(78,98,114);
background-color: #fff;
max-width: 40%;
border-spacing: 0;
position: relative;
top: -0.5em;
margin: 0 0 0 2em;
}
.info th {
padding: 0 1em 0 0;
}
div#style-menu-holder {
position: relative;
z-index: 2;
display: inline;
}
#style-menu {
position: absolute;
z-index: 1;
overflow: visible;
background: #374c5e;
margin: 0;
text-align: center;
right: 0;
padding: 0;
top: 1.25em;
}
#style-menu li {
display: list-item;
border-style: none;
margin: 0;
padding: 0;
color: #000;
list-style-type: none;
}
#style-menu li + li {
border-top: 1px solid #919191;
}
#style-menu a {
width: 6em;
padding: 3px;
display: block;
}
#footer {
background: #ddd;
border-top: 1px solid #aaa;
padding: 0.5em 0;
color: #666;
text-align: center;
position: absolute;
bottom: 0;
width: 100%;
height: 3em;
}
/* @end */
/* @group Front Matter */
#table-of-contents {
float: right;
clear: right;
background: #faf9dc;
border: 1px solid #d8d7ad;
padding: 0.5em 1em;
max-width: 20em;
margin: 0.5em 0 1em 1em;
}
#table-of-contents .caption {
text-align: center;
margin: 0;
}
#table-of-contents ul {
list-style: none;
margin: 0;
}
#table-of-contents ul ul {
margin-left: 2em;
}
#description .caption {
display: none;
}
#synopsis {
display: none;
}
.no-frame #synopsis {
display: block;
position: fixed;
right: 0;
height: 80%;
top: 10%;
padding: 0;
max-width: 75%;
}
#synopsis .caption {
float: left;
width: 29px;
color: rgba(255,255,255,0);
height: 110px;
margin: 0;
font-size: 1px;
padding: 0;
}
#synopsis p.caption.collapser {
background: url(synopsis.png) no-repeat -64px -8px;
}
#synopsis p.caption.expander {
background: url(synopsis.png) no-repeat 0px -8px;
}
#synopsis ul {
height: 100%;
overflow: auto;
padding: 0.5em;
margin: 0;
}
#synopsis ul ul {
overflow: hidden;
}
#synopsis ul,
#synopsis ul li.src {
background-color: #faf9dc;
white-space: nowrap;
list-style: none;
margin-left: 0;
}
/* @end */
/* @group Main Content */
#interface div.top { margin: 2em 0; }
#interface h1 + div.top,
#interface h2 + div.top,
#interface h3 + div.top,
#interface h4 + div.top,
#interface h5 + div.top {
margin-top: 1em;
}
#interface p.src .link {
float: right;
color: #919191;
border-left: 1px solid #919191;
background: #f0f0f0;
padding: 0 0.5em 0.2em;
margin: 0 -0.5em 0 0.5em;
}
#interface td.src .link {
float: right;
color: #919191;
border-left: 1px solid #919191;
background: #f0f0f0;
padding: 0 0.5em 0.2em;
margin: 0 -0.5em 0 0.5em;
}
#interface span.fixity {
color: #919191;
border-left: 1px solid #919191;
padding: 0.2em 0.5em 0.2em 0.5em;
margin: 0 -1em 0 1em;
}
#interface span.rightedge {
border-left: 1px solid #919191;
padding: 0.2em 0 0.2em 0;
margin: 0 0 0 1em;
}
#interface table { border-spacing: 2px; }
#interface td {
vertical-align: top;
padding-left: 0.5em;
}
#interface td.src {
white-space: nowrap;
}
#interface td.doc p {
margin: 0;
}
#interface td.doc p + p {
margin-top: 0.8em;
}
.subs dl {
margin: 0;
}
.subs dt {
float: left;
clear: left;
display: block;
margin: 1px 0;
}
.subs dd {
float: right;
width: 90%;
display: block;
padding-left: 0.5em;
margin-bottom: 0.5em;
}
.subs dd.empty {
display: none;
}
.subs dd p {
margin: 0;
}
/* Render short-style data instances */
.inst ul {
height: 100%;
padding: 0.5em;
margin: 0;
}
.inst, .inst li {
list-style: none;
margin-left: 1em;
}
.top p.src {
border-top: 1px solid #ccc;
}
.subs, .doc {
/* use this selector for one level of indent */
padding-left: 2em;
}
.warning {
color: red;
}
.arguments {
margin-top: -0.4em;
}
.arguments .caption {
display: none;
}
.fields { padding-left: 1em; }
.fields .caption { display: none; }
.fields p { margin: 0 0; }
/* this seems bulky to me
.methods, .constructors {
background: #f8f8f8;
border: 1px solid #eee;
}
*/
/* @end */
/* @group Auxillary Pages */
.extension-list {
list-style-type: none;
margin-left: 0;
}
#mini {
margin: 0 auto;
padding: 0 1em 1em;
}
#mini > * {
font-size: 93%; /* 12pt */
}
#mini #module-list .caption,
#mini #module-header .caption {
font-size: 125%; /* 15pt */
}
#mini #interface h1,
#mini #interface h2,
#mini #interface h3,
#mini #interface h4 {
font-size: 109%; /* 13pt */
margin: 1em 0 0;
}
#mini #interface .top,
#mini #interface .src {
margin: 0;
}
#mini #module-list ul {
list-style: none;
margin: 0;
}
#alphabet ul {
list-style: none;
padding: 0;
margin: 0.5em 0 0;
text-align: center;
}
#alphabet li {
display: inline;
margin: 0 0.25em;
}
#alphabet a {
font-weight: bold;
}
#index .caption,
#module-list .caption { font-size: 131%; /* 17pt */ }
#index table {
margin-left: 2em;
}
#index .src {
font-weight: bold;
}
#index .alt {
font-size: 77%; /* 10pt */
font-style: italic;
padding-left: 2em;
}
#index td + td {
padding-left: 1em;
}
#module-list ul {
list-style: none;
margin: 0 0 0 2em;
}
#module-list li {
clear: right;
}
#module-list span.collapser,
#module-list span.expander {
background-position: 0 0.3em;
}
#module-list .package {
float: right;
}
/* @end */
Binary file not shown.

After

Width:  |  Height:  |  Size: 59 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

@@ -0,0 +1,29 @@
HUnit is Copyright (c) Dean Herington, 2002, all rights reserved,
and is distributed as free software under the following license.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
- Redistributions of source code must retain the above copyright
notice, this list of conditions, and the following disclaimer.
- Redistributions in binary form must reproduce the above copyright
notice, this list of conditions, and the following disclaimer in the
documentation and/or other materials provided with the distribution.
- The names of the copyright holders may not be used to endorse or
promote products derived from this software without specific prior
written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS "AS IS" AND ANY
EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
@@ -0,0 +1,53 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Test.HUnit.Base</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Test-HUnit-Base.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">HUnit-1.2.5.2: A unit testing framework for Haskell</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Safe Haskell</th><td>Safe</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Test.HUnit.Base</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Declaring tests</a></li><li><a href="#g:2">Making assertions</a></li><li><a href="#g:3">Extending the assertion functionality</a></li><li><a href="#g:4">Test execution</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Basic definitions for the HUnit library.</p><p>This module contains what you need to create assertions and test cases and
combine them into test suites. </p><p>This module also provides infrastructure for
implementing test controllers (which are used to execute tests).
See <a href="Test-HUnit-Text.html">Test.HUnit.Text</a> for a great example of how to implement a test
controller.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">data</span> <a href="#t:Test">Test</a><ul class="subs"><li>= <a href="#v:TestCase">TestCase</a> <a href="Test-HUnit-Base.html#t:Assertion">Assertion</a></li><li>| <a href="#v:TestList">TestList</a> [<a href="Test-HUnit-Base.html#t:Test">Test</a>]</li><li>| <a href="#v:TestLabel">TestLabel</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> <a href="Test-HUnit-Base.html#t:Test">Test</a></li></ul></li><li class="src short"><a href="#v:-126--61--63-">(~=?)</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a) =&gt; a -&gt; a -&gt; <a href="Test-HUnit-Base.html#t:Test">Test</a></li><li class="src short"><a href="#v:-126--63--61-">(~?=)</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a) =&gt; a -&gt; a -&gt; <a href="Test-HUnit-Base.html#t:Test">Test</a></li><li class="src short"><a href="#v:-126-:">(~:)</a> :: <a href="Test-HUnit-Base.html#t:Testable">Testable</a> t =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; t -&gt; <a href="Test-HUnit-Base.html#t:Test">Test</a></li><li class="src short"><a href="#v:-126--63-">(~?)</a> :: <a href="Test-HUnit-Base.html#t:AssertionPredicable">AssertionPredicable</a> t =&gt; t -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="Test-HUnit-Base.html#t:Test">Test</a></li><li class="src short"><a href="#v:assertFailure">assertFailure</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="Test-HUnit-Base.html#t:Assertion">Assertion</a></li><li class="src short"><a href="#v:assertBool">assertBool</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a> -&gt; <a href="Test-HUnit-Base.html#t:Assertion">Assertion</a></li><li class="src short"><a href="#v:assertEqual">assertEqual</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; a -&gt; a -&gt; <a href="Test-HUnit-Base.html#t:Assertion">Assertion</a></li><li class="src short"><a href="#v:assertString">assertString</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="Test-HUnit-Base.html#t:Assertion">Assertion</a></li><li class="src short"><span class="keyword">type</span> <a href="#t:Assertion">Assertion</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:-64--61--63-">(@=?)</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a) =&gt; a -&gt; a -&gt; <a href="Test-HUnit-Base.html#t:Assertion">Assertion</a></li><li class="src short"><a href="#v:-64--63--61-">(@?=)</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a) =&gt; a -&gt; a -&gt; <a href="Test-HUnit-Base.html#t:Assertion">Assertion</a></li><li class="src short"><a href="#v:-64--63-">(@?)</a> :: <a href="Test-HUnit-Base.html#t:AssertionPredicable">AssertionPredicable</a> t =&gt; t -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="Test-HUnit-Base.html#t:Assertion">Assertion</a></li><li class="src short"><span class="keyword">class</span> <a href="#t:Assertable">Assertable</a> t <span class="keyword">where</span><ul clasLine truncated
value on the left-hand side, and the actual value on the right-hand
side).</p></div></div><div class="top"><p class="src"><a name="v:-126--63--61-" class="def">(~?=)</a> <span class="fixity">infix 1</span><span class="rightedge"></span></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">=&gt; a</td><td class="doc"><p>The actual value</p></td></tr><tr><td class="src">-&gt; a</td><td class="doc"><p>The expected value </p></td></tr><tr><td class="src">-&gt; <a href="Test-HUnit-Base.html#t:Test">Test</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Shorthand for a test case that asserts equality (with the actual
value on the left-hand side, and the expected value on the right-hand
side).</p></div></div><div class="top"><p class="src"><a name="v:-126-:" class="def">(~:)</a> :: <a href="Test-HUnit-Base.html#t:Testable">Testable</a> t =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; t -&gt; <a href="Test-HUnit-Base.html#t:Test">Test</a> <span class="fixity">infixr 0</span><span class="rightedge"></span></p><div class="doc"><p>Creates a test from the specified <code><a href="Test-HUnit-Base.html#t:Testable">Testable</a></code>, with the specified
label attached to it.</p><p>Since <code><a href="Test-HUnit-Base.html#t:Test">Test</a></code> is <code>Testable</code>, this can be used as a shorthand way of attaching
a <code><a href="Test-HUnit-Base.html#v:TestLabel">TestLabel</a></code> to one or more tests. </p></div></div><div class="top"><p class="src"><a name="v:-126--63-" class="def">(~?)</a> <span class="fixity">infix 1</span><span class="rightedge"></span></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="Test-HUnit-Base.html#t:AssertionPredicable">AssertionPredicable</a> t</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">=&gt; t</td><td class="doc"><p>A value of which the asserted condition is predicated</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>A message that is displayed on test failure</p></td></tr><tr><td class="src">-&gt; <a href="Test-HUnit-Base.html#t:Test">Test</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Creates a test case resulting from asserting the condition obtained
from the specified <code><a href="Test-HUnit-Base.html#t:AssertionPredicable">AssertionPredicable</a></code>.</p></div></div><h2 id="g:2">Making assertions</h2><div class="top"><p class="src"><a name="v:assertFailure" class="def">assertFailure</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>A message that is displayed with the assertion failure </p></td></tr><tr><td class="src">-&gt; <a href="Test-HUnit-Base.html#t:Assertion">Assertion</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Unconditionally signals that a failure has occured. All
other assertions can be expressed with the form:</p><pre> if conditionIsMet
then IO ()
else assertFailure msg
</pre></div></div><div class="top"><p class="src"><a name="v:assertBool" class="def">assertBool</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>The message that is displayed if the assertion fails</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></td><td class="doc"><p>The condition</p></td></tr><tr><td class="src">-&gt; <a href="Test-HUnit-Base.html#t:Assertion">Assertion</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Asserts that the specified condition holds.</p></div></div><div class="top"><p class="src"><a name="v:assertEqual" class="def">assertEqual</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">=&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>The message prefix </p></td></tr><tr><td class="src">-&gt; a</td><td class="doc"><p>The expected value </p></td></tr><tr><td class="src">-&gt; a</td><td class="doc"><p>The actual value</p></td></tr><tr><td class="src">-&gt; <a href="Test-HUnit-Base.html#t:Assertion">Assertion</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Asserts that the specified actual value is equal to the expected value.
The output message will contain the prefix, the expected value, and the
actual value.</p><p>If the prefix is the empty string (i.e., <code>&quot;&quot;</code>), then the prefix is omitted
and only the expected and actual values are output.</p></div></div><div class="top"><p class="src"><a name="v:assertString" class="def">assertString</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>The message that is displayed with the assertion failure </p></td></tr><tr><td class="src">-&gt; <a href="Test-HUnit-Base.html#t:Assertion">Assertion</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Signals an assertion failure if a non-empty message (i.e., a message
other than <code>&quot;&quot;</code>) is passed.</p></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:Assertion" class="def">Assertion</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>When an assertion is evaluated, it will output a message if and only if the
assertion fails. </p><p>Test cases are composed of a sequence of one or more assertions.</p></div></div><div class="top"><p class="src"><a name="v:-64--61--63-" class="def">(@=?)</a> <span class="fixity">infix 1</span><span class="rightedge"></span></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">=&gt; a</td><td class="doc"><p>The expected value</p></td></tr><tr><td class="src">-&gt; a</td><td class="doc"><p>The actual value</p></td></tr><tr><td class="src">-&gt; <a href="Test-HUnit-Base.html#t:Assertion">Assertion</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Asserts that the specified actual value is equal to the expected value
(with the expected value on the left-hand side).</p></div></div><div class="top"><p class="src"><a name="v:-64--63--61-" class="def">(@?=)</a> <span class="fixity">infix 1</span><span class="rightedge"></span></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">=&gt; a</td><td class="doc"><p>The actual value</p></td></tr><tr><td class="src">-&gt; a</td><td class="doc"><p>The expected value</p></td></tr><tr><td class="src">-&gt; <a href="Test-HUnit-Base.html#t:Assertion">Assertion</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Asserts that the specified actual value is equal to the expected value
(with the actual value on the left-hand side).</p></div></div><div class="top"><p class="src"><a name="v:-64--63-" class="def">(@?)</a> <span class="fixity">infix 1</span><span class="rightedge"></span></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="Test-HUnit-Base.html#t:AssertionPredicable">AssertionPredicable</a> t</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">=&gt; t</td><td class="doc"><p>A value of which the asserted condition is predicated</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>A message that is displayed if the assertion fails</p></td></tr><tr><td class="src">-&gt; <a href="Test-HUnit-Base.html#t:Assertion">Assertion</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Asserts that the condition obtained from the specified
<code><a href="Test-HUnit-Base.html#t:AssertionPredicable">AssertionPredicable</a></code> holds.</p></div></div><h2 id="g:3">Extending the assertion functionality</h2><div class="top"><p class="src"><span class="keyword">class</span> <a name="t:Assertable" class="def">Assertable</a> t <span class="keyword">where</span></p><div class="doc"><p>Allows the extension of the assertion mechanism.</p><p>Since an <code><a href="Test-HUnit-Base.html#t:Assertion">Assertion</a></code> can be a sequence of <code>Assertion</code>s and <code>IO</code> actions,
there is a fair amount of flexibility of what can be achieved. As a rule,
the resulting <code>Assertion</code> should be the body of a <code><a href="Test-HUnit-Base.html#v:TestCase">TestCase</a></code> or part of
a <code>TestCase</code>; it should not be used to assert multiple, independent
conditions.</p><p>If more complex arrangements of assertions are needed, <code><a href="Test-HUnit-Base.html#t:Test">Test</a></code>s and
<code><a href="Test-HUnit-Base.html#t:Testable">Testable</a></code> should be used.</p></div><div class="subs methods"><p class="caption">Methods</p><p class="src"><a name="v:assert" class="def">assert</a> :: t -&gt; <a href="Test-HUnit-Base.html#t:Assertion">Assertion</a></p></div><div class="subs instances"><p id="control.i:Assertable" class="caption collapser" onclick="toggleSection('i:Assertable')">Instances</p><div id="section.i:Assertable" class="show"><table><tr><td class="src"><a href="Test-HUnit-Base.html#t:Assertable">Assertable</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-HUnit-Base.html#t:Assertable">Assertable</a> ()</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-HUnit-Base.html#t:ListAssertable">ListAssertable</a> t =&gt; <a href="Test-HUnit-Base.html#t:Assertable">Assertable</a> [t]</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-HUnit-Base.html#t:Assertable">Assertable</a> t =&gt; <a href="Test-HUnit-Base.html#t:Assertable">Assertable</a> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> t)</td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">class</span> <a name="t:ListAssertable" class="def">ListAssertable</a> t <span class="keyword">where</span></p><div class="doc"><p>A specialized form of <code><a href="Test-HUnit-Base.html#t:Assertable">Assertable</a></code> to handle lists.</p></div><div class="subs methods"><p class="caption">Methods</p><p class="src"><a name="v:listAssert" class="def">listAssert</a> :: [t] -&gt; <a href="Test-HUnit-Base.html#t:Assertion">Assertion</a></p></div><div class="subs instances"><p id="control.i:ListAssertable" class="caption collapser" onclick="toggleSection('i:ListAssertable')">Instances</p><div id="section.i:ListAssertable" class="show"><table><tr><td class="src"><a href="Test-HUnit-Base.html#t:ListAssertable">ListAssertable</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Char.html#t:Char">Char</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:AssertionPredicate" class="def">AssertionPredicate</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>The result of an assertion that hasn't been evaluated yet.</p><p>Most test cases follow the following steps:</p><ol><li>Do some processing or an action.</li><li>Assert certain conditions.</li></ol><p>However, this flow is not always suitable. <code>AssertionPredicate</code> allows for
additional steps to be inserted without the initial action to be affected
by side effects. Additionally, clean-up can be done before the test case
has a chance to end. A potential work flow is:</p><ol><li>Write data to a file.</li><li>Read data from a file, evaluate conditions.</li><li>Clean up the file.</li><li>Assert that the side effects of the read operation meet certain conditions.</li><li>Assert that the conditions evaluated in step 2 are met.</li></ol></div></div><div class="top"><p class="src"><span class="keyword">class</span> <a name="t:AssertionPredicable" class="def">AssertionPredicable</a> t <span class="keyword">where</span></p><div class="doc"><p>Used to signify that a data type can be converted to an assertion
predicate.</p></div><div class="subs methods"><p class="caption">Methods</p><p class="src"><a name="v:assertionPredicate" class="def">assertionPredicate</a> :: t -&gt; <a href="Test-HUnit-Base.html#t:AssertionPredicate">AssertionPredicate</a></p></div><div class="subs instances"><p id="control.i:AssertionPredicable" class="caption collapser" onclick="toggleSection('i:AssertionPredicable')">Instances</p><div id="section.i:AssertionPredicable" class="show"><table><tr><td class="src"><a href="Test-HUnit-Base.html#t:AssertionPredicable">AssertionPredicable</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-HUnit-Base.html#t:AssertionPredicable">AssertionPredicable</a> t =&gt; <a href="Test-HUnit-Base.html#t:AssertionPredicable">AssertionPredicable</a> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> t)</td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">class</span> <a name="t:Testable" class="def">Testable</a> t <span class="keyword">where</span></p><div class="doc"><p>Provides a way to convert data into a <code>Test</code> or set of <code>Test</code>.</p></div><div class="subs methods"><p class="caption">Methods</p><p class="src"><a name="v:test" class="def">test</a> :: t -&gt; <a href="Test-HUnit-Base.html#t:Test">Test</a></p></div><div class="subs instances"><p id="control.i:Testable" class="caption collapser" onclick="toggleSection('i:Testable')">Instances</p><div id="section.i:Testable" class="show"><table><tr><td class="src"><a href="Test-HUnit-Base.html#t:Testable">Testable</a> <a href="Test-HUnit-Base.html#t:Test">Test</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-HUnit-Base.html#t:Testable">Testable</a> t =&gt; <a href="Test-HUnit-Base.html#t:Testable">Testable</a> [t]</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Test-HUnit-Base.html#t:Assertable">Assertable</a> t =&gt; <a href="Test-HUnit-Base.html#t:Testable">Testable</a> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> t)</td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><h2 id="g:4">Test execution</h2><div class="doc"><p>Note: the rest of the functionality in this module is intended for
implementors of test controllers. If you just want to run your tests cases,
simply use a test controller, such as the text-based controller in
<a href="Test-HUnit-Text.html">Test.HUnit.Text</a>.</p></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:State" class="def">State</a></p><div class="doc"><p>Keeps track of the remaining tests and the results of the performed tests.
As each test is performed, the path is removed and the counts are
updated as appropriate.</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:State" class="def">State</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div class="subs fields"><p class="caption">Fields</p><dl><dt class="src"><a name="v:path" class="def">path</a> :: <a href="Test-HUnit-Base.html#t:Path">Path</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:counts" class="def">counts</a> :: <a href="Test-HUnit-Base.html#t:Counts">Counts</a></dt><dd class="doc empty">&nbsp;</dd></dl><div class="clear"></div></div></td></tr></table></div><div class="subs instances"><p id="control.i:State" class="caption collapser" onclick="toggleSection('i:State')">Instances</p><div id="section.i:State" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> <a href="Test-HUnit-Base.html#t:State">State</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> <a href="Test-HUnit-Base.html#t:State">State</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="Test-HUnit-Base.html#t:State">State</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:Counts" class="def">Counts</a></p><div class="doc"><p>A data structure that hold the results of tests that have been performed
up until this point.</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:Counts" class="def">Counts</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div class="subs fields"><p class="caption">Fields</p><dl><dt class="src"><a name="v:cases" class="def">cases</a>, <a name="v:tried" class="def">tried</a>, <a name="v:errors" class="def">errors</a>, <a name="v:failures" class="def">failures</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></dt><dd class="doc empty">&nbsp;</dd></dl><div class="clear"></div></div></td></tr></table></div><div class="subs instances"><p id="control.i:Counts" class="caption collapser" onclick="toggleSection('i:Counts')">Instances</p><div id="section.i:Counts" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> <a href="Test-HUnit-Base.html#t:Counts">Counts</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> <a href="Test-HUnit-Base.html#t:Counts">Counts</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="Test-HUnit-Base.html#t:Counts">Counts</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:Path" class="def">Path</a> = [<a href="Test-HUnit-Base.html#t:Node">Node</a>]</p><div class="doc"><p>Uniquely describes the location of a test within a test hierarchy.
Node order is from test case to root.</p></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:Node" class="def">Node</a></p><div class="doc"><p>Composed into <code><a href="Test-HUnit-Base.html#t:Path">Path</a></code>s.</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:ListItem" class="def">ListItem</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a name="v:Label" class="def">Label</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="subs instances"><p id="control.i:Node" class="caption collapser" onclick="toggleSection('i:Node')">Instances</p><div id="section.i:Node" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> <a href="Test-HUnit-Base.html#t:Node">Node</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> <a href="Test-HUnit-Base.html#t:Node">Node</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="Test-HUnit-Base.html#t:Node">Node</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><a name="v:testCasePaths" class="def">testCasePaths</a> :: <a href="Test-HUnit-Base.html#t:Test">Test</a> -&gt; [<a href="Test-HUnit-Base.html#t:Path">Path</a>]</p><div class="doc"><p>Determines the paths for all <code><a href="Test-HUnit-Base.html#v:TestCase">TestCase</a></code>s in a tree of <code>Test</code>s.</p></div></div><div class="top"><p class="src"><a name="v:testCaseCount" class="def">testCaseCount</a> :: <a href="Test-HUnit-Base.html#t:Test">Test</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></p><div class="doc"><p>Counts the number of <code><a href="Test-HUnit-Base.html#v:TestCase">TestCase</a></code>s in a tree of <code>Test</code>s.</p></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:ReportStart" class="def">ReportStart</a> us = <a href="Test-HUnit-Base.html#t:State">State</a> -&gt; us -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> us</p><div class="doc"><p>Report generator for reporting the start of a test run.</p></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:ReportProblem" class="def">ReportProblem</a> us = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="Test-HUnit-Base.html#t:State">State</a> -&gt; us -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> us</p><div class="doc"><p>Report generator for reporting problems that have occurred during
a test run. Problems may be errors or assertion failures.</p></div></div><div class="top"><p class="src"><a name="v:performTest" class="def">performTest</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="Test-HUnit-Base.html#t:ReportStart">ReportStart</a> us</td><td class="doc"><p>report generator for the test run start </p></td></tr><tr><td class="src">-&gt; <a href="Test-HUnit-Base.html#t:ReportProblem">ReportProblem</a> us</td><td class="doc"><p>report generator for errors during the test run</p></td></tr><tr><td class="src">-&gt; <a href="Test-HUnit-Base.html#t:ReportProblem">ReportProblem</a> us</td><td class="doc"><p>report generator for assertion failures during the test run</p></td></tr><tr><td class="src">-&gt; us</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">-&gt; <a href="Test-HUnit-Base.html#t:Test">Test</a></td><td class="doc"><p>the test to be executed </p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="Test-HUnit-Base.html#t:Counts">Counts</a>, us)</td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Performs a test run with the specified report generators. </p><p>This handles the actual running of the tests. Most developers will want
to use <code>HUnit.Text.runTestTT</code> instead. A developer could use this function
to execute tests via another IO system, such as a GUI, or to output the
results in a different manner (e.g., upload XML-formatted results to a
webservice). </p><p>Note that the counts in a start report do not include the test case
being started, whereas the counts in a problem report do include the
test case just finished. The principle is that the counts are sampled
only between test case executions. As a result, the number of test
case successes always equals the difference of test cases tried and
the sum of test case errors and failures.</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,11 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Test.HUnit.Lang</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Test-HUnit-Lang.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">HUnit-1.2.5.2: A unit testing framework for Haskell</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Safe Haskell</th><td>Safe</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Test.HUnit.Lang</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Internals</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This module abstracts the differences between implementations of
Haskell (e.g., GHC, Hugs, and NHC).</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">type</span> <a href="#t:Assertion">Assertion</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:assertFailure">assertFailure</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="Test-HUnit-Lang.html#t:Assertion">Assertion</a></li><li class="src short"><a href="#v:performTestCase">performTestCase</a> :: <a href="Test-HUnit-Lang.html#t:Assertion">Assertion</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>))</li><li class="src short"><span class="keyword">data</span> <a href="#t:HUnitFailure">HUnitFailure</a> = <a href="#v:HUnitFailure">HUnitFailure</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:Assertion" class="def">Assertion</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>When an assertion is evaluated, it will output a message if and only if the
assertion fails. </p><p>Test cases are composed of a sequence of one or more assertions.</p></div></div><div class="top"><p class="src"><a name="v:assertFailure" class="def">assertFailure</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>A message that is displayed with the assertion failure </p></td></tr><tr><td class="src">-&gt; <a href="Test-HUnit-Lang.html#t:Assertion">Assertion</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Unconditionally signals that a failure has occured. All
other assertions can be expressed with the form:</p><pre> if conditionIsMet
then IO ()
else assertFailure msg
</pre></div></div><div class="top"><p class="src"><a name="v:performTestCase" class="def">performTestCase</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="Test-HUnit-Lang.html#t:Assertion">Assertion</a></td><td class="doc"><p>an assertion to be made during the test case run </p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>))</td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Performs a single test case. The meaning of the result is as follows:</p><dl><dt><code>Nothing</code></dt><dd>test case success<dl><dt><code>Just (True, msg)</code></dt><dd>test case failure with the given message</dd><dt><code>Just (False, msg)</code></dt><dd>test case error with the given message</dd></dl></dd></dl></div></div><h1 id="g:1">Internals</h1><div class="doc"><p><em>Note:</em> This is not part of the public API! It is exposed so that you can
tinker with the internals of HUnit, but do not expect it to be stable!</p></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:HUnitFailure" class="def">HUnitFailure</a></p><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:HUnitFailure" class="def">HUnitFailure</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="subs instances"><p id="control.i:HUnitFailure" class="caption collapser" onclick="toggleSection('i:HUnitFailure')">Instances</p><div id="section.i:HUnitFailure" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="Test-HUnit-Lang.html#t:HUnitFailure">HUnitFailure</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Control-Exception-Base.html#t:Exception">Exception</a> <a href="Test-HUnit-Lang.html#t:HUnitFailure">HUnitFailure</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,9 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Test.HUnit.Terminal</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Test-HUnit-Terminal.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">HUnit-1.2.5.2: A unit testing framework for Haskell</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Safe Haskell</th><td>Safe</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Test.HUnit.Terminal</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This module handles the complexities of writing information to the
terminal, including modifying text in place.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:terminalAppearance">terminalAppearance</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:terminalAppearance" class="def">terminalAppearance</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Simplifies the input string by interpreting <code>\r</code> and <code>\b</code> characters
specially so that the result string has the same final (or <em>terminal</em>,
pun intended) appearance as would the input string when written to a
terminal that overwrites character positions following carriage
returns and backspaces.</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,36 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Test.HUnit.Text</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Test-HUnit-Text.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">HUnit-1.2.5.2: A unit testing framework for Haskell</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Safe Haskell</th><td>Safe</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Test.HUnit.Text</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Text-based test controller for running HUnit tests and reporting
results as text, usually to a terminal.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">data</span> <a href="#t:PutText">PutText</a> st = <a href="#v:PutText">PutText</a> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a> -&gt; st -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> st) st</li><li class="src short"><a href="#v:putTextToHandle">putTextToHandle</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a> -&gt; <a href="Test-HUnit-Text.html#t:PutText">PutText</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></li><li class="src short"><a href="#v:putTextToShowS">putTextToShowS</a> :: <a href="Test-HUnit-Text.html#t:PutText">PutText</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:ShowS">ShowS</a></li><li class="src short"><a href="#v:runTestText">runTestText</a> :: <a href="Test-HUnit-Text.html#t:PutText">PutText</a> st -&gt; <a href="Test-HUnit-Base.html#t:Test">Test</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="Test-HUnit-Base.html#t:Counts">Counts</a>, st)</li><li class="src short"><a href="#v:showPath">showPath</a> :: <a href="Test-HUnit-Base.html#t:Path">Path</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:showCounts">showCounts</a> :: <a href="Test-HUnit-Base.html#t:Counts">Counts</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:runTestTT">runTestTT</a> :: <a href="Test-HUnit-Base.html#t:Test">Test</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="Test-HUnit-Base.html#t:Counts">Counts</a></li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:PutText" class="def">PutText</a> st</p><div class="doc"><p>As the general text-based test controller (<code><a href="Test-HUnit-Text.html#v:runTestText">runTestText</a></code>) executes a
test, it reports each test case start, error, and failure by
constructing a string and passing it to the function embodied in a
<code><a href="Test-HUnit-Text.html#t:PutText">PutText</a></code>. A report string is known as a &quot;line&quot;, although it includes
no line terminator; the function in a <code><a href="Test-HUnit-Text.html#t:PutText">PutText</a></code> is responsible for
terminating lines appropriately. Besides the line, the function
receives a flag indicating the intended &quot;persistence&quot; of the line:
<code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#v:True">True</a></code> indicates that the line should be part of the final overall
report; <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#v:False">False</a></code> indicates that the line merely indicates progress of
the test execution. Each progress line shows the current values of
the cumulative test execution counts; a final, persistent line shows
the final count values.</p><p>The <code><a href="Test-HUnit-Text.html#t:PutText">PutText</a></code> function is also passed, and returns, an arbitrary state
value (called <code>st</code> here). The initial state value is given in the
<code><a href="Test-HUnit-Text.html#t:PutText">PutText</a></code>; the final value is returned by <code><a href="Test-HUnit-Text.html#v:runTestText">runTestText</a></code>.</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:PutText" class="def">PutText</a> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a> -&gt; st -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> st) st</td><td class="doc empty">&nbsp;</td></tr></table></div></div><div class="top"><p class="src"><a name="v:putTextToHandle" class="def">putTextToHandle</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></td><td class="doc"><p>Write progress lines to handle? </p></td></tr><tr><td class="src">-&gt; <a href="Test-HUnit-Text.html#t:PutText">PutText</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Two reporting schemes are defined here. <code>putTextToHandle</code> writes
report lines to a given handle. <code><a href="Test-HUnit-Text.html#v:putTextToShowS">putTextToShowS</a></code> accumulates
persistent lines for return as a whole by <code><a href="Test-HUnit-Text.html#v:runTestText">runTestText</a></code>.</p><p><code>putTextToHandle</code> writes persistent lines to the given handle,
following each by a newline character. In addition, if the given flag
is <code>True</code>, it writes progress lines to the handle as well. A progress
line is written with no line termination, so that it can be
overwritten by the next report line. As overwriting involves writing
carriage return and blank characters, its proper effect is usually
only obtained on terminal devices.</p></div></div><div class="top"><p class="src"><a name="v:putTextToShowS" class="def">putTextToShowS</a> :: <a href="Test-HUnit-Text.html#t:PutText">PutText</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:ShowS">ShowS</a></p><div class="doc"><p>Accumulates persistent lines (dropping progess lines) for return by
<code><a href="Test-HUnit-Text.html#v:runTestText">runTestText</a></code>. The accumulated lines are represented by a
<code><code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:ShowS">ShowS</a></code> (<code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></code> -&gt; <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></code>)</code> function whose first argument is the
string to be appended to the accumulated report lines.</p></div></div><div class="top"><p class="src"><a name="v:runTestText" class="def">runTestText</a> :: <a href="Test-HUnit-Text.html#t:PutText">PutText</a> st -&gt; <a href="Test-HUnit-Base.html#t:Test">Test</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="Test-HUnit-Base.html#t:Counts">Counts</a>, st)</p><div class="doc"><p>Executes a test, processing each report line according to the given
reporting scheme. The reporting scheme's state is threaded through calls
to the reporting scheme's function and finally returned, along with final
count values.</p></div></div><div class="top"><p class="src"><a name="v:showPath" class="def">showPath</a> :: <a href="Test-HUnit-Base.html#t:Path">Path</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Converts a test case path to a string, separating adjacent elements by
the colon (':'). An element of the path is quoted (as with <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#v:show">show</a></code>) when
there is potential ambiguity.</p></div></div><div class="top"><p class="src"><a name="v:showCounts" class="def">showCounts</a> :: <a href="Test-HUnit-Base.html#t:Counts">Counts</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Converts test execution counts to a string.</p></div></div><div class="top"><p class="src"><a name="v:runTestTT" class="def">runTestTT</a> :: <a href="Test-HUnit-Base.html#t:Test">Test</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="Test-HUnit-Base.html#t:Counts">Counts</a></p><div class="doc"><p>Provides the &quot;standard&quot; text-based test controller. Reporting is made to
standard error, and progress reports are included. For possible
programmatic use, the final counts are returned.</p><p>The &quot;TT&quot; in the name suggests &quot;Text-based reporting to the Terminal&quot;.</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,37 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Test.HUnit</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Test-HUnit.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">HUnit-1.2.5.2: A unit testing framework for Haskell</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Safe Haskell</th><td>Safe</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Test.HUnit</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>HUnit is a unit testing framework for Haskell, inspired by the JUnit tool
for Java. This guide describes how to use HUnit, assuming you are familiar
with Haskell, though not necessarily with JUnit.</p><p>In the Haskell module where your tests will reside, import module
<code>Test.HUnit</code>:</p><pre> import Test.HUnit
</pre><p>Define test cases as appropriate:</p><pre> test1 = TestCase (assertEqual &quot;for (foo 3),&quot; (1,2) (foo 3))
test2 = TestCase (do (x,y) &lt;- partA 3
assertEqual &quot;for the first result of partA,&quot; 5 x
b &lt;- partB y
assertBool (&quot;(partB &quot; ++ show y ++ &quot;) failed&quot;) b)
</pre><p>Name the test cases and group them together:</p><pre> tests = TestList [TestLabel &quot;test1&quot; test1, TestLabel &quot;test2&quot; test2]
</pre><p>Run the tests as a group. At a Haskell interpreter prompt, apply the function
<code>runTestTT</code> to the collected tests. (The <em>TT</em> suggests <em>T</em>ext orientation
with output to the <em>T</em>erminal.)</p><pre> &gt; runTestTT tests
Cases: 2 Tried: 2 Errors: 0 Failures: 0
&gt;
</pre><p>If the tests are proving their worth, you might see:</p><pre> &gt; runTestTT tests
### Failure in: 0:test1
for (foo 3),
expected: (1,2)
but got: (1,3)
Cases: 2 Tried: 2 Errors: 0 Failures: 1
&gt;
</pre><p>You can specify tests even more succinctly using operators and overloaded
functions that HUnit provides:</p><pre> tests = test [ &quot;test1&quot; ~: &quot;(foo 3)&quot; ~: (1,2) ~=? (foo 3),
&quot;test2&quot; ~: do (x, y) &lt;- partA 3
assertEqual &quot;for the first result of partA,&quot; 5 x
partB y @? &quot;(partB &quot; ++ show y ++ &quot;) failed&quot; ]
</pre><p>Assuming the same test failures as before, you would see:</p><pre> &gt; runTestTT tests
### Failure in: 0:test1:(foo 3)
expected: (1,2)
but got: (1,3)
Cases: 2 Tried: 2 Errors: 0 Failures: 1
&gt;
</pre></div></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src">module <a href="Test-HUnit-Base.html">Test.HUnit.Base</a></p></div><div class="top"><p class="src">module <a href="Test-HUnit-Text.html">Test.HUnit.Text</a></p></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>HUnit-1.2.5.2: A unit testing framework for Haskell (Index)</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">HUnit-1.2.5.2: A unit testing framework for Haskell</p></div><div id="content"><div id="index"><p class="caption">Index</p><table><tr><td class="src">@=?</td><td class="module"><a href="Test-HUnit-Base.html#v:-64--61--63-">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">@?</td><td class="module"><a href="Test-HUnit-Base.html#v:-64--63-">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">@?=</td><td class="module"><a href="Test-HUnit-Base.html#v:-64--63--61-">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">assert</td><td class="module"><a href="Test-HUnit-Base.html#v:assert">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">Assertable</td><td class="module"><a href="Test-HUnit-Base.html#t:Assertable">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">assertBool</td><td class="module"><a href="Test-HUnit-Base.html#v:assertBool">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">assertEqual</td><td class="module"><a href="Test-HUnit-Base.html#v:assertEqual">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">assertFailure</td><td class="module"><a href="Test-HUnit-Lang.html#v:assertFailure">Test.HUnit.Lang</a>, <a href="Test-HUnit-Base.html#v:assertFailure">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">Assertion</td><td class="module"><a href="Test-HUnit-Lang.html#t:Assertion">Test.HUnit.Lang</a>, <a href="Test-HUnit-Base.html#t:Assertion">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">AssertionPredicable</td><td class="module"><a href="Test-HUnit-Base.html#t:AssertionPredicable">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">AssertionPredicate</td><td class="module"><a href="Test-HUnit-Base.html#t:AssertionPredicate">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">assertionPredicate</td><td class="module"><a href="Test-HUnit-Base.html#v:assertionPredicate">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">assertString</td><td class="module"><a href="Test-HUnit-Base.html#v:assertString">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">cases</td><td class="module"><a href="Test-HUnit-Base.html#v:cases">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">Counts</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Type/Class)</td><td class="module"><a href="Test-HUnit-Base.html#t:Counts">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="alt">2 (Data Constructor)</td><td class="module"><a href="Test-HUnit-Base.html#v:Counts">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">counts</td><td class="module"><a href="Test-HUnit-Base.html#v:counts">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">errors</td><td class="module"><a href="Test-HUnit-Base.html#v:errors">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">failures</td><td class="module"><a href="Test-HUnit-Base.html#v:failures">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">HUnitFailure</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Type/Class)</td><td class="module"><a href="Test-HUnit-Lang.html#t:HUnitFailure">Test.HUnit.Lang</a></td></tr><tr><td class="alt">2 (Data Constructor)</td><td class="module"><a href="Test-HUnit-Lang.html#v:HUnitFailure">Test.HUnit.Lang</a></td></tr><tr><td class="src">Label</td><td class="module"><a href="Test-HUnit-Base.html#v:Label">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">listAssert</td><td class="module"><a href="Test-HUnit-Base.html#v:listAssert">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">ListAssertable</td><td class="module"><a href="Test-HUnit-Base.html#t:ListAssertable">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">ListItem</td><td class="module"><a href="Test-HUnit-Base.html#v:ListItem">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">Node</td><td class="module"><a href="Test-HUnit-Base.html#t:Node">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">Path</td><td class="module"><a href="Test-HUnit-Base.html#t:Path">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">path</td><td class="module"><a href="Test-HUnit-Base.html#v:path">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">performTest</td><td class="module"><a href="Test-HUnit-Base.html#v:performTest">Test.HUnit.Base</a>, Test.HUnit</td></tr><tr><td class="src">performTestCase</td><td class="module"><a href="Test-HUnit-Lang.html#v:performTestCase">Test.HUnit.Lang</a></td></tr><tr><td class="src">PutText</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Type/Class)</td><td class="module"><a href="Test-HUnit-Text.html#t:PutText">Test.HUnit.Text</a>, Test.HUnit</td></tr><tr><td class="alt">2 (Data Constructor)</td><td class="module"><a href="Test-HUnit-Text.html#v:PutText">Test.HUnit.TeLine truncated
@@ -0,0 +1,30 @@
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>
<script src="haddock-util.js" type="text/javascript"></script>
<script type="text/javascript"><!--
/*
The synopsis frame needs to be updated using javascript, so we hide
it by default and only show it if javascript is enabled.
TODO: provide some means to disable it.
*/
function load() {
var d = document.getElementById("inner-fs");
d.rows = "50%,50%";
postReframe();
}
--></script>
</head>
<frameset id="outer-fs" cols="25%,75%" onload="load()">
<frameset id="inner-fs" rows="100%,0%">
<frame src="index-frames.html" name="modules" />
<frame src="" name="synopsis" />
</frameset>
<frame src="index.html" name="main" />
</frameset>
</html>
@@ -0,0 +1,344 @@
// Haddock JavaScript utilities
var rspace = /\s\s+/g,
rtrim = /^\s+|\s+$/g;
function spaced(s) { return (" " + s + " ").replace(rspace, " "); }
function trim(s) { return s.replace(rtrim, ""); }
function hasClass(elem, value) {
var className = spaced(elem.className || "");
return className.indexOf( " " + value + " " ) >= 0;
}
function addClass(elem, value) {
var className = spaced(elem.className || "");
if ( className.indexOf( " " + value + " " ) < 0 ) {
elem.className = trim(className + " " + value);
}
}
function removeClass(elem, value) {
var className = spaced(elem.className || "");
className = className.replace(" " + value + " ", " ");
elem.className = trim(className);
}
function toggleClass(elem, valueOn, valueOff, bool) {
if (bool == null) { bool = ! hasClass(elem, valueOn); }
if (bool) {
removeClass(elem, valueOff);
addClass(elem, valueOn);
}
else {
removeClass(elem, valueOn);
addClass(elem, valueOff);
}
return bool;
}
function makeClassToggle(valueOn, valueOff)
{
return function(elem, bool) {
return toggleClass(elem, valueOn, valueOff, bool);
}
}
toggleShow = makeClassToggle("show", "hide");
toggleCollapser = makeClassToggle("collapser", "expander");
function toggleSection(id)
{
var b = toggleShow(document.getElementById("section." + id));
toggleCollapser(document.getElementById("control." + id), b);
rememberCollapsed(id, b);
return b;
}
var collapsed = {};
function rememberCollapsed(id, b)
{
if(b)
delete collapsed[id]
else
collapsed[id] = null;
var sections = [];
for(var i in collapsed)
{
if(collapsed.hasOwnProperty(i))
sections.push(i);
}
// cookie specific to this page; don't use setCookie which sets path=/
document.cookie = "collapsed=" + escape(sections.join('+'));
}
function restoreCollapsed()
{
var cookie = getCookie("collapsed");
if(!cookie)
return;
var ids = cookie.split('+');
for(var i in ids)
{
if(document.getElementById("section." + ids[i]))
toggleSection(ids[i]);
}
}
function setCookie(name, value) {
document.cookie = name + "=" + escape(value) + ";path=/;";
}
function clearCookie(name) {
document.cookie = name + "=;path=/;expires=Thu, 01-Jan-1970 00:00:01 GMT;";
}
function getCookie(name) {
var nameEQ = name + "=";
var ca = document.cookie.split(';');
for(var i=0;i < ca.length;i++) {
var c = ca[i];
while (c.charAt(0)==' ') c = c.substring(1,c.length);
if (c.indexOf(nameEQ) == 0) {
return unescape(c.substring(nameEQ.length,c.length));
}
}
return null;
}
var max_results = 75; // 50 is not enough to search for map in the base libraries
var shown_range = null;
var last_search = null;
function quick_search()
{
perform_search(false);
}
function full_search()
{
perform_search(true);
}
function perform_search(full)
{
var text = document.getElementById("searchbox").value.toLowerCase();
if (text == last_search && !full) return;
last_search = text;
var table = document.getElementById("indexlist");
var status = document.getElementById("searchmsg");
var children = table.firstChild.childNodes;
// first figure out the first node with the prefix
var first = bisect(-1);
var last = (first == -1 ? -1 : bisect(1));
if (first == -1)
{
table.className = "";
status.innerHTML = "No results found, displaying all";
}
else if (first == 0 && last == children.length - 1)
{
table.className = "";
status.innerHTML = "";
}
else if (last - first >= max_results && !full)
{
table.className = "";
status.innerHTML = "More than " + max_results + ", press Search to display";
}
else
{
// decide what you need to clear/show
if (shown_range)
setclass(shown_range[0], shown_range[1], "indexrow");
setclass(first, last, "indexshow");
shown_range = [first, last];
table.className = "indexsearch";
status.innerHTML = "";
}
function setclass(first, last, status)
{
for (var i = first; i <= last; i++)
{
children[i].className = status;
}
}
// do a binary search, treating 0 as ...
// return either -1 (no 0's found) or location of most far match
function bisect(dir)
{
var first = 0, finish = children.length - 1;
var mid, success = false;
while (finish - first > 3)
{
mid = Math.floor((finish + first) / 2);
var i = checkitem(mid);
if (i == 0) i = dir;
if (i == -1)
finish = mid;
else
first = mid;
}
var a = (dir == 1 ? first : finish);
var b = (dir == 1 ? finish : first);
for (var i = b; i != a - dir; i -= dir)
{
if (checkitem(i) == 0) return i;
}
return -1;
}
// from an index, decide what the result is
// 0 = match, -1 is lower, 1 is higher
function checkitem(i)
{
var s = getitem(i).toLowerCase().substr(0, text.length);
if (s == text) return 0;
else return (s > text ? -1 : 1);
}
// from an index, get its string
// this abstracts over alternates
function getitem(i)
{
for ( ; i >= 0; i--)
{
var s = children[i].firstChild.firstChild.data;
if (s.indexOf(' ') == -1)
return s;
}
return ""; // should never be reached
}
}
function setSynopsis(filename) {
if (parent.window.synopsis) {
if (parent.window.synopsis.location.replace) {
// In Firefox this avoids adding the change to the history.
parent.window.synopsis.location.replace(filename);
} else {
parent.window.synopsis.location = filename;
}
}
}
function addMenuItem(html) {
var menu = document.getElementById("page-menu");
if (menu) {
var btn = menu.firstChild.cloneNode(false);
btn.innerHTML = html;
menu.appendChild(btn);
}
}
function adjustForFrames() {
var bodyCls;
if (parent.location.href == window.location.href) {
// not in frames, so add Frames button
addMenuItem("<a href='#' onclick='reframe();return true;'>Frames</a>");
bodyCls = "no-frame";
}
else {
bodyCls = "in-frame";
}
addClass(document.body, bodyCls);
}
function reframe() {
setCookie("haddock-reframe", document.URL);
window.location = "frames.html";
}
function postReframe() {
var s = getCookie("haddock-reframe");
if (s) {
parent.window.main.location = s;
clearCookie("haddock-reframe");
}
}
function styles() {
var i, a, es = document.getElementsByTagName("link"), rs = [];
for (i = 0; a = es[i]; i++) {
if(a.rel.indexOf("style") != -1 && a.title) {
rs.push(a);
}
}
return rs;
}
function addStyleMenu() {
var as = styles();
var i, a, btns = "";
for(i=0; a = as[i]; i++) {
btns += "<li><a href='#' onclick=\"setActiveStyleSheet('"
+ a.title + "'); return false;\">"
+ a.title + "</a></li>"
}
if (as.length > 1) {
var h = "<div id='style-menu-holder'>"
+ "<a href='#' onclick='styleMenu(); return false;'>Style &#9662;</a>"
+ "<ul id='style-menu' class='hide'>" + btns + "</ul>"
+ "</div>";
addMenuItem(h);
}
}
function setActiveStyleSheet(title) {
var as = styles();
var i, a, found;
for(i=0; a = as[i]; i++) {
a.disabled = true;
// need to do this always, some browsers are edge triggered
if(a.title == title) {
found = a;
}
}
if (found) {
found.disabled = false;
setCookie("haddock-style", title);
}
else {
as[0].disabled = false;
clearCookie("haddock-style");
}
styleMenu(false);
}
function resetStyle() {
var s = getCookie("haddock-style");
if (s) setActiveStyleSheet(s);
}
function styleMenu(show) {
var m = document.getElementById('style-menu');
if (m) toggleShow(m, show);
}
function pageLoad() {
addStyleMenu();
adjustForFrames();
resetStyle();
restoreCollapsed();
}
Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>HUnit-1.2.5.2: A unit testing framework for Haskell</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body id="mini"><div id="module-list"><p class="caption">Modules</p><ul><li class="module"><a href="Test-HUnit.html" target="main">Test.HUnit</a></li><li class="module"><a href="Test-HUnit-Base.html" target="main">Test.HUnit.Base</a></li><li class="module"><a href="Test-HUnit-Lang.html" target="main">Test.HUnit.Lang</a></li><li class="module"><a href="Test-HUnit-Terminal.html" target="main">Test.HUnit.Terminal</a></li><li class="module"><a href="Test-HUnit-Text.html" target="main">Test.HUnit.Text</a></li></ul></div></body></html>
@@ -0,0 +1,5 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>HUnit-1.2.5.2: A unit testing framework for Haskell</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">HUnit-1.2.5.2: A unit testing framework for Haskell</p></div><div id="content"><div id="description"><h1>HUnit-1.2.5.2: A unit testing framework for Haskell</h1><div class="doc"><p>HUnit is a unit testing framework for Haskell, inspired by the
JUnit tool for Java, see: <a href="http://www.junit.org">http://www.junit.org</a>.</p></div></div><div id="module-list"><p class="caption">Modules</p><ul><li><span id="control.n.1" class="module collapser" onclick="toggleSection('n.1')">Test</span><ul id="section.n.1" class="show"><li><span class="module"><span id="control.n.1.1" class="collapser" onclick="toggleSection('n.1.1')">&nbsp;</span><a href="Test-HUnit.html">Test.HUnit</a></span><ul id="section.n.1.1" class="show"><li><span class="module"><a href="Test-HUnit-Base.html">Test.HUnit.Base</a></span></li><li><span class="module"><a href="Test-HUnit-Lang.html">Test.HUnit.Lang</a></span></li><li><span class="module"><a href="Test-HUnit-Terminal.html">Test.HUnit.Terminal</a></span></li><li><span class="module"><a href="Test-HUnit-Text.html">Test.HUnit.Text</a></span></li></ul></li></ul></li></ul></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Test.HUnit.Base</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body id="mini"><div id="module-header"><p class="caption">Test.HUnit.Base</p></div><div id="interface"><h2>Declaring tests</h2><div class="top"><p class="src"><span class="keyword">data</span> <a href="Test-HUnit-Base.html#t:Test" target="main">Test</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Base.html#v:-126--61--63-" target="main">(~=?)</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Base.html#v:-126--63--61-" target="main">(~?=)</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Base.html#v:-126-:" target="main">(~:)</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Base.html#v:-126--63-" target="main">(~?)</a></p></div><h2>Making assertions</h2><div class="top"><p class="src"><a href="Test-HUnit-Base.html#v:assertFailure" target="main">assertFailure</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Base.html#v:assertBool" target="main">assertBool</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Base.html#v:assertEqual" target="main">assertEqual</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Base.html#v:assertString" target="main">assertString</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a href="Test-HUnit-Base.html#t:Assertion" target="main">Assertion</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Base.html#v:-64--61--63-" target="main">(@=?)</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Base.html#v:-64--63--61-" target="main">(@?=)</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Base.html#v:-64--63-" target="main">(@?)</a></p></div><h2>Extending the assertion functionality</h2><div class="top"><p class="src"><span class="keyword">class</span> <a href="Test-HUnit-Base.html#t:Assertable" target="main">Assertable</a> t</p></div><div class="top"><p class="src"><span class="keyword">class</span> <a href="Test-HUnit-Base.html#t:ListAssertable" target="main">ListAssertable</a> t</p></div><div class="top"><p class="src"><span class="keyword">type</span> <a href="Test-HUnit-Base.html#t:AssertionPredicate" target="main">AssertionPredicate</a></p></div><div class="top"><p class="src"><span class="keyword">class</span> <a href="Test-HUnit-Base.html#t:AssertionPredicable" target="main">AssertionPredicable</a> t</p></div><div class="top"><p class="src"><span class="keyword">class</span> <a href="Test-HUnit-Base.html#t:Testable" target="main">Testable</a> t</p></div><h2>Test execution</h2><div class="top"><p class="src"><span class="keyword">data</span> <a href="Test-HUnit-Base.html#t:State" target="main">State</a></p></div><div class="top"><p class="src"><span class="keyword">data</span> <a href="Test-HUnit-Base.html#t:Counts" target="main">Counts</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a href="Test-HUnit-Base.html#t:Path" target="main">Path</a></p></div><div class="top"><p class="src"><span class="keyword">data</span> <a href="Test-HUnit-Base.html#t:Node" target="main">Node</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Base.html#v:testCasePaths" target="main">testCasePaths</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Base.html#v:testCaseCount" target="main">testCaseCount</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a href="Test-HUnit-Base.html#t:ReportStart" target="main">ReportStart</a> us</p></div><div class="top"><p class="src"><span class="keyword">type</span> <a href="Test-HUnit-Base.html#t:ReportProblem" target="main">ReportProblem</a> us</p></div><div class="top"><p class="src"><a href="Test-HUnit-Base.html#v:performTest" target="main">performTest</a></p></div></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Test.HUnit.Lang</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body id="mini"><div id="module-header"><p class="caption">Test.HUnit.Lang</p></div><div id="interface"><div class="top"><p class="src"><span class="keyword">type</span> <a href="Test-HUnit-Lang.html#t:Assertion" target="main">Assertion</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Lang.html#v:assertFailure" target="main">assertFailure</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Lang.html#v:performTestCase" target="main">performTestCase</a></p></div><h1>Internals</h1><div class="top"><p class="src"><span class="keyword">data</span> <a href="Test-HUnit-Lang.html#t:HUnitFailure" target="main">HUnitFailure</a></p></div></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Test.HUnit.Terminal</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body id="mini"><div id="module-header"><p class="caption">Test.HUnit.Terminal</p></div><div id="interface"><div class="top"><p class="src"><a href="Test-HUnit-Terminal.html#v:terminalAppearance" target="main">terminalAppearance</a></p></div></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Test.HUnit.Text</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body id="mini"><div id="module-header"><p class="caption">Test.HUnit.Text</p></div><div id="interface"><div class="top"><p class="src"><span class="keyword">data</span> <a href="Test-HUnit-Text.html#t:PutText" target="main">PutText</a> st</p></div><div class="top"><p class="src"><a href="Test-HUnit-Text.html#v:putTextToHandle" target="main">putTextToHandle</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Text.html#v:putTextToShowS" target="main">putTextToShowS</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Text.html#v:runTestText" target="main">runTestText</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Text.html#v:showPath" target="main">showPath</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Text.html#v:showCounts" target="main">showCounts</a></p></div><div class="top"><p class="src"><a href="Test-HUnit-Text.html#v:runTestTT" target="main">runTestTT</a></p></div></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Test.HUnit</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body id="mini"><div id="module-header"><p class="caption">Test.HUnit</p></div><div id="interface"></div></body></html>
Binary file not shown.

After

Width:  |  Height:  |  Size: 56 B

@@ -0,0 +1,587 @@
/* @group Fundamentals */
* { margin: 0; padding: 0 }
/* Is this portable? */
html {
background-color: white;
width: 100%;
height: 100%;
}
body {
background: white;
color: black;
text-align: left;
min-height: 100%;
position: relative;
}
p {
margin: 0.8em 0;
}
ul, ol {
margin: 0.8em 0 0.8em 2em;
}
dl {
margin: 0.8em 0;
}
dt {
font-weight: bold;
}
dd {
margin-left: 2em;
}
a { text-decoration: none; }
a[href]:link { color: rgb(196,69,29); }
a[href]:visited { color: rgb(171,105,84); }
a[href]:hover { text-decoration:underline; }
/* @end */
/* @group Fonts & Sizes */
/* Basic technique & IE workarounds from YUI 3
For reasons, see:
http://yui.yahooapis.com/3.1.1/build/cssfonts/fonts.css
*/
body {
font:13px/1.4 sans-serif;
*font-size:small; /* for IE */
*font:x-small; /* for IE in quirks mode */
}
h1 { font-size: 146.5%; /* 19pt */ }
h2 { font-size: 131%; /* 17pt */ }
h3 { font-size: 116%; /* 15pt */ }
h4 { font-size: 100%; /* 13pt */ }
h5 { font-size: 100%; /* 13pt */ }
select, input, button, textarea {
font:99% sans-serif;
}
table {
font-size:inherit;
font:100%;
}
pre, code, kbd, samp, tt, .src {
font-family:monospace;
*font-size:108%;
line-height: 124%;
}
.links, .link {
font-size: 85%; /* 11pt */
}
#module-header .caption {
font-size: 182%; /* 24pt */
}
.info {
font-size: 85%; /* 11pt */
}
#table-of-contents, #synopsis {
/* font-size: 85%; /* 11pt */
}
/* @end */
/* @group Common */
.caption, h1, h2, h3, h4, h5, h6 {
font-weight: bold;
color: rgb(78,98,114);
margin: 0.8em 0 0.4em;
}
* + h1, * + h2, * + h3, * + h4, * + h5, * + h6 {
margin-top: 2em;
}
h1 + h2, h2 + h3, h3 + h4, h4 + h5, h5 + h6 {
margin-top: inherit;
}
ul.links {
list-style: none;
text-align: left;
float: right;
display: inline-table;
margin: 0 0 0 1em;
}
ul.links li {
display: inline;
border-left: 1px solid #d5d5d5;
white-space: nowrap;
padding: 0;
}
ul.links li a {
padding: 0.2em 0.5em;
}
.hide { display: none; }
.show { display: inherit; }
.clear { clear: both; }
.collapser {
background-image: url(minus.gif);
background-repeat: no-repeat;
}
.expander {
background-image: url(plus.gif);
background-repeat: no-repeat;
}
p.caption.collapser,
p.caption.expander {
background-position: 0 0.4em;
}
.collapser, .expander {
padding-left: 14px;
margin-left: -14px;
cursor: pointer;
}
pre {
padding: 0.25em;
margin: 0.8em 0;
background: rgb(229,237,244);
overflow: auto;
border-bottom: 0.25em solid white;
/* white border adds some space below the box to compensate
for visual extra space that paragraphs have between baseline
and the bounding box */
}
.src {
background: #f0f0f0;
padding: 0.2em 0.5em;
}
.keyword { font-weight: normal; }
.def { font-weight: bold; }
/* @end */
/* @group Page Structure */
#content {
margin: 0 auto;
padding: 0 2em 6em;
}
#package-header {
background: rgb(41,56,69);
border-top: 5px solid rgb(78,98,114);
color: #ddd;
padding: 0.2em;
position: relative;
text-align: left;
}
#package-header .caption {
background: url(hslogo-16.png) no-repeat 0em;
color: white;
margin: 0 2em;
font-weight: normal;
font-style: normal;
padding-left: 2em;
}
#package-header a:link, #package-header a:visited { color: white; }
#package-header a:hover { background: rgb(78,98,114); }
#module-header .caption {
color: rgb(78,98,114);
font-weight: bold;
border-bottom: 1px solid #ddd;
}
table.info {
float: right;
padding: 0.5em 1em;
border: 1px solid #ddd;
color: rgb(78,98,114);
background-color: #fff;
max-width: 40%;
border-spacing: 0;
position: relative;
top: -0.5em;
margin: 0 0 0 2em;
}
.info th {
padding: 0 1em 0 0;
}
div#style-menu-holder {
position: relative;
z-index: 2;
display: inline;
}
#style-menu {
position: absolute;
z-index: 1;
overflow: visible;
background: #374c5e;
margin: 0;
text-align: center;
right: 0;
padding: 0;
top: 1.25em;
}
#style-menu li {
display: list-item;
border-style: none;
margin: 0;
padding: 0;
color: #000;
list-style-type: none;
}
#style-menu li + li {
border-top: 1px solid #919191;
}
#style-menu a {
width: 6em;
padding: 3px;
display: block;
}
#footer {
background: #ddd;
border-top: 1px solid #aaa;
padding: 0.5em 0;
color: #666;
text-align: center;
position: absolute;
bottom: 0;
width: 100%;
height: 3em;
}
/* @end */
/* @group Front Matter */
#table-of-contents {
float: right;
clear: right;
background: #faf9dc;
border: 1px solid #d8d7ad;
padding: 0.5em 1em;
max-width: 20em;
margin: 0.5em 0 1em 1em;
}
#table-of-contents .caption {
text-align: center;
margin: 0;
}
#table-of-contents ul {
list-style: none;
margin: 0;
}
#table-of-contents ul ul {
margin-left: 2em;
}
#description .caption {
display: none;
}
#synopsis {
display: none;
}
.no-frame #synopsis {
display: block;
position: fixed;
right: 0;
height: 80%;
top: 10%;
padding: 0;
max-width: 75%;
}
#synopsis .caption {
float: left;
width: 29px;
color: rgba(255,255,255,0);
height: 110px;
margin: 0;
font-size: 1px;
padding: 0;
}
#synopsis p.caption.collapser {
background: url(synopsis.png) no-repeat -64px -8px;
}
#synopsis p.caption.expander {
background: url(synopsis.png) no-repeat 0px -8px;
}
#synopsis ul {
height: 100%;
overflow: auto;
padding: 0.5em;
margin: 0;
}
#synopsis ul ul {
overflow: hidden;
}
#synopsis ul,
#synopsis ul li.src {
background-color: #faf9dc;
white-space: nowrap;
list-style: none;
margin-left: 0;
}
/* @end */
/* @group Main Content */
#interface div.top { margin: 2em 0; }
#interface h1 + div.top,
#interface h2 + div.top,
#interface h3 + div.top,
#interface h4 + div.top,
#interface h5 + div.top {
margin-top: 1em;
}
#interface p.src .link {
float: right;
color: #919191;
border-left: 1px solid #919191;
background: #f0f0f0;
padding: 0 0.5em 0.2em;
margin: 0 -0.5em 0 0.5em;
}
#interface td.src .link {
float: right;
color: #919191;
border-left: 1px solid #919191;
background: #f0f0f0;
padding: 0 0.5em 0.2em;
margin: 0 -0.5em 0 0.5em;
}
#interface span.fixity {
color: #919191;
border-left: 1px solid #919191;
padding: 0.2em 0.5em 0.2em 0.5em;
margin: 0 -1em 0 1em;
}
#interface span.rightedge {
border-left: 1px solid #919191;
padding: 0.2em 0 0.2em 0;
margin: 0 0 0 1em;
}
#interface table { border-spacing: 2px; }
#interface td {
vertical-align: top;
padding-left: 0.5em;
}
#interface td.src {
white-space: nowrap;
}
#interface td.doc p {
margin: 0;
}
#interface td.doc p + p {
margin-top: 0.8em;
}
.subs dl {
margin: 0;
}
.subs dt {
float: left;
clear: left;
display: block;
margin: 1px 0;
}
.subs dd {
float: right;
width: 90%;
display: block;
padding-left: 0.5em;
margin-bottom: 0.5em;
}
.subs dd.empty {
display: none;
}
.subs dd p {
margin: 0;
}
/* Render short-style data instances */
.inst ul {
height: 100%;
padding: 0.5em;
margin: 0;
}
.inst, .inst li {
list-style: none;
margin-left: 1em;
}
.top p.src {
border-top: 1px solid #ccc;
}
.subs, .doc {
/* use this selector for one level of indent */
padding-left: 2em;
}
.warning {
color: red;
}
.arguments {
margin-top: -0.4em;
}
.arguments .caption {
display: none;
}
.fields { padding-left: 1em; }
.fields .caption { display: none; }
.fields p { margin: 0 0; }
/* this seems bulky to me
.methods, .constructors {
background: #f8f8f8;
border: 1px solid #eee;
}
*/
/* @end */
/* @group Auxillary Pages */
.extension-list {
list-style-type: none;
margin-left: 0;
}
#mini {
margin: 0 auto;
padding: 0 1em 1em;
}
#mini > * {
font-size: 93%; /* 12pt */
}
#mini #module-list .caption,
#mini #module-header .caption {
font-size: 125%; /* 15pt */
}
#mini #interface h1,
#mini #interface h2,
#mini #interface h3,
#mini #interface h4 {
font-size: 109%; /* 13pt */
margin: 1em 0 0;
}
#mini #interface .top,
#mini #interface .src {
margin: 0;
}
#mini #module-list ul {
list-style: none;
margin: 0;
}
#alphabet ul {
list-style: none;
padding: 0;
margin: 0.5em 0 0;
text-align: center;
}
#alphabet li {
display: inline;
margin: 0 0.25em;
}
#alphabet a {
font-weight: bold;
}
#index .caption,
#module-list .caption { font-size: 131%; /* 17pt */ }
#index table {
margin-left: 2em;
}
#index .src {
font-weight: bold;
}
#index .alt {
font-size: 77%; /* 10pt */
font-style: italic;
padding-left: 2em;
}
#index td + td {
padding-left: 1em;
}
#module-list ul {
list-style: none;
margin: 0 0 0 2em;
}
#module-list li {
clear: right;
}
#module-list span.collapser,
#module-list span.expander {
background-position: 0 0.3em;
}
#module-list .package {
float: right;
}
/* @end */
Binary file not shown.

After

Width:  |  Height:  |  Size: 59 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

@@ -0,0 +1,88 @@
Copyright (c) 2004 - 2011 John Goerzen
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice, this
list of conditions and the following disclaimer in the documentation and/or
other materials provided with the distribution.
* Neither the name of John Goerzen nor the names of its
contributors may be used to endorse or promote products derived from this
software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
============================================================================
Special Notes for Included Code
============================================================================
If you split out the parts originally from other authors, and use them
completely independently of the rest of the library, you may treat them
under the licenses shown below.
----------------------------------------------------
Portions of System.Path come from Volker Wysk's HsShellScript
library, version 2.1.0. That code is Copyright (c) 2004 Volker Wysk
and was originally licensed under the GNU LGPL 2.1. Volker gave permission
on Aug. 10, 2011, to John Goerzen to relicense it under the same 3-clause
BSD license as MissingH itself.
----------------------------------------------------
Data.Hash.CRC32.Posix is
(C) 2002 HardCore SoftWare, Doug Hoyte
and is "distributed under the terms of the GNU GPL." This license is
the same as the main license for MissingH.
The code was obtained from
http://cvs.sourceforge.net/viewcvs.py/haskell-libs/libs/crypto/crc32.hs
----------------------------------------------------
Data.Compression.Inflate is
Copyright 2004 Ian Lynagh <igloo@earth.li>
Licence: 3 clause BSD.
Debian GNU/Linux users may find the 3-clause BSD license at
/usr/share/common-licenses/BSD. Alternatively, you may find it at
3rd-party-licenses/BSD. Please note that the University of California
has no claim on this code; simply substitute Ian Lynagh for the
University wherever it may occur in that file.
The code was obtained from
http://urchin.earth.li/darcs/ian/inflate/Inflate.lhs
----------------------------------------------------
Data.Hash.MD5* is
Copyright 2001 Ian Lynagh <igloo@earth.li>
Licence: GPL or 3 clause BSD
Debian GNU/Linux users may find the 3-clause BSD license at
/usr/share/common-licenses/BSD. Alternatively, you may find it at
3rd-party-licenses/BSD. Please note that the University of California
has no claim on this code; simply substitute Ian Lynagh for the
University wherever it may occur in that file.
The code was obtained from
http://web.comlab.ox.ac.uk/oucl/work/ian.lynagh/md5/
----------------------------------------------------
System.Time.Utils.ParseDate is from
http://www.dtek.chalmers.se/~d00bring/projects.html
Copyright (c) Bj<F6>rn Bringert
License: GNU General Public License, version 2
I (John Goerzen) have modified only the module name and Haddock
comments at the top of it.
@@ -0,0 +1,6 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Control.Concurrent.Thread.Utils</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Control-Concurrent-Thread-Utils.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Control.Concurrent.Thread.Utils</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">I/O utilities</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This module provides various helpful utilities for dealing with threads.</p><p>Written by John Goerzen, jgoerzen@complete.org</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:runInThread">runInThread</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a -&gt; (a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> b) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Control-Concurrent.html#t:ThreadId">ThreadId</a></li></ul></div><div id="interface"><h1 id="g:1">I/O utilities</h1><div class="top"><p class="src"><a name="v:runInThread" class="def">runInThread</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a -&gt; (a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> b) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Control-Concurrent.html#t:ThreadId">ThreadId</a></p><div class="doc"><p>Takes a IO action and a function. The IO action will be called in a
separate thread. When it is completed, the specified function is called with
its result. This is a simple way of doing callbacks. </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,22 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.BinPacking</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-BinPacking.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2008-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.BinPacking</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Tools for packing into bins</p><p>Written by John Goerzen, jgoerzen@complete.org</p><p>This module is designed to solve this type of problem: Given a bunch of
objects of varying sizes, what is the best possible way to pack them into
fixed-size bins? This can be used, for instance, by the datapacker program
to pack files onto CDs or DVDs; by manufacturing environments to pack
physical items into physicl bins; etc.</p><p>A description of bin packing algorithms can be found at
<a href="http://en.wikipedia.org/wiki/Bin_packing_problem">http://en.wikipedia.org/wiki/Bin_packing_problem</a>.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">type</span> <a href="#t:BinPacker">BinPacker</a> = (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Num">Num</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> obj) =&gt; [size] -&gt; [(size, obj)] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> (<a href="Data-BinPacking.html#t:BinPackerError">BinPackerError</a> size obj) [[(size, obj)]]</li><li class="src short"><span class="keyword">data</span> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Num">Num</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> obj) =&gt; <a href="#t:BinPackerError">BinPackerError</a> size obj<ul class="subs"><li>= <a href="#v:BPTooFewBins">BPTooFewBins</a> [(size, obj)]</li><li>| <a href="#v:BPSizeTooLarge">BPSizeTooLarge</a> size (size, obj)</li><li>| <a href="#v:BPOther">BPOther</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li></ul></li><li class="src short"><a href="#v:packByOrder">packByOrder</a> :: <a href="Data-BinPacking.html#t:BinPacker">BinPacker</a></li><li class="src short"><a href="#v:packLargeFirst">packLargeFirst</a> :: <a href="Data-BinPacking.html#t:BinPacker">BinPacker</a></li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:BinPacker" class="def">BinPacker</a> = (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Num">Num</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> obj) =&gt; [size] -&gt; [(size, obj)] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> (<a href="Data-BinPacking.html#t:BinPackerError">BinPackerError</a> size obj) [[(size, obj)]]</p><div class="doc"><p>The primary type for bin-packing functions.</p><p>These functions take a list of size of bins. If every bin is the same size,
you can pass <code>repeat binSize</code> to pass an infinite list of bins if the
same size. Any surplus bins will simply be ignored. </p><pre>[size] is the sizes of bins
[(size, obj)] is the sizes and objects
result is Either error or results</pre></div></div><div class="top"><p class="src"><span class="keyword">data</span> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Num">Num</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> obj) =&gt; <a name="t:BinPackerError" class="def">BinPackerError</a> size obj</p><div class="doc"><p>Potential errors returned as Left values by <code><a href="Data-BinPacking.html#t:BinPacker">BinPacker</a></code> functions.
Calling <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#v:show">show</a></code> on this value will produce a nice error message suitable for
display. </p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:BPTooFewBins" class="def">BPTooFewBins</a> [(size, obj)]</td><td class="doc"><p>Ran out of bins; attached value is the list of objects that do not fit</p></td></tr><tr><td class="src"><a name="v:BPSizeTooLarge" class="def">BPSizeTooLarge</a> size (size, obj)</td><td class="doc"><p>Bin size1 exceeded by at least the given object and size</p></td></tr><tr><td class="src"><a name="v:BPOther" class="def">BPOther</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Other error</p></td></tr></table></div><div class="subs instances"><p id="control.i:BinPackerError" class="caption collapser" onclick="toggleSection('i:BinPackerError')">Instances</p><div id="section.i:BinPackerError" class="show"><table><tr><td class="src">(<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> obj, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Num">Num</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> obj) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> (<a href="Data-BinPacking.html#t:BinPackerError">BinPackerError</a> size obj)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">(<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Num">Num</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> obj, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> obj) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> (<a href="Data-BinPacking.html#t:BinPackerError">BinPackerError</a> size obj)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">(<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Num">Num</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> obj) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> (<a href="Data-BinPacking.html#t:BinPackerError">BinPackerError</a> size obj)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">(<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Num">Num</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> size, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> obj) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/transformers-0.4.2.0/Control-Monad-Trans-Error.html#t:Error">Error</a> (<a href="Data-BinPacking.html#t:BinPackerError">BinPackerError</a> size obj)</td><td class="doc"><p>Let us use this as part of the Either monad </p></td></tr></table></div></div></div><div class="top"><p class="src"><a name="v:packByOrder" class="def">packByOrder</a> :: <a href="Data-BinPacking.html#t:BinPacker">BinPacker</a></p><div class="doc"><p>Pack objects into bins, preserving order. Objects will be taken from the
input list one by one, and added to each bin until the bin is full. Work will
then proceed on the next bin. No attempt is made to optimize allocations to
bins. This is the simplest and most naive bin-packing algorithm, but
may not make very good use of bin space. </p></div></div><div class="top"><p class="src"><a name="v:packLargeFirst" class="def">packLargeFirst</a> :: <a href="Data-BinPacking.html#t:BinPacker">BinPacker</a></p><div class="doc"><p>Pack objects into bins. For each bin, start with the largest objects,
and keep packing the largest object from the remainder until no object can
be found to put in the bin. This is substantially more efficient than
<code><a href="Data-BinPacking.html#v:packByOrder">packByOrder</a></code>, but requires sorting the input. </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,5 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.Bits.Utils</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-Bits-Utils.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable to platforms with rawSystem</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.Bits.Utils</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Bit-related utilities</p><p>Written by John Goerzen, jgoerzen@complete.org</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:getBytes">getBytes</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integral">Integral</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Bounded">Bounded</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bits.html#t:Bits">Bits</a> a) =&gt; a -&gt; [a]</li><li class="src short"><a href="#v:fromBytes">fromBytes</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bits.html#t:Bits">Bits</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Num">Num</a> a) =&gt; [a] -&gt; a</li><li class="src short"><a href="#v:c2w8">c2w8</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Char.html#t:Char">Char</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word8">Word8</a></li><li class="src short"><a href="#v:s2w8">s2w8</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word8">Word8</a>]</li><li class="src short"><a href="#v:w82c">w82c</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word8">Word8</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Char.html#t:Char">Char</a></li><li class="src short"><a href="#v:w82s">w82s</a> :: [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word8">Word8</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:getBytes" class="def">getBytes</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integral">Integral</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Bounded">Bounded</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bits.html#t:Bits">Bits</a> a) =&gt; a -&gt; [a]</p><div class="doc"><p>Returns a list representing the bytes that comprise a data type.</p><p>Example:</p><pre>getBytes (0x12345678::Int) -&gt; [0x12, 0x34, 0x56, 0x78]</pre></div></div><div class="top"><p class="src"><a name="v:fromBytes" class="def">fromBytes</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bits.html#t:Bits">Bits</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Num">Num</a> a) =&gt; [a] -&gt; a</p><div class="doc"><p>The opposite of <code><a href="Data-Bits-Utils.html#v:getBytes">getBytes</a></code>, this function builds a number based on
its component bytes.</p><p>Results are undefined if any components of the input list are &gt; 0xff!</p></div></div><div class="top"><p class="src"><a name="v:c2w8" class="def">c2w8</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Char.html#t:Char">Char</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word8">Word8</a></p><div class="doc"><p>Converts a Char to a Word8. </p></div></div><div class="top"><p class="src"><a name="v:s2w8" class="def">s2w8</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word8">Word8</a>]</p><div class="doc"><p>Converts a String to a [Word8]. </p></div></div><div class="top"><p class="src"><a name="v:w82c" class="def">w82c</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word8">Word8</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Char.html#t:Char">Char</a></p><div class="doc"><p>Converts a Word8 to a Char. </p></div></div><div class="top"><p class="src"><a name="v:w82s" class="def">w82s</a> :: [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word8">Word8</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Converts a [Word8] to a String. </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,24 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.CSV</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-CSV.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2005-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.CSV</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Haskell Parsec parsers for comma-separated value (CSV) files.</p><p>Written by John Goerzen, jgoerzen@complete.org</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:csvFile">csvFile</a> :: CharParser st [[<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]]</li><li class="src short"><a href="#v:genCsvFile">genCsvFile</a> :: [[<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:csvFile" class="def">csvFile</a> :: CharParser st [[<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]]</p><div class="doc"><p>Parse a Comma-Separated Value (CSV) file. The return value is a list of
lines; each line is a list of cells; and each cell is a String.</p><p>Please note that CSV files may have a different number of cells on each line.
Also, it is impossible to distinguish a CSV line that has a call with no data
from a CSV line that has no cells.</p><p>Here are some examples:</p><pre>Input (literal strings) Parses As (Haskell String syntax)
-------------------------------- ---------------------------------
1,2,3 [[&quot;1&quot;, &quot;2&quot;, &quot;3&quot;]]
l1 [[&quot;l1&quot;], [&quot;l2&quot;]]
l2
(empty line) [[&quot;&quot;]]
NQ,&quot;Quoted&quot; [[&quot;NQ&quot;, &quot;Quoted&quot;]]
NQ,&quot;Embedded&quot;&quot;Quote&quot; [[&quot;NQ&quot;, &quot;Embedded\&quot;Quote&quot;]]</pre><p>To parse a String, you might use:</p><pre>import Text.ParserCombinators.Parsec
import Data.String.CSV
....
parse csvFile &quot;&quot; mystring</pre><p>To parse a file, you might instead use:</p><pre>do result &lt;- parseFromFile csvFile &quot;/path/to/file&quot;</pre><p>Please note that the result of parsing will be of type
(Either ParseError [[String]]). A Left result indicates an error.
For more details, see the Parsec information.</p></div></div><div class="top"><p class="src"><a name="v:genCsvFile" class="def">genCsvFile</a> :: [[<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Generate CSV data for a file. The resulting string can be
written out to disk directly. </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,6 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.Compression.Inflate</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-Compression-Inflate.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004 Ian Lynagh </td></tr><tr><th>License</th><td>3-clause BSD</td></tr><tr><th>Maintainer</th><td>Ian Lynagh, </td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.Compression.Inflate</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Maintainer : <a href="igloo@earth.li">igloo@earth.li</a>
Stability : provisional
Portability: portable</p><p>Inflate algorithm implementation</p><p>Copyright (C) 2004 Ian Lynagh</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:inflate_string">inflate_string</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:inflate_string_remainder">inflate_string_remainder</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</li><li class="src short"><a href="#v:inflate">inflate</a> :: [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a>] -&gt; (<a href="Data-Compression-Inflate.html#t:Output">Output</a>, [<a href="Data-Compression-Inflate.html#t:Bit">Bit</a>])</li><li class="src short"><span class="keyword">type</span> <a href="#t:Output">Output</a> = [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a>]</li><li class="src short"><span class="keyword">data</span> <a href="#t:Bit">Bit</a></li><li class="src short"><a href="#v:bits_to_word32">bits_to_word32</a> :: [<a href="Data-Compression-Inflate.html#t:Bit">Bit</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a></li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:inflate_string" class="def">inflate_string</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p></div><div class="top"><p class="src"><a name="v:inflate_string_remainder" class="def">inflate_string_remainder</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</p><div class="doc"><p>Returns (Data, Remainder)</p></div></div><div class="top"><p class="src"><a name="v:inflate" class="def">inflate</a> :: [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a>] -&gt; (<a href="Data-Compression-Inflate.html#t:Output">Output</a>, [<a href="Data-Compression-Inflate.html#t:Bit">Bit</a>])</p></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:Output" class="def">Output</a> = [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a>]</p></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:Bit" class="def">Bit</a></p><div class="subs instances"><p id="control.i:Bit" class="caption collapser" onclick="toggleSection('i:Bit')">Instances</p><div id="section.i:Bit" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> <a href="Data-Compression-Inflate.html#t:Bit">Bit</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="Data-Compression-Inflate.html#t:Bit">Bit</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><a name="v:bits_to_word32" class="def">bits_to_word32</a> :: [<a href="Data-Compression-Inflate.html#t:Bit">Bit</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a></p></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,7 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.Either.Utils</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-Either-Utils.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.Either.Utils</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Utilities for working with the Either data type</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:maybeToEither">maybeToEither</a> :: MonadError e m =&gt; e -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> a -&gt; m a</li><li class="src short"><a href="#v:forceEither">forceEither</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> e =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> e a -&gt; a</li><li class="src short"><a href="#v:forceEitherMsg">forceEitherMsg</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> e =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> e a -&gt; a</li><li class="src short"><a href="#v:eitherToMonadError">eitherToMonadError</a> :: MonadError e m =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> e a -&gt; m a</li><li class="src short"><a href="#v:fromLeft">fromLeft</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> a b -&gt; a</li><li class="src short"><a href="#v:fromRight">fromRight</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> a b -&gt; b</li><li class="src short"><a href="#v:fromEither">fromEither</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> a a -&gt; a</li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:maybeToEither" class="def">maybeToEither</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: MonadError e m</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">=&gt; e</td><td class="doc"><p>(Left e) will be returned if the Maybe value is Nothing</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> a</td><td class="doc"><p>(Right a) will be returned if this is (Just a)</p></td></tr><tr><td class="src">-&gt; m a</td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Converts a Maybe value to an Either value, using the supplied parameter
as the Left value if the Maybe is Nothing.</p><p>This function can be interpreted as:</p><pre>maybeToEither :: e -&gt; Maybe a -&gt; Either e a</pre><p>Its definition is given as it is so that it can be used in the Error and related monads.</p></div></div><div class="top"><p class="src"><a name="v:forceEither" class="def">forceEither</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> e =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> e a -&gt; a</p><div class="doc"><p>Pulls a <a href="Right.html">Right</a> value out of an Either value. If the Either value is
Left, raises an exception with &quot;error&quot;. </p></div></div><div class="top"><p class="src"><a name="v:forceEitherMsg" class="def">forceEitherMsg</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> e =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> e a -&gt; a</p><div class="doc"><p>Like <code><a href="Data-Either-Utils.html#v:forceEither">forceEither</a></code>, but can raise a specific message with the error. </p></div></div><div class="top"><p class="src"><a name="v:eitherToMonadError" class="def">eitherToMonadError</a> :: MonadError e m =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> e a -&gt; m a</p><div class="doc"><p>Takes an either and transforms it into something of the more generic
MonadError class. </p></div></div><div class="top"><p class="src"><a name="v:fromLeft" class="def">fromLeft</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> a b -&gt; a</p><div class="doc"><p>Take a Left to a value, crashes on a Right</p></div></div><div class="top"><p class="src"><a name="v:fromRight" class="def">fromRight</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> a b -&gt; b</p><div class="doc"><p>Take a Right to a value, crashes on a Left</p></div></div><div class="top"><p class="src"><a name="v:fromEither" class="def">fromEither</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> a a -&gt; a</p><div class="doc"><p>Take an Either, and return the value inside it</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,6 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.Hash.CRC32.GZip</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-Hash-CRC32-GZip.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.Hash.CRC32.GZip</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>CRC32 checksumming using the GZIP/PKZIP algorithm as used in both
ISO 3309 and section 8.1.1.6.2 of ITU-T V.42 and referenced in
RFC1952.</p></div></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:update_crc" class="def">update_crc</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Char.html#t:Char">Char</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a></p></div><div class="top"><p class="src"><a name="v:update_crc_list" class="def">update_crc_list</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Char.html#t:Char">Char</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a></p></div><div class="top"><p class="src"><a name="v:calc_crc32" class="def">calc_crc32</a> :: [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Char.html#t:Char">Char</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a></p></div><div class="top"><p class="src"><a name="v:gzipcrctab" class="def">gzipcrctab</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/array-0.5.1.0/Data-Array.html#t:Array">Array</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a></p></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,5 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.Hash.CRC32.Posix</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-Hash-CRC32-Posix.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2002 HardCore SoftWare, Doug Hoyte</td></tr><tr><th>License</th><td>GNU GPL</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.Hash.CRC32.Posix</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>CRC32 checksumming using POSIX 1003.2-1992 algorithm for the polynomial { 32 26
23 22 16 12 11 10 8 7 5 4 2 1 }, also defined in ISO 8802-3: 1989.</p><p>Copyright (c) 2002 HardCore SoftWare, Doug Hoyte</p></div></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:iter_crc32" class="def">iter_crc32</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Char.html#t:Char">Char</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a></p></div><div class="top"><p class="src"><a name="v:calc_crc32" class="def">calc_crc32</a> :: [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Char.html#t:Char">Char</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a></p></div><div class="top"><p class="src"><a name="v:crc32" class="def">crc32</a> :: [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Char.html#t:Char">Char</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a></p></div><div class="top"><p class="src"><a name="v:crctab" class="def">crctab</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/array-0.5.1.0/Data-Array.html#t:Array">Array</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a></p></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.Hash.MD5.Zord64_HARD</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-Hash-MD5-Zord64_HARD.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.Hash.MD5.Zord64_HARD</p></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:Zord64" class="def">Zord64</a></p><div class="subs instances"><p id="control.i:Zord64" class="caption collapser" onclick="toggleSection('i:Zord64')">Instances</p><div id="section.i:Zord64" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Bounded">Bounded</a> <a href="Data-Hash-MD5-Zord64_HARD.html#t:Zord64">Zord64</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Enum">Enum</a> <a href="Data-Hash-MD5-Zord64_HARD.html#t:Zord64">Zord64</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> <a href="Data-Hash-MD5-Zord64_HARD.html#t:Zord64">Zord64</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integral">Integral</a> <a href="Data-Hash-MD5-Zord64_HARD.html#t:Zord64">Zord64</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Num">Num</a> <a href="Data-Hash-MD5-Zord64_HARD.html#t:Zord64">Zord64</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> <a href="Data-Hash-MD5-Zord64_HARD.html#t:Zord64">Zord64</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> <a href="Data-Hash-MD5-Zord64_HARD.html#t:Zord64">Zord64</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Real">Real</a> <a href="Data-Hash-MD5-Zord64_HARD.html#t:Zord64">Zord64</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="Data-Hash-MD5-Zord64_HARD.html#t:Zord64">Zord64</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bits.html#t:Bits">Bits</a> <a href="Data-Hash-MD5-Zord64_HARD.html#t:Zord64">Zord64</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,5 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.Hash.MD5</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-Hash-MD5.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2001 Ian Lynagh </td></tr><tr><th>License</th><td>Either BSD or GPL</td></tr><tr><th>Maintainer</th><td>Ian Lynagh &lt;igloo@earth.li&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.Hash.MD5</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Generation of MD5sums</p><p>Written by Ian Lynagh, igloo@earth.li</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:md5">md5</a> :: <a href="Data-Hash-MD5.html#t:MD5">MD5</a> a =&gt; a -&gt; <a href="Data-Hash-MD5.html#t:ABCD">ABCD</a></li><li class="src short"><a href="#v:md5s">md5s</a> :: <a href="Data-Hash-MD5.html#t:MD5">MD5</a> a =&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:md5i">md5i</a> :: <a href="Data-Hash-MD5.html#t:MD5">MD5</a> a =&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a></li><li class="src short"><span class="keyword">class</span> <a href="#t:MD5">MD5</a> a <span class="keyword">where</span><ul class="subs"><li><a href="#v:get_next">get_next</a> :: a -&gt; ([<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a>], <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a>, a)</li><li><a href="#v:len_pad">len_pad</a> :: <a href="Data-Hash-MD5.html#t:Zord64">Zord64</a> -&gt; a -&gt; a</li><li><a href="#v:finished">finished</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li></ul></li><li class="src short"><span class="keyword">newtype</span> <a href="#t:ABCD">ABCD</a> = <a href="#v:ABCD">ABCD</a> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a>)</li><li class="src short"><span class="keyword">type</span> <a href="#t:Zord64">Zord64</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word64">Word64</a></li><li class="src short"><span class="keyword">newtype</span> <a href="#t:Str">Str</a> = <a href="#v:Str">Str</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><span class="keyword">newtype</span> <a href="#t:BoolList">BoolList</a> = <a href="#v:BoolList">BoolList</a> [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a>]</li><li class="src short"><span class="keyword">newtype</span> <a href="#t:WordList">WordList</a> = <a href="#v:WordList">WordList</a> ([<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a>], <a href="Data-Hash-MD5.html#t:Zord64">Zord64</a>)</li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:md5" class="def">md5</a> :: <a href="Data-Hash-MD5.html#t:MD5">MD5</a> a =&gt; a -&gt; <a href="Data-Hash-MD5.html#t:ABCD">ABCD</a></p><div class="doc"><p>The simplest function, gives you the MD5 of a string as 4-tuple of
32bit words. </p></div></div><div class="top"><p class="src"><a name="v:md5s" class="def">md5s</a> :: <a href="Data-Hash-MD5.html#t:MD5">MD5</a> a =&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Returns a hex number ala the md5sum program. </p></div></div><div class="top"><p class="src"><a name="v:md5i" class="def">md5i</a> :: <a href="Data-Hash-MD5.html#t:MD5">MD5</a> a =&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a></p><div class="doc"><p>Returns an integer equivalent to hex number from <code><a href="Data-Hash-MD5.html#v:md5s">md5s</a></code>. </p></div></div><div class="top"><p class="src"><span class="keyword">class</span> <a name="t:MD5" class="def">MD5</a> a <span class="keyword">where</span></p><div class="doc"><p>Anything we want to work out the MD5 of must be an instance of class MD5</p></div><div class="subs methods"><p class="caption">Methods</p><p class="src"><a name="v:get_next" class="def">get_next</a> :: a -&gt; ([<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a>], <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a>, a)</p><p class="src"><a name="v:len_pad" class="def">len_pad</a> :: <a href="Data-Hash-MD5.html#t:Zord64">Zord64</a> -&gt; a -&gt; a</p><p class="src"><a name="v:finished" class="def">finished</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p></div><div class="subs instances"><p id="control.i:MD5" class="caption collapser" onclick="toggleSection('i:MD5')">Instances</p><div id="section.i:MD5" class="show"><table><tr><td class="src"><a href="Data-Hash-MD5.html#t:MD5">MD5</a> <a href="Data-Hash-MD5.html#t:WordList">WordList</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Data-Hash-MD5.html#t:MD5">MD5</a> <a href="Data-Hash-MD5.html#t:BoolList">BoolList</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Data-Hash-MD5.html#t:MD5">MD5</a> <a href="Data-Hash-MD5.html#t:Str">Str</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">newtype</span> <a name="t:ABCD" class="def">ABCD</a></p><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:ABCD" class="def">ABCD</a> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a>)</td><td class="doc empty">&nbsp;</td></tr></table></div><div class="subs instances"><p id="control.i:ABCD" class="caption collapser" onclick="toggleSection('i:ABCD')">Instances</p><div id="section.i:ABCD" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> <a href="Data-Hash-MD5.html#t:ABCD">ABCD</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Num">Num</a> <a href="Data-Hash-MD5.html#t:ABCD">ABCD</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="Data-Hash-MD5.html#t:ABCD">ABCD</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:Zord64" class="def">Zord64</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word64">Word64</a></p></div><div class="top"><p class="src"><span class="keyword">newtype</span> <a name="t:Str" class="def">Str</a></p><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:Str" class="def">Str</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="subs instances"><p id="control.i:Str" class="caption collapser" onclick="toggleSection('i:Str')">Instances</p><div id="section.i:Str" class="show"><table><tr><td class="src"><a href="Data-Hash-MD5.html#t:MD5">MD5</a> <a href="Data-Hash-MD5.html#t:Str">Str</a></td><td class="doc empty">&Line truncated
@@ -0,0 +1,78 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.List.Utils</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-List-Utils.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.List.Utils</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Merging</a></li><li><a href="#g:2">Tests</a></li><li><a href="#g:3">Association List Utilities</a><ul><li><a href="#g:4">Association List Conversions</a></li></ul></li><li><a href="#g:5">Conversions</a><ul><li><a href="#g:6">Advanced Conversions</a></li></ul></li><li><a href="#g:7">Fixed-Width and State Monad Utilities</a></li><li><a href="#g:8">Miscellaneous</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This module provides various helpful utilities for dealing with lists.</p><p>Written by John Goerzen, jgoerzen@complete.org</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:merge">merge</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> a =&gt; [a] -&gt; [a] -&gt; [a]</li><li class="src short"><a href="#v:mergeBy">mergeBy</a> :: (a -&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ordering">Ordering</a>) -&gt; [a] -&gt; [a] -&gt; [a]</li><li class="src short"><a href="#v:startswith">startswith</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li class="src short"><a href="#v:endswith">endswith</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li class="src short"><a href="#v:contains">contains</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li class="src short"><a href="#v:hasAny">hasAny</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li class="src short"><a href="#v:addToAL">addToAL</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> key =&gt; [(key, elt)] -&gt; key -&gt; elt -&gt; [(key, elt)]</li><li class="src short"><a href="#v:delFromAL">delFromAL</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> key =&gt; [(key, a)] -&gt; key -&gt; [(key, a)]</li><li class="src short"><a href="#v:flipAL">flipAL</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> key, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> val) =&gt; [(key, val)] -&gt; [(val, [key])]</li><li class="src short"><a href="#v:keysAL">keysAL</a> :: [(key, a)] -&gt; [key]</li><li class="src short"><a href="#v:valuesAL">valuesAL</a> :: [(a, value)] -&gt; [value]</li><li class="src short"><a href="#v:hasKeyAL">hasKeyAL</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; a -&gt; [(a, b)] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li class="src short"><a href="#v:strFromAL">strFromAL</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> b) =&gt; [(a, b)] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/Line truncated
merge (sort xs) (sort ys) == sort (xs ++ ys)
where types = xs :: [Int]</p></div></div><div class="top"><p class="src"><a name="v:mergeBy" class="def">mergeBy</a> :: (a -&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ordering">Ordering</a>) -&gt; [a] -&gt; [a] -&gt; [a]</p><div class="doc"><p>Merge two sorted lists using into a single, sorted whole,
allowing the programmer to specify the comparison function.</p><p>QuickCheck test property:</p><p>prop_mergeBy xs ys =
mergeBy cmp (sortBy cmp xs) (sortBy cmp ys) == sortBy cmp (xs ++ ys)
where types = xs :: [ (Int, Int) ]
cmp (x1,_) (x2,_) = compare x1 x2</p></div></div><h1 id="g:2">Tests</h1><div class="top"><p class="src"><a name="v:startswith" class="def">startswith</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>Returns true if the given list starts with the specified elements;
false otherwise. (This is an alias for &quot;Data.List.isPrefixOf&quot;.)</p><p>Example:</p><pre>startswith &quot;He&quot; &quot;Hello&quot; -&gt; True</pre></div></div><div class="top"><p class="src"><a name="v:endswith" class="def">endswith</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>Returns true if the given list ends with the specified elements;
false otherwise. (This is an alias for &quot;Data.List.isSuffixOf&quot;.)</p><p>Example:</p><pre>endswith &quot;lo&quot; &quot;Hello&quot; -&gt; True</pre></div></div><div class="top"><p class="src"><a name="v:contains" class="def">contains</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><div class="warning"><p>Deprecated: Use Data.List.isInfixOf, will be removed in MissingH 1.1.0</p></div><p>Returns true if the given parameter is a sublist of the given list;
false otherwise.</p><p>Example:</p><pre>contains &quot;Haskell&quot; &quot;I really like Haskell.&quot; -&gt; True
contains &quot;Haskell&quot; &quot;OCaml is great.&quot; -&gt; False</pre><p>This function was submitted to GHC and was applied as
<code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-OldList.html#v:isInfixOf">isInfixOf</a></code>. This function therefore is deprecated and will
be removed in future versions.</p></div></div><div class="top"><p class="src"><a name="v:hasAny" class="def">hasAny</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">=&gt; [a]</td><td class="doc"><p>List of elements to look for</p></td></tr><tr><td class="src">-&gt; [a]</td><td class="doc"><p>List to search</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></td><td class="doc"><p>Result</p></td></tr></table></div><div class="doc"><p>Returns true if the given list contains any of the elements in the search
list. </p></div></div><h1 id="g:3">Association List Utilities</h1><div class="doc"><p>These functions are designed to augment the
association list functions in <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-List.html">Data.List</a> and
provide an interface similar to <a href="Data-FiniteMap.html">Data.FiniteMap</a> or
<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map.html">Data.Map</a>
for association lists. </p></div><div class="top"><p class="src"><a name="v:addToAL" class="def">addToAL</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> key =&gt; [(key, elt)] -&gt; key -&gt; elt -&gt; [(key, elt)]</p><div class="doc"><p>Adds the specified (key, value) pair to the given list, removing any
existing pair with the same key already present. </p></div></div><div class="top"><p class="src"><a name="v:delFromAL" class="def">delFromAL</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> key =&gt; [(key, a)] -&gt; key -&gt; [(key, a)]</p><div class="doc"><p>Removes all (key, value) pairs from the given list where the key
matches the given one. </p></div></div><div class="top"><p class="src"><a name="v:flipAL" class="def">flipAL</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> key, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> val) =&gt; [(key, val)] -&gt; [(val, [key])]</p><div class="doc"><p>Flips an association list. Converts (key1, val), (key2, val) pairs
to (val, [key1, key2]). </p></div></div><div class="top"><p class="src"><a name="v:keysAL" class="def">keysAL</a> :: [(key, a)] -&gt; [key]</p><div class="doc"><p>Returns the keys that comprise the (key, value) pairs of the given AL.</p><p>Same as:</p><pre>map fst</pre></div></div><div class="top"><p class="src"><a name="v:valuesAL" class="def">valuesAL</a> :: [(a, value)] -&gt; [value]</p><div class="doc"><p>Returns the values the comprise the (key, value) pairs of the given
AL.</p><p>Same as:</p><pre>map snd</pre></div></div><div class="top"><p class="src"><a name="v:hasKeyAL" class="def">hasKeyAL</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; a -&gt; [(a, b)] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>Indicates whether or not the given key is in the AL. </p></div></div><h2 id="g:4">Association List Conversions</h2><div class="top"><p class="src"><a name="v:strFromAL" class="def">strFromAL</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> b) =&gt; [(a, b)] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Converts an association list to a string. The string will have
one pair per line, with the key and value both represented as a Haskell string.</p><p>This function is designed to work with [(String, String)] association lists,
but may work with other types as well. </p></div></div><div class="top"><p class="src"><a name="v:strToAL" class="def">strToAL</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> b) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; [(a, b)]</p><div class="doc"><p>The inverse of <code><a href="Data-List-Utils.html#v:strFromAL">strFromAL</a></code>, this function reads a string and outputs the
appropriate association list. </p><p>Like <code><a href="Data-List-Utils.html#v:strFromAL">strFromAL</a></code>, this is designed to work with [(String, String)] association
lists but may also work with other objects with simple representations.</p></div></div><h1 id="g:5">Conversions</h1><div class="top"><p class="src"><a name="v:split" class="def">split</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a] -&gt; [[a]]</p><div class="doc"><p>Given a delimiter and a list (or string), split into components.</p><p>Example:</p><pre>split &quot;,&quot; &quot;foo,bar,,baz,&quot; -&gt; [&quot;foo&quot;, &quot;bar&quot;, &quot;&quot;, &quot;baz&quot;, &quot;&quot;]</pre><pre>split &quot;ba&quot; &quot;,foo,bar,,baz,&quot; -&gt; [&quot;,foo,&quot;,&quot;r,,&quot;,&quot;z,&quot;]</pre></div></div><div class="top"><p class="src"><a name="v:join" class="def">join</a> :: [a] -&gt; [[a]] -&gt; [a]</p><div class="doc"><p>Given a delimiter and a list of items (or strings), join the items
by using the delimiter.</p><p>Example:</p><pre>join &quot;|&quot; [&quot;foo&quot;, &quot;bar&quot;, &quot;baz&quot;] -&gt; &quot;foo|bar|baz&quot;</pre></div></div><div class="top"><p class="src"><a name="v:replace" class="def">replace</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a] -&gt; [a] -&gt; [a]</p><div class="doc"><p>Given a list and a replacement list, replaces each occurance of the search
list with the replacement list in the operation list.</p><p>Example:</p><pre>replace &quot;,&quot; &quot;.&quot; &quot;127,0,0,1&quot; -&gt; &quot;127.0.0.1&quot;</pre><p>This could logically be thought of as:</p><pre>replace old new l = join new . split old $ l</pre></div></div><div class="top"><p class="src"><a name="v:genericJoin" class="def">genericJoin</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; [a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Like <code><a href="Data-List-Utils.html#v:join">join</a></code>, but works with a list of anything showable, converting
it to a String.</p><p>Examples:</p><pre>genericJoin &quot;, &quot; [1, 2, 3, 4] -&gt; &quot;1, 2, 3, 4&quot;
genericJoin &quot;|&quot; [&quot;foo&quot;, &quot;bar&quot;, &quot;baz&quot;] -&gt; &quot;\&quot;foo\&quot;|\&quot;bar\&quot;|\&quot;baz\&quot;&quot;</pre></div></div><div class="top"><p class="src"><a name="v:takeWhileList" class="def">takeWhileList</a> :: ([a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a>) -&gt; [a] -&gt; [a]</p><div class="doc"><p>Similar to Data.List.takeWhile, takes elements while the func is true.
The function is given the remainder of the list to examine. </p></div></div><div class="top"><p class="src"><a name="v:dropWhileList" class="def">dropWhileList</a> :: ([a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a>) -&gt; [a] -&gt; [a]</p><div class="doc"><p>Similar to Data.List.dropWhile, drops elements while the func is true.
The function is given the remainder of the list to examine. </p></div></div><div class="top"><p class="src"><a name="v:spanList" class="def">spanList</a> :: ([a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a>) -&gt; [a] -&gt; ([a], [a])</p><div class="doc"><p>Similar to Data.List.span, but performs the test on the entire remaining
list instead of just one element. </p><p><code>spanList p xs</code> is the same as <code>(takeWhileList p xs, dropWhileList p xs)</code> </p></div></div><div class="top"><p class="src"><a name="v:breakList" class="def">breakList</a> :: ([a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a>) -&gt; [a] -&gt; ([a], [a])</p><div class="doc"><p>Similar to Data.List.break, but performs the test on the entire remaining
list instead of just one element.</p></div></div><h2 id="g:6">Advanced Conversions</h2><div class="top"><p class="src"><span class="keyword">newtype</span> <a name="t:WholeFunc" class="def">WholeFunc</a> a b</p><div class="doc"><p>The type used for functions for <code><a href="Data-List-Utils.html#v:wholeMap">wholeMap</a></code>. See <code><a href="Data-List-Utils.html#v:wholeMap">wholeMap</a></code> for details.</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:WholeFunc" class="def">WholeFunc</a> ([a] -&gt; (<a href="Data-List-Utils.html#t:WholeFunc">WholeFunc</a> a b, [a], [b]))</td><td class="doc empty">&nbsp;</td></tr></table></div></div><div class="top"><p class="src"><a name="v:wholeMap" class="def">wholeMap</a> :: <a href="Data-List-Utils.html#t:WholeFunc">WholeFunc</a> a b -&gt; [a] -&gt; [b]</p><div class="doc"><p>This is an enhanced version of the concatMap or map functions in
Data.List.</p><p>Unlike those functions, this one:</p><ul><li>Can consume a varying number of elements from the input list during
each iteration</li><li>Can arbitrarily decide when to stop processing data</li><li>Can return a varying number of elements to insert into the output list</li><li>Can actually switch processing functions mid-stream</li><li>Is not even restricted to processing the input list intact</li></ul><p>The function used by wholeMap, of type <code><a href="Data-List-Utils.html#t:WholeFunc">WholeFunc</a></code>, is repeatedly called
with the input list. The function returns three things: the function
to call for the next iteration (if any), what remains of the input list,
and the list of output elements generated during this iteration. The return
value of <code><a href="Data-List-Utils.html#v:wholeMap">wholeMap</a></code> is the concatenation of the output element lists from
all iterations.</p><p>Processing stops when the remaining input list is empty. An example
of a <code><a href="Data-List-Utils.html#t:WholeFunc">WholeFunc</a></code> is <code><a href="Data-List-Utils.html#v:fixedWidth">fixedWidth</a></code>. </p></div></div><div class="top"><p class="src"><a name="v:fixedWidth" class="def">fixedWidth</a> :: [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a>] -&gt; <a href="Data-List-Utils.html#t:WholeFunc">WholeFunc</a> a [a]</p><div class="doc"><p>A parser designed to process fixed-width input fields. Use it with
<code><a href="Data-List-Utils.html#v:wholeMap">wholeMap</a></code>.</p><p>The Int list passed to this function is the list of the field widths desired
from the input. The result is a list of those widths, if possible. If any
of the input remains after processing this list, it is added on as the final
element in the result list. If the input is less than the sum of the requested
widths, then the result list will be short the appropriate number of elements,
and its final element may be shorter than requested.</p><p>Examples:</p><pre>wholeMap (fixedWidth [1, 2, 3]) &quot;1234567890&quot;
--&gt; [&quot;1&quot;,&quot;23&quot;,&quot;456&quot;,&quot;7890&quot;]
wholeMap (fixedWidth (repeat 2)) &quot;123456789&quot;
--&gt; [&quot;12&quot;,&quot;34&quot;,&quot;56&quot;,&quot;78&quot;,&quot;9&quot;]
wholeMap (fixedWidth []) &quot;123456789&quot;
--&gt; [&quot;123456789&quot;]
wholeMap (fixedWidth [5, 3, 6, 1]) &quot;Hello, This is a test.&quot;
--&gt; [&quot;Hello&quot;,&quot;, T&quot;,&quot;his is&quot;,&quot; &quot;,&quot;a test.&quot;]</pre></div></div><h1 id="g:7">Fixed-Width and State Monad Utilities</h1><div class="top"><p class="src"><a name="v:grab" class="def">grab</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/transformers-0.4.2.0/Control-Monad-Trans-State-Lazy.html#t:State">State</a> [a] [a]</p><div class="doc"><p>Helps you pick out fixed-width components from a list.</p><p>Example:</p><pre>conv :: String -&gt; (String,String)
conv = runState $
do f3 &lt;- grab 3
n2 &lt;- grab 2
return $ f3 ++ &quot;,&quot; ++ n2
main = print $ conv &quot;TestIng&quot;</pre><p>Prints:</p><pre>(&quot;Tes,tI&quot;,&quot;ng&quot;)</pre></div></div><h1 id="g:8">Miscellaneous</h1><div class="top"><p class="src"><a name="v:countElem" class="def">countElem</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; a -&gt; [a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></p><div class="doc"><p>Returns a count of the number of times the given element occured in the
given list. </p></div></div><div class="top"><p class="src"><a name="v:elemRIndex" class="def">elemRIndex</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; a -&gt; [a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></p><div class="doc"><p>Returns the rightmost index of the given element in the
given list. </p></div></div><div class="top"><p class="src"><a name="v:alwaysElemRIndex" class="def">alwaysElemRIndex</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; a -&gt; [a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></p><div class="doc"><p>Like elemRIndex, but returns -1 if there is nothing
found. </p></div></div><div class="top"><p class="src"><a name="v:seqList" class="def">seqList</a> :: [a] -&gt; [a]</p><div class="doc"><p>Forces the evaluation of the entire list. </p></div></div><div class="top"><p class="src"><a name="v:subIndex" class="def">subIndex</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></p><div class="doc"><p>Similar to Data.List.elemIndex. Instead of looking for one element in a
list, this function looks for the first occurance of a sublist in the list,
and returns the index of the first element of that occurance. If there is no
such list, returns Nothing.</p><p>If the list to look for is the empty list, will return Just 0 regardless
of the content of the list to search.</p><p>Examples:</p><pre>subIndex &quot;foo&quot; &quot;asdfoobar&quot; -&gt; Just 3
subIndex &quot;foo&quot; [] -&gt; Nothing
subIndex &quot;&quot; [] -&gt; Just 0
subIndex &quot;&quot; &quot;asdf&quot; -&gt; Just 0
subIndex &quot;test&quot; &quot;asdftestbartest&quot; -&gt; Just 4
subIndex [(1::Int), 2] [0, 5, 3, 2, 1, 2, 4] -&gt; Just 4</pre></div></div><div class="top"><p class="src"><a name="v:uniq" class="def">uniq</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a]</p><div class="doc"><p>Given a list, returns a new list with all duplicate elements removed.
For example:</p><pre>uniq &quot;Mississippi&quot; -&gt; &quot;Misp&quot;</pre><p>You should not rely on this function necessarily preserving order, though
the current implementation happens to.</p><p>This function is not compatible with infinite lists.</p><p>This is presently an alias for Data.List.nub</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,17 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.MIME.Types</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-MIME-Types.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.MIME.Types</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Creating Lookup Objects</a></li><li><a href="#g:2">Basic Access</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Utilities for guessing MIME types of files.</p><p>Written by John Goerzen, jgoerzen@complete.org</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:defaultmtd">defaultmtd</a> :: <a href="Data-MIME-Types.html#t:MIMETypeData">MIMETypeData</a></li><li class="src short"><a href="#v:readMIMETypes">readMIMETypes</a> :: <a href="Data-MIME-Types.html#t:MIMETypeData">MIMETypeData</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a> -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="Data-MIME-Types.html#t:MIMETypeData">MIMETypeData</a></li><li class="src short"><a href="#v:hReadMIMETypes">hReadMIMETypes</a> :: <a href="Data-MIME-Types.html#t:MIMETypeData">MIMETypeData</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="Data-MIME-Types.html#t:MIMETypeData">MIMETypeData</a></li><li class="src short"><a href="#v:readSystemMIMETypes">readSystemMIMETypes</a> :: <a href="Data-MIME-Types.html#t:MIMETypeData">MIMETypeData</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="Data-MIME-Types.html#t:MIMETypeData">MIMETypeData</a></li><li class="src short"><span class="keyword">type</span> <a href="#t:MIMEResults">MIMEResults</a> = (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</li><li class="src short"><span class="keyword">data</span> <a href="#t:MIMETypeData">MIMETypeData</a> = <a href="#v:MIMETypeData">MIMETypeData</a> {<ul class="subs"><li><a href="#v:suffixMap">suffixMap</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li><a href="#v:encodingsMap">encodingsMap</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li><a href="#v:typesMap">typesMap</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li><a href="#v:commonTypesMap">commonTypesMap</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.Line truncated
Returns new object. </p></div></div><div class="top"><p class="src"><a name="v:hReadMIMETypes" class="def">hReadMIMETypes</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="Data-MIME-Types.html#t:MIMETypeData">MIMETypeData</a></td><td class="doc"><p>Data to work with</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></td><td class="doc"><p>Whether to work on strict data</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a></td><td class="doc"><p>Handle to read from</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="Data-MIME-Types.html#t:MIMETypeData">MIMETypeData</a></td><td class="doc"><p>New object</p></td></tr></table></div><div class="doc"><p>Load a mime.types file from an already-open handle. </p></div></div><div class="top"><p class="src"><a name="v:readSystemMIMETypes" class="def">readSystemMIMETypes</a> :: <a href="Data-MIME-Types.html#t:MIMETypeData">MIMETypeData</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="Data-MIME-Types.html#t:MIMETypeData">MIMETypeData</a></p><div class="doc"><p>Read the system's default mime.types files, and add the data contained
therein to the passed object, then return the new one. </p></div></div><h1 id="g:2">Basic Access</h1><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:MIMEResults" class="def">MIMEResults</a> = (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</p><div class="doc"><p>Return value from guessing a file's type.</p><p>The first element of the tuple gives the MIME type. It is Nothing if no
suitable type could be found.</p><p>The second element gives the encoding. It is Nothing if there was no particular
encoding for the file, or if no encoding could be found.</p></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:MIMETypeData" class="def">MIMETypeData</a></p><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:MIMETypeData" class="def">MIMETypeData</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div class="subs fields"><p class="caption">Fields</p><dl><dt class="src"><a name="v:suffixMap" class="def">suffixMap</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></dt><dd class="doc"><p>A mapping used to expand common suffixes into equivolent,
better-parsed versions. For instance, &quot;.tgz&quot; would expand
into &quot;.tar.gz&quot;.</p></dd><dt class="src"><a name="v:encodingsMap" class="def">encodingsMap</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></dt><dd class="doc"><p>A mapping used to determine the encoding of a file.
This is used, for instance, to map &quot;.gz&quot; to &quot;gzip&quot;.</p></dd><dt class="src"><a name="v:typesMap" class="def">typesMap</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></dt><dd class="doc"><p>A mapping used to map extensions to MIME types.</p></dd><dt class="src"><a name="v:commonTypesMap" class="def">commonTypesMap</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></dt><dd class="doc"><p>A mapping used to augment the <code><a href="Data-MIME-Types.html#v:typesMap">typesMap</a></code> when non-strict
lookups are used.</p></dd></dl><div class="clear"></div></div></td></tr></table></div></div><div class="top"><p class="src"><a name="v:guessType" class="def">guessType</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="Data-MIME-Types.html#t:MIMETypeData">MIMETypeData</a></td><td class="doc"><p>Source data for guessing</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></td><td class="doc"><p>Whether to limit to strict data</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>File or URL name to consider</p></td></tr><tr><td class="src">-&gt; <a href="Data-MIME-Types.html#t:MIMEResults">MIMEResults</a></td><td class="doc"><p>Result of guessing (see <code><a href="Data-MIME-Types.html#t:MIMEResults">MIMEResults</a></code> for details on interpreting it)</p></td></tr></table></div><div class="doc"><p>Guess the type of a file given a filename or URL. The file
is not opened; only the name is considered. </p></div></div><div class="top"><p class="src"><a name="v:guessExtension" class="def">guessExtension</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="Data-MIME-Types.html#t:MIMETypeData">MIMETypeData</a></td><td class="doc"><p>Source data for guessing</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></td><td class="doc"><p>Whether to limit to strict data</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>MIME type to consider</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Result of guessing, or Nothing if no match possible</p></td></tr></table></div><div class="doc"><p>Guess the extension of a file based on its MIME type.
The return value includes the leading dot.</p><p>Returns Nothing if no extension could be found.</p><p>In the event that multiple possible extensions are available,
one of them will be picked and returned. The logic to select one
of these should be considered undefined. </p></div></div><div class="top"><p class="src"><a name="v:guessAllExtensions" class="def">guessAllExtensions</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="Data-MIME-Types.html#t:MIMETypeData">MIMETypeData</a></td><td class="doc"><p>Source data for guessing</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></td><td class="doc"><p>Whether to limit to strict data</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>MIME type to consider</p></td></tr><tr><td class="src">-&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</td><td class="doc"><p>Result of guessing</p></td></tr></table></div><div class="doc"><p>Similar to <code><a href="Data-MIME-Types.html#v:guessExtension">guessExtension</a></code>, but returns a list of all possible matching
extensions, or the empty list if there are no matches. </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,15 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.Map.Utils</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-Map-Utils.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.Map.Utils</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Basic Utilities</a></li><li><a href="#g:2">Conversions</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This module provides various helpful utilities for dealing with Data.Maps.</p><p>Written by John Goerzen, jgoerzen@complete.org</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:flipM">flipM</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> key, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> val) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> key val -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> val [key]</li><li class="src short"><a href="#v:flippedLookupM">flippedLookupM</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> val, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> key) =&gt; val -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> key val -&gt; [key]</li><li class="src short"><a href="#v:forceLookupM">forceLookupM</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> key, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> key) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; key -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> key elt -&gt; elt</li><li class="src short"><a href="#v:strToM">strToM</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> b, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> a) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> a b</li><li class="src short"><a href="#v:strFromM">strFromM</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> b, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> a) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> a b -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li></ul></div><div id="interface"><h1 id="g:1">Basic Utilities</h1><div class="top"><p class="src"><a name="v:flipM" class="def">flipM</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> key, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> val) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> key val -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> val [key]<Line truncated
function for lists. </p></div></div><div class="top"><p class="src"><a name="v:flippedLookupM" class="def">flippedLookupM</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> val, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> key) =&gt; val -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> key val -&gt; [key]</p><div class="doc"><p>Returns a list of all keys in the Map whose value matches the
parameter. If the value does not occur in the Map, the empty
list is returned. </p></div></div><div class="top"><p class="src"><a name="v:forceLookupM" class="def">forceLookupM</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> key, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> key) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; key -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> key elt -&gt; elt</p><div class="doc"><p>Performs a lookup, and raises an exception (with an error message
prepended with the given string) if the key could not be found.</p></div></div><h1 id="g:2">Conversions</h1><div class="top"><p class="src"><a name="v:strToM" class="def">strToM</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> b, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> a) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> a b</p><div class="doc"><p>Converts a String into a String, String Map. See
<code><a href="Data-List-Utils.html#v:strToAL">strToAL</a></code> for more on the similar function for association
lists.</p><p>This implementation is simple:</p><pre>strToM = Data.Map.fromList . strToAL</pre><p>This function is designed to work with Map String String objects,
but may work with other key/value combinations if they have simple
representations. </p></div></div><div class="top"><p class="src"><a name="v:strFromM" class="def">strFromM</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> b, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> a) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/containers-0.5.6.2/Data-Map-Lazy.html#t:Map">Map</a> a b -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Converts a String, String Map into a string representation.
See <code><a href="Data-List-Utils.html#v:strFromAL">strFromAL</a></code> for more on the similar function for
association lists. This implementation is simple:</p><pre>strFromM = strFromAL . Data.Map.toList</pre><p>This function is designed to work with Map String String objects,
but may also work with other objects with simple representations. </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,6 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.Maybe.Utils</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-Maybe-Utils.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2005-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.Maybe.Utils</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Utilities for working with the Either data type</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:forceMaybe">forceMaybe</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> a -&gt; a</li><li class="src short"><a href="#v:forceMaybeMsg">forceMaybeMsg</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> a -&gt; a</li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:forceMaybe" class="def">forceMaybe</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> a -&gt; a</p><div class="doc"><p>Pulls a Just value out of a Maybe value. If the Maybe value is
Nothing, raises an exception with error. </p></div></div><div class="top"><p class="src"><a name="v:forceMaybeMsg" class="def">forceMaybeMsg</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> a -&gt; a</p><div class="doc"><p>Like <code><a href="Data-Maybe-Utils.html#v:forceMaybe">forceMaybe</a></code>, but lets you customize the error message raised if
Nothing is supplied. </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,9 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.Progress.Meter</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-Progress-Meter.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2006-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.Progress.Meter</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Types</a></li><li><a href="#g:2">Creation and Configuration</a></li><li><a href="#g:3">Rendering and Output</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Tool for maintaining a status bar, supporting multiple simultaneous tasks,
as a layer atop <a href="Data-Progress-Tracker.html">Data.Progress.Tracker</a>.</p><p>Written by John Goerzen, jgoerzen@complete.org </p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">type</span> <a href="#t:ProgressMeter">ProgressMeter</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Control-Concurrent-MVar.html#t:MVar">MVar</a> ProgressMeterR</li><li class="src short"><a href="#v:simpleNewMeter">simpleNewMeter</a> :: <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="Data-Progress-Meter.html#t:ProgressMeter">ProgressMeter</a></li><li class="src short"><a href="#v:newMeter">newMeter</a> :: <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; ([<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a>] -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="Data-Progress-Meter.html#t:ProgressMeter">ProgressMeter</a></li><li class="src short"><a href="#v:setComponents">setComponents</a> :: <a href="Data-Progress-Meter.html#t:ProgressMeter">ProgressMeter</a> -&gt; [<a href="Data-Progress-Tracker.html#t:Progress">Progress</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:addComponent">addComponent</a> :: <a href="Data-Progress-Meter.html#t:ProgressMeter">ProgressMeter</a> -&gt; <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:removeComponent">removeComponent</a> :: <a href="Data-Progress-Meter.html#t:ProgressMeter">ProgressMeter</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:setWidth">setWidth</a> :: <a href="Data-Progress-Meter.html#t:ProgressMeter">ProgressMeter</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:renderMeter">renderMeter</a> :: <a href="Data-Progress-Meter.html#t:ProgressMeter">ProgressMeter</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:displayMeter">displayMeter</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a> -&gt; <a href="Data-Progress-Meter.html#t:ProgressMeter">ProgressMeter</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:clearMeter">clearMeter</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a> -&gt; <a href="Data-Progress-Meter.html#t:ProgressMeter">ProgressMeter</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:writeMeterString">writeMeterString</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a> -&gt; <a href="Data-Progress-Meter.html#t:ProgressMeter">ProgressMeter</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:autoDisplayMeter">autoDisplayMeter</a> :: <a href="Data-Progress-Line truncated
then another CR.</p><p>Pass stdout as the handle for regular display to the screen. </p></div></div><div class="top"><p class="src"><a name="v:writeMeterString" class="def">writeMeterString</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a> -&gt; <a href="Data-Progress-Meter.html#t:ProgressMeter">ProgressMeter</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Clears the meter, writes the given string, then restores the meter.
The string is assumed to contain a trailing newline.</p><p>Pass stdout as the handle for regular display to the screen. </p></div></div><div class="top"><p class="src"><a name="v:autoDisplayMeter" class="def">autoDisplayMeter</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="Data-Progress-Meter.html#t:ProgressMeter">ProgressMeter</a></td><td class="doc"><p>The meter to display</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></td><td class="doc"><p>Update interval in seconds</p></td></tr><tr><td class="src">-&gt; (<a href="Data-Progress-Meter.html#t:ProgressMeter">ProgressMeter</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ())</td><td class="doc"><p>Function to display it</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Control-Concurrent.html#t:ThreadId">ThreadId</a></td><td class="doc"><p>Resulting thread id</p></td></tr></table></div><div class="doc"><p>Starts a thread that updates the meter every n seconds by calling
the specified function. Note: <code>displayMeter stdout</code>
is an ideal function here.</p><p>Save this threadID and use it later to call <code>stopAutoDisplayMeter</code>.</p></div></div><div class="top"><p class="src"><a name="v:killAutoDisplayMeter" class="def">killAutoDisplayMeter</a> :: <a href="Data-Progress-Meter.html#t:ProgressMeter">ProgressMeter</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Control-Concurrent.html#t:ThreadId">ThreadId</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Stops the specified meter from displaying.</p><p>You should probably call <code><a href="Data-Progress-Meter.html#v:clearMeter">clearMeter</a></code> after a call to this. </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,73 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.Progress.Tracker</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-Progress-Tracker.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2006-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.Progress.Tracker</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Introduction</a></li><li><a href="#g:2">Updating</a></li><li><a href="#g:3">Reading and Processing</a></li><li><a href="#g:4">Types</a></li><li><a href="#g:5">Utilities</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Tools for tracking the status of a long operation.</p><p>Written by John Goerzen, jgoerzen@complete.org </p><p>See also <a href="Data-Progress-Meter.html">Data.Progress.Meter</a> </p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:newProgress">newProgress</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="Data-Progress-Tracker.html#t:Progress">Progress</a></li><li class="src short"><a href="#v:newProgress-39-">newProgress'</a> :: <a href="Data-Progress-Tracker.html#t:ProgressStatus">ProgressStatus</a> -&gt; [<a href="Data-Progress-Tracker.html#t:ProgressCallback">ProgressCallback</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="Data-Progress-Tracker.html#t:Progress">Progress</a></li><li class="src short"><a href="#v:addCallback">addCallback</a> :: <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="Data-Progress-Tracker.html#t:ProgressCallback">ProgressCallback</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:addParent">addParent</a> :: <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:incrP">incrP</a> :: <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:incrP-39-">incrP'</a> :: <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:setP">setP</a> :: <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:setP-39-">setP'</a> :: <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:incrTotal">incrTotal</a> :: <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:setTotal">setTotal</a> :: <a href="Data-Progress-Tracker.html#t:Progress"Line truncated
operations. It can be thought of as the back end engine behind
a status bar. ProgressTracker can do things such as track how far along
a task is, provide an estimated time of completion, estimated time remaining,
current speed, etc. It is designed to be as generic as possible; it can even
base its speed calculations on something other than the system clock.</p><p>ProgressTracker also supports a notion of a parent tracker. This is used when
a large task is composed of several individual tasks which may also be
long-running. Downloading many large files over the Internet is a common
example of this.</p><p>Any given ProgressTracker can be told about one or more parent trackers.
When the child tracker's status is updated, the parent tracker's status is
also updated in the same manner. Therefore, the progress on each individual
component, as well as the overall progress, can all be kept in sync
automatically.</p><p>Finally, you can register callbacks. Callbacks are functions that are called
whenever the status of a tracker changes. They'll be passed the old and new
status and are intended to do things like update on-screen status displays.</p><p>The cousin module <code><a href="Data-Progress.html#t:Meter">Meter</a></code> can be used to nicely render
these trackers on a console.</p></div><div class="top"><p class="src"><a name="v:newProgress" class="def">newProgress</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Name of this tracker</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a></td><td class="doc"><p>Total units expected</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="Data-Progress-Tracker.html#t:Progress">Progress</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Create a new <code><a href="Data-Progress-Tracker.html#t:Progress">Progress</a></code> object with the given name and number
of total units initialized as given. The start time will be initialized
with the current time at the present moment according to the system clock.
The units completed will be set to 0, the time source will be set to the
system clock, and the parents and callbacks will be empty.</p><p>If you need more control, see 'newProgress\''.</p><p>Example:</p><pre>prog &lt;- newProgress &quot;mytracker&quot; 1024</pre></div></div><div class="top"><p class="src"><a name="v:newProgress-39-" class="def">newProgress'</a> :: <a href="Data-Progress-Tracker.html#t:ProgressStatus">ProgressStatus</a> -&gt; [<a href="Data-Progress-Tracker.html#t:ProgressCallback">ProgressCallback</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="Data-Progress-Tracker.html#t:Progress">Progress</a></p><div class="doc"><p>Create a new <code><a href="Data-Progress-Tracker.html#t:Progress">Progress</a></code> object initialized with the given status and
callbacks.
No adjustment to the <code><a href="Data-Progress-Tracker.html#v:startTime">startTime</a></code> will be made. If you
want to use the system clock, you can initialize <code><a href="Data-Progress-Tracker.html#v:startTime">startTime</a></code> with
the return value of <code><a href="Data-Progress-Tracker.html#v:defaultTimeSource">defaultTimeSource</a></code> and also pass <code><a href="Data-Progress-Tracker.html#v:defaultTimeSource">defaultTimeSource</a></code>
as the timing source. </p></div></div><div class="top"><p class="src"><a name="v:addCallback" class="def">addCallback</a> :: <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="Data-Progress-Tracker.html#t:ProgressCallback">ProgressCallback</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Adds an new callback to an existing <code><a href="Data-Progress-Tracker.html#t:Progress">Progress</a></code>. The callback will be
called whenever the object's status is updated, except by the call to finishP.</p><p>Please note that the Progress object will be locked while the callback is
running, so the callback will not be able to make any modifications to it.</p></div></div><div class="top"><p class="src"><a name="v:addParent" class="def">addParent</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="Data-Progress-Tracker.html#t:Progress">Progress</a></td><td class="doc"><p>The child object</p></td></tr><tr><td class="src">-&gt; <a href="Data-Progress-Tracker.html#t:Progress">Progress</a></td><td class="doc"><p>The parent to add to this child</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Adds a new parent to an existing <code><a href="Data-Progress-Tracker.html#t:Progress">Progress</a></code>. The parent
will automatically have its completed and total counters incremented
by the value of those counters in the existing <code><a href="Data-Progress-Tracker.html#t:Progress">Progress</a></code>. </p></div></div><h1 id="g:2">Updating</h1><div class="top"><p class="src"><a name="v:incrP" class="def">incrP</a> :: <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Increment the completed unit count in the <code><a href="Data-Progress-Tracker.html#t:Progress">Progress</a></code> object
by the amount given. If the value as given exceeds the total, then
the total will also be raised to match this value so that the
completed count never exceeds the total.</p><p>You can decrease the completed unit count by supplying a negative number
here. </p></div></div><div class="top"><p class="src"><a name="v:incrP-39-" class="def">incrP'</a> :: <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Like <code><a href="Data-Progress-Tracker.html#v:incrP">incrP</a></code>, but never modify the total. </p></div></div><div class="top"><p class="src"><a name="v:setP" class="def">setP</a> :: <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Set the completed unit count in the <code><a href="Data-Progress-Tracker.html#t:Progress">Progress</a></code> object to the specified
value. Unlike <code><a href="Data-Progress-Tracker.html#v:incrP">incrP</a></code>, this function sets the count to a specific value,
rather than adding to the existing value. If this value exceeds the total,
then the total will also be raised to match this value so that the completed
count never exceeds teh total. </p></div></div><div class="top"><p class="src"><a name="v:setP-39-" class="def">setP'</a> :: <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Like <code><a href="Data-Progress-Tracker.html#v:setP">setP</a></code>, but never modify the total. </p></div></div><div class="top"><p class="src"><a name="v:incrTotal" class="def">incrTotal</a> :: <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Increment the total unit count in the <code><a href="Data-Progress-Tracker.html#t:Progress">Progress</a></code> object by the amount
given. This would rarely be needed, but could be needed in some special cases
when the total number of units is not known in advance. </p></div></div><div class="top"><p class="src"><a name="v:setTotal" class="def">setTotal</a> :: <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Set the total unit count in the <code><a href="Data-Progress-Tracker.html#t:Progress">Progress</a></code> object to the specified
value. Like <code><a href="Data-Progress-Tracker.html#v:incrTotal">incrTotal</a></code>, this would rarely be needed. </p></div></div><div class="top"><p class="src"><a name="v:finishP" class="def">finishP</a> :: <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Call this when you are finished with the object. It is especially
important to do this when parent objects are involved.</p><p>This will simply set the totalUnits to the current completedUnits count,
but will not call the callbacks. It will additionally propogate
any adjustment in totalUnits to the parents, whose callbacks <em>will</em> be
called.</p><p>This ensures that the total expected counts on the parent are always correct.
Without doing this, if, say, a transfer ended earlier than expected, ETA
values on the parent would be off since it would be expecting more data than
actually arrived. </p></div></div><h1 id="g:3">Reading and Processing</h1><div class="top"><p class="src"><a name="v:getSpeed" class="def">getSpeed</a> :: (<a href="Data-Progress-Tracker.html#t:ProgressStatuses">ProgressStatuses</a> a (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> b), <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Fractional">Fractional</a> b) =&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> b</p><div class="doc"><p>Returns the speed in units processed per time unit. (If you are
using the default time source, this would be units processed per second).
This obtains the current speed solely from analyzing the <code><a href="Data-Progress-Tracker.html#t:Progress">Progress</a></code> object.</p><p>If no time has elapsed yet, returns 0.</p><p>You can use this against either a <code><a href="Data-Progress-Tracker.html#t:Progress">Progress</a></code> object or a <code><a href="Data-Progress-Tracker.html#t:ProgressStatus">ProgressStatus</a></code>
object. This is in the IO monad because the speed is based on the current
time.</p><p>Example:</p><pre>getSpeed progressobj &gt;&gt;= print</pre><p>Don't let the type of this function confuse you. It is a fancy way of saying
that it can take either a <code><a href="Data-Progress-Tracker.html#t:Progress">Progress</a></code> or a <code><a href="Data-Progress-Tracker.html#t:ProgressStatus">ProgressStatus</a></code> object, and returns
a number that is valid as any Fractional type, such as a Double, Float, or
Rational. </p></div></div><div class="top"><p class="src"><a name="v:getETR" class="def">getETR</a> :: (<a href="Data-Progress-Tracker.html#t:ProgressStatuses">ProgressStatuses</a> a (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a>), <a href="Data-Progress-Tracker.html#t:ProgressStatuses">ProgressStatuses</a> a (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Rational">Rational</a>)) =&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a></p><div class="doc"><p>Returns the estimated time remaining, in standard time units. </p><p>Returns 0 whenever <code><a href="Data-Progress-Tracker.html#v:getSpeed">getSpeed</a></code> would return 0.</p><p>See the comments under <code><a href="Data-Progress-Tracker.html#v:getSpeed">getSpeed</a></code> for information about this function's type
and result. </p></div></div><div class="top"><p class="src"><a name="v:getETA" class="def">getETA</a> :: (<a href="Data-Progress-Tracker.html#t:ProgressStatuses">ProgressStatuses</a> a (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a>), <a href="Data-Progress-Tracker.html#t:ProgressStatuses">ProgressStatuses</a> a (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Rational">Rational</a>)) =&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a></p><div class="doc"><p>Returns the estimated system clock time of completion, in standard
time units. Returns the current time whenever <code><a href="Data-Progress-Tracker.html#v:getETR">getETR</a></code> would return 0.</p><p>See the comments under <code><a href="Data-Progress-Tracker.html#v:getSpeed">getSpeed</a></code> for information about this function's type
and result. </p></div></div><h1 id="g:4">Types</h1><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:ProgressStatus" class="def">ProgressStatus</a></p><div class="doc"><p>The main progress status record. </p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:ProgressStatus" class="def">ProgressStatus</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div class="subs fields"><p class="caption">Fields</p><dl><dt class="src"><a name="v:completedUnits" class="def">completedUnits</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:totalUnits" class="def">totalUnits</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:startTime" class="def">startTime</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:trackerName" class="def">trackerName</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></dt><dd class="doc"><p>An identifying string</p></dd><dt class="src"><a name="v:timeSource" class="def">timeSource</a> :: <a href="Data-Progress-Tracker.html#t:ProgressTimeSource">ProgressTimeSource</a></dt><dd class="doc empty">&nbsp;</dd></dl><div class="clear"></div></div></td></tr></table></div><div class="subs instances"><p id="control.i:ProgressStatus" class="caption collapser" onclick="toggleSection('i:ProgressStatus')">Instances</p><div id="section.i:ProgressStatus" class="show"><table><tr><td class="src"><a href="Data-Progress-Tracker.html#t:ProgressStatuses">ProgressStatuses</a> <a href="Data-Progress-Tracker.html#t:ProgressStatus">ProgressStatus</a> b</td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:Progress" class="def">Progress</a></p><div class="doc"><p>The main Progress object. </p></div><div class="subs instances"><p id="control.i:Progress" class="caption collapser" onclick="toggleSection('i:Progress')">Instances</p><div id="section.i:Progress" class="show"><table><tr><td class="src"><a href="Data-Progress-Tracker.html#t:ProgressStatuses">ProgressStatuses</a> <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> b)</td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:ProgressTimeSource" class="def">ProgressTimeSource</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a></p><div class="doc"><p>A function that, when called, yields the current time.
The default is <code><a href="Data-Progress-Tracker.html#v:defaultTimeSource">defaultTimeSource</a></code>. </p></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:ProgressCallback" class="def">ProgressCallback</a> = <a href="Data-Progress-Tracker.html#t:ProgressStatus">ProgressStatus</a> -&gt; <a href="Data-Progress-Tracker.html#t:ProgressStatus">ProgressStatus</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>The type for a callback function for the progress tracker.
When given at creation time to 'newProgress\'' or when added via <code><a href="Data-Progress-Tracker.html#v:addCallback">addCallback</a></code>,
these functions get called every time the status of the tracker changes.</p><p>This function is passed two <code><a href="Data-Progress-Tracker.html#t:ProgressStatus">ProgressStatus</a></code> records: the first
reflects the status prior to the update, and the second reflects
the status after the update.</p><p>Please note that the owning <code><a href="Data-Progress-Tracker.html#t:Progress">Progress</a></code> object will be locked while the
callback is running, so the callback will not be able to make changes to it. </p></div></div><div class="top"><p class="src"><span class="keyword">class</span> <a name="t:ProgressStatuses" class="def">ProgressStatuses</a> a b <span class="keyword">where</span></p><div class="subs methods"><p class="caption">Methods</p><p class="src"><a name="v:withStatus" class="def">withStatus</a> :: a -&gt; (<a href="Data-Progress-Tracker.html#t:ProgressStatus">ProgressStatus</a> -&gt; b) -&gt; b</p><div class="doc"><p>Lets you examine the <code><a href="Data-Progress-Tracker.html#t:ProgressStatus">ProgressStatus</a></code> that is contained
within a <code><a href="Data-Progress-Tracker.html#t:Progress">Progress</a></code> object. You can simply pass
a <code><a href="Data-Progress-Tracker.html#t:Progress">Progress</a></code> object and a function to <code><a href="Data-Progress-Tracker.html#v:withStatus">withStatus</a></code>, and
<code><a href="Data-Progress-Tracker.html#v:withStatus">withStatus</a></code> will lock the <code><a href="Data-Progress-Tracker.html#t:Progress">Progress</a></code> object (blocking any
modifications while you are reading it), then pass the object
to your function. If you happen to already have a <code><a href="Data-Progress-Tracker.html#t:ProgressStatus">ProgressStatus</a></code>
object, withStatus will also accept it and simply pass it unmodified
to the function. </p></div></div><div class="subs instances"><p id="control.i:ProgressStatuses" class="caption collapser" onclick="toggleSection('i:ProgressStatuses')">Instances</p><div id="section.i:ProgressStatuses" class="show"><table><tr><td class="src"><a href="Data-Progress-Tracker.html#t:ProgressStatuses">ProgressStatuses</a> <a href="Data-Progress-Tracker.html#t:ProgressStatus">ProgressStatus</a> b</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="Data-Progress-Tracker.html#t:ProgressStatuses">ProgressStatuses</a> <a href="Data-Progress-Tracker.html#t:Progress">Progress</a> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> b)</td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><h1 id="g:5">Utilities</h1><div class="top"><p class="src"><a name="v:defaultTimeSource" class="def">defaultTimeSource</a> :: <a href="Data-Progress-Tracker.html#t:ProgressTimeSource">ProgressTimeSource</a></p><div class="doc"><p>The default time source for the system. This is defined as:</p><pre>getClockTime &gt;&gt;= (return . clockTimeToEpoch)</pre></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,41 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.Quantity</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-Quantity.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2006-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.Quantity</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Tools for rendering sizes</p><p>Written by John Goerzen, jgoerzen@complete.org </p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:renderNum">renderNum</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Real">Real</a> a) =&gt; <a href="Data-Quantity.html#t:SizeOpts">SizeOpts</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:renderNums">renderNums</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Real">Real</a> a) =&gt; <a href="Data-Quantity.html#t:SizeOpts">SizeOpts</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; [a] -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</li><li class="src short"><a href="#v:parseNum">parseNum</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Fractional">Fractional</a> a) =&gt; <a href="Data-Quantity.html#t:SizeOpts">SizeOpts</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> a</li><li class="src short"><a href="#v:parseNumInt">parseNumInt</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integral">Integral</a> a) =&gt; <a href="Data-Quantity.html#t:SizeOpts">SizeOpts</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> a</li><li class="src short"><a href="#v:quantifyNum">quantifyNum</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Real">Real</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Floating">Floating</a> b, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> b) =&gt; <a href="Data-Quantity.html#t:SizeOpts">SizeOpts</a> -&gt; a -&gt; (b, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Char.html#t:Char">Char</a>)</li><li class="src short"><a href="#v:quantifyNums">quantifyNums</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraLine truncated
useful for displaying quantities in terms of bytes or in SI units. Give this
function the <code><a href="Data-Quantity.html#t:SizeOpts">SizeOpts</a></code> for the desired output, and a precision (number of
digits to the right of the decimal point), and you get a string output.</p><p>Here are some examples:</p><pre>Data.Quantity&gt; renderNum binaryOpts 0 1048576
&quot;1M&quot;
Data.Quantity&gt; renderNum binaryOpts 2 10485760
&quot;10.00M&quot;
Data.Quantity&gt; renderNum binaryOpts 3 1048576
&quot;1.000M&quot;
Data.Quantity&gt; renderNum binaryOpts 3 1500000
&quot;1.431M&quot;
Data.Quantity&gt; renderNum binaryOpts 2 (1500 ** 3)
&quot;3.14G&quot;</pre><pre>Data.Quantity&gt; renderNum siOpts 2 1024
&quot;1.02k&quot;
Data.Quantity&gt; renderNum siOpts 2 1048576
&quot;1.05M&quot;
Data.Quantity&gt; renderNum siOpts 2 0.001
&quot;1.00m&quot;
Data.Quantity&gt; renderNum siOpts 2 0.0001
&quot;100.00u&quot;</pre><p>If you want more control over the output, see <code><a href="Data-Quantity.html#v:quantifyNum">quantifyNum</a></code>. </p></div></div><div class="top"><p class="src"><a name="v:renderNums" class="def">renderNums</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Real">Real</a> a)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">=&gt; <a href="Data-Quantity.html#t:SizeOpts">SizeOpts</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></td><td class="doc"><p>Prevision of the result</p></td></tr><tr><td class="src">-&gt; [a]</td><td class="doc"><p>The numbers to examine</p></td></tr><tr><td class="src">-&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</td><td class="doc"><p>Result</p></td></tr></table></div><div class="doc"><p>Like <code><a href="Data-Quantity.html#v:renderNum">renderNum</a></code>, but operates on a list of numbers. The first number
in the list will be evaluated for the suffix. The same suffix and scale will
be used for the remaining items in the list. See <code><a href="Data-Quantity.html#v:renderNum">renderNum</a></code> for more
examples.</p><p>Also, unlike <code><a href="Data-Quantity.html#v:renderNum">renderNum</a></code>, the %f instead of %g printf format is used so that
&quot;scientific&quot; notation is avoided in the output.</p><p>Examples:</p><pre>*Data.Quantity&gt; renderNums binaryOpts 3 [1500000, 10240, 104857600]
[&quot;1.431M&quot;,&quot;0.010M&quot;,&quot;100.000M&quot;]
*Data.Quantity&gt; renderNums binaryOpts 3 [1500, 10240, 104857600]
[&quot;1.465K&quot;,&quot;10.000K&quot;,&quot;102400.000K&quot;]</pre></div></div><div class="top"><p class="src"><a name="v:parseNum" class="def">parseNum</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Fractional">Fractional</a> a)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">=&gt; <a href="Data-Quantity.html#t:SizeOpts">SizeOpts</a></td><td class="doc"><p>Information on how to parse this data</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></td><td class="doc"><p>Whether to perform a case-insensitive match</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>The string to parse</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> a</td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Parses a String, possibly generated by <code><a href="Data-Quantity.html#v:renderNum">renderNum</a></code>. Parses the suffix
and applies it to the number, which is read via the Read class.</p><p>Returns Left &quot;error message&quot; on error, or Right number on successful parse.</p><p>If you want an Integral result, the convenience function <code><a href="Data-Quantity.html#v:parseNumInt">parseNumInt</a></code> is for
you.</p></div></div><div class="top"><p class="src"><a name="v:parseNumInt" class="def">parseNumInt</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integral">Integral</a> a)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">=&gt; <a href="Data-Quantity.html#t:SizeOpts">SizeOpts</a></td><td class="doc"><p>Information on how to parse this data</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></td><td class="doc"><p>Whether to perform a case-insensitive match</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>The string to parse</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> a</td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Parse a number as with <code><a href="Data-Quantity.html#v:parseNum">parseNum</a></code>, but return the result as
an <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integral">Integral</a></code>. Any type such as Integer, Int, etc. can be used for the
result type.</p><p>This function simply calls <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#v:round">round</a></code> on the result of <code><a href="Data-Quantity.html#v:parseNum">parseNum</a></code>. A
<code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-Exts.html#t:Double">Double</a></code> is used internally for the parsing of the numeric component.</p><p>By using this function, a user can still say something like 1.5M and get an
integral result. </p></div></div><div class="top"><p class="src"><a name="v:quantifyNum" class="def">quantifyNum</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Real">Real</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Floating">Floating</a> b, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> b) =&gt; <a href="Data-Quantity.html#t:SizeOpts">SizeOpts</a> -&gt; a -&gt; (b, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Char.html#t:Char">Char</a>)</p><div class="doc"><p>Takes a number and returns a new (quantity, suffix) combination.
The space character is used as the suffix for items around 0. </p></div></div><div class="top"><p class="src"><a name="v:quantifyNums" class="def">quantifyNums</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Real">Real</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Floating">Floating</a> b, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> b) =&gt; <a href="Data-Quantity.html#t:SizeOpts">SizeOpts</a> -&gt; [a] -&gt; ([b], <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Char.html#t:Char">Char</a>)</p><div class="doc"><p>Like <code><a href="Data-Quantity.html#v:quantifyNum">quantifyNum</a></code>, but takes a list of numbers. The first number in
the list will be evaluated for the suffix. The same suffix and scale will
be used for the remaining items in the list. Please see <code><a href="Data-Quantity.html#v:renderNums">renderNums</a></code> for
an example of how this works.</p><p>It is invalid to use this function on an empty list. </p></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:SizeOpts" class="def">SizeOpts</a></p><div class="doc"><p>The options for <code><a href="Data-Quantity.html#v:quantifyNum">quantifyNum</a></code> and <code><a href="Data-Quantity.html#v:renderNum">renderNum</a></code> </p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:SizeOpts" class="def">SizeOpts</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div class="subs fields"><p class="caption">Fields</p><dl><dt class="src"><a name="v:base" class="def">base</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></dt><dd class="doc"><p>The base from which calculations are made</p></dd><dt class="src"><a name="v:powerIncr" class="def">powerIncr</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></dt><dd class="doc"><p>The increment to the power for each new suffix</p></dd><dt class="src"><a name="v:firstPower" class="def">firstPower</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></dt><dd class="doc"><p>The first power for which suffixes are given</p></dd><dt class="src"><a name="v:suffixes" class="def">suffixes</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></dt><dd class="doc"><p>The suffixes themselves</p></dd></dl><div class="clear"></div></div></td></tr></table></div></div><div class="top"><p class="src"><a name="v:binaryOpts" class="def">binaryOpts</a> :: <a href="Data-Quantity.html#t:SizeOpts">SizeOpts</a></p><div class="doc"><p>Predefined definitions for byte measurement in groups of 1024, from 0 to
2**80 </p></div></div><div class="top"><p class="src"><a name="v:siOpts" class="def">siOpts</a> :: <a href="Data-Quantity.html#t:SizeOpts">SizeOpts</a></p><div class="doc"><p>Predefined definitions for SI measurement, from 10**-24 to 10**24. </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,19 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.String.Utils</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-String-Utils.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.String.Utils</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Whitespace Removal</a></li><li><a href="#g:2">Tests</a></li><li><a href="#g:3">Conversions</a></li><li><a href="#g:4">Reading</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This module provides various helpful utilities for dealing with strings.</p><p>Written by John Goerzen, jgoerzen@complete.org</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:strip">strip</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:lstrip">lstrip</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:rstrip">rstrip</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:startswith">startswith</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li class="src short"><a href="#v:endswith">endswith</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li class="src short"><a href="#v:join">join</a> :: [a] -&gt; [[a]] -&gt; [a]</li><li class="src short"><a href="#v:split">split</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a] -&gt; [[a]]</li><li class="src short"><a href="#v:splitWs">splitWs</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</li><li class="src short"><a href="#v:replace">replace</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a] -&gt; [a] -&gt; [a]</li><li class="src short"><a href="#v:escapeRe">escapeRe</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:maybeRead">maybeRead</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> a =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> a</li></ul></div><div id="interface"><h1 id="g:1">Whitespace Removal</h1><div class="top"><p class="src"><a name="v:strip" class="def">strip</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Removes any whitespace characters that are presenLine truncated
or end of a string. Does not alter the internal contents of a
string. If no whitespace characters are present at the start or end
of a string, returns the original string unmodified. Safe to use on
any string.</p><p>Note that this may differ from some other similar
functions from other authors in that:</p><ol><li>If multiple whitespace
characters are present all in a row, they are all removed;</li><li>If no
whitespace characters are present, nothing is done.</li></ol></div></div><div class="top"><p class="src"><a name="v:lstrip" class="def">lstrip</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Same as <code><a href="Data-String-Utils.html#v:strip">strip</a></code>, but applies only to the left side of the string.</p></div></div><div class="top"><p class="src"><a name="v:rstrip" class="def">rstrip</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Same as <code><a href="Data-String-Utils.html#v:strip">strip</a></code>, but applies only to the right side of the string.</p></div></div><h1 id="g:2">Tests</h1><div class="doc"><p>Note: These functions are aliases for functions
in <a href="Data-List-Utils.html">Data.List.Utils</a>.</p></div><div class="top"><p class="src"><a name="v:startswith" class="def">startswith</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>Returns true if the given list starts with the specified elements;
false otherwise. (This is an alias for &quot;Data.List.isPrefixOf&quot;.)</p><p>Example:</p><pre>startswith &quot;He&quot; &quot;Hello&quot; -&gt; True</pre></div></div><div class="top"><p class="src"><a name="v:endswith" class="def">endswith</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>Returns true if the given list ends with the specified elements;
false otherwise. (This is an alias for &quot;Data.List.isSuffixOf&quot;.)</p><p>Example:</p><pre>endswith &quot;lo&quot; &quot;Hello&quot; -&gt; True</pre></div></div><h1 id="g:3">Conversions</h1><div class="doc"><p>Note: Some of these functions are aliases for functions
in <a href="Data-List-Utils.html">Data.List.Utils</a>.</p></div><div class="top"><p class="src"><a name="v:join" class="def">join</a> :: [a] -&gt; [[a]] -&gt; [a]</p><div class="doc"><p>Given a delimiter and a list of items (or strings), join the items
by using the delimiter.</p><p>Example:</p><pre>join &quot;|&quot; [&quot;foo&quot;, &quot;bar&quot;, &quot;baz&quot;] -&gt; &quot;foo|bar|baz&quot;</pre></div></div><div class="top"><p class="src"><a name="v:split" class="def">split</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a] -&gt; [[a]]</p><div class="doc"><p>Given a delimiter and a list (or string), split into components.</p><p>Example:</p><pre>split &quot;,&quot; &quot;foo,bar,,baz,&quot; -&gt; [&quot;foo&quot;, &quot;bar&quot;, &quot;&quot;, &quot;baz&quot;, &quot;&quot;]</pre><pre>split &quot;ba&quot; &quot;,foo,bar,,baz,&quot; -&gt; [&quot;,foo,&quot;,&quot;r,,&quot;,&quot;z,&quot;]</pre></div></div><div class="top"><p class="src"><a name="v:splitWs" class="def">splitWs</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</p><div class="doc"><p>Splits a string around whitespace. Empty elements in the result
list are automatically removed. </p></div></div><div class="top"><p class="src"><a name="v:replace" class="def">replace</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a =&gt; [a] -&gt; [a] -&gt; [a] -&gt; [a]</p><div class="doc"><p>Given a list and a replacement list, replaces each occurance of the search
list with the replacement list in the operation list.</p><p>Example:</p><pre>replace &quot;,&quot; &quot;.&quot; &quot;127,0,0,1&quot; -&gt; &quot;127.0.0.1&quot;</pre><p>This could logically be thought of as:</p><pre>replace old new l = join new . split old $ l</pre></div></div><div class="top"><p class="src"><a name="v:escapeRe" class="def">escapeRe</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Escape all characters in the input pattern that are not alphanumeric.</p><p>Does not make special allowances for NULL, which isn't valid in a
Haskell regular expression pattern. </p></div></div><h1 id="g:4">Reading</h1><div class="top"><p class="src"><a name="v:maybeRead" class="def">maybeRead</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> a =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> a</p><div class="doc"><p>Attempts to parse a value from the front of the string.</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Data.Tuple.Utils</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Data-Tuple-Utils.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Data.Tuple.Utils</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Extraction</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This module provides various helpful utilities for dealing with lists.</p><p>Written by Neil Mitchell, <a href="http://www.cs.york.ac.uk/~ndm/">http://www.cs.york.ac.uk/~ndm/</a></p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:fst3">fst3</a> :: (a, b, c) -&gt; a</li><li class="src short"><a href="#v:snd3">snd3</a> :: (a, b, c) -&gt; b</li><li class="src short"><a href="#v:thd3">thd3</a> :: (a, b, c) -&gt; c</li></ul></div><div id="interface"><h1 id="g:1">Extraction</h1><div class="top"><p class="src"><a name="v:fst3" class="def">fst3</a> :: (a, b, c) -&gt; a</p><div class="doc"><p>Take the first item out of a 3 element tuple</p></div></div><div class="top"><p class="src"><a name="v:snd3" class="def">snd3</a> :: (a, b, c) -&gt; b</p><div class="doc"><p>Take the second item out of a 3 element tuple</p></div></div><div class="top"><p class="src"><a name="v:thd3" class="def">thd3</a> :: (a, b, c) -&gt; c</p><div class="doc"><p>Take the third item out of a 3 element tuple</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,8 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Network.Email.Mailbox</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Network-Email-Mailbox.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2005-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Network.Email.Mailbox</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>General support for e-mail mailboxes</p><p>Written by John Goerzen, jgoerzen@complete.org</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">data</span> <a href="#t:Flag">Flag</a><ul class="subs"><li>= <a href="#v:SEEN">SEEN</a></li><li>| <a href="#v:ANSWERED">ANSWERED</a></li><li>| <a href="#v:FLAGGED">FLAGGED</a></li><li>| <a href="#v:DELETED">DELETED</a></li><li>| <a href="#v:DRAFT">DRAFT</a></li><li>| <a href="#v:FORWARDED">FORWARDED</a></li><li>| <a href="#v:OTHERFLAG">OTHERFLAG</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li></ul></li><li class="src short"><span class="keyword">type</span> <a href="#t:Flags">Flags</a> = [<a href="Network-Email-Mailbox.html#t:Flag">Flag</a>]</li><li class="src short"><span class="keyword">type</span> <a href="#t:Message">Message</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><span class="keyword">class</span> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> b, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> b) =&gt; <a href="#t:MailboxReader">MailboxReader</a> a b <span class="keyword">where</span><ul class="subs"><li><a href="#v:listIDs">listIDs</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [b]</li><li><a href="#v:listMessageFlags">listMessageFlags</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [(b, <a href="Network-Email-Mailbox.html#t:Flags">Flags</a>)]</li><li><a href="#v:getAll">getAll</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [(b, <a href="Network-Email-Mailbox.html#t:Flags">Flags</a>, <a href="Network-Email-Mailbox.html#t:Message">Message</a>)]</li><li><a href="#v:getMessages">getMessages</a> :: a -&gt; [b] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [(b, <a href="Network-Email-Mailbox.html#t:Flags">Flags</a>, <a href="Network-Email-Mailbox.html#t:Message">Message</a>)]</li></ul></li><li class="src short"><span class="keyword">class</span> <a href="Network-Email-Mailbox.html#t:MailboxReader">MailboxReader</a> a b =&gt; <a href="#t:MailboxWriter">MailboxWriter</a> a b <span class="keyword">where</span><ul class="subs"><li><a href="#v:appendMessages">appendMessages</a> :: a -&gt; [(<a href="Network-Email-Mailbox.html#t:Flags">Flags</a>, <a href="Network-Email-Mailbox.html#t:Message">Message</a>)] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [b]</li><li><a href="#v:deleteMessages">deleteMessages</a> :: a -&gt; [b] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li><a href="#v:addFlags">addFlags</a> :: a -&gt; [b] -&gt; <a href="Network-Email-Mailbox.html#t:Flags">Flags</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li><a href="#v:removeFlags">removeFlags</a> :: a -&gt; [b] -&gt; <a href="Network-Email-Mailbox.html#t:Flags">Flags</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li><a href="#v:setFlags">setFlags</a> :: a -&gt; [b] -&gt; <a href="Network-Email-Mailbox.html#t:Flags">Flags</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (Line truncated
has a unique identifier <em>b</em> in a format specific to each given mailbox.
This identifier may or may not be persistent.</p><p>Functions which return a list are encouraged -- but not guaranteed -- to
do so lazily.</p><p>Implementing classes must provide, at minimum, <code><a href="Network-Email-Mailbox.html#v:getAll">getAll</a></code>.</p></div><div class="subs minimal"><p class="caption">Minimal complete definition</p><p class="src"><a href="Network-Email-Mailbox.html#v:getAll">getAll</a></p></div><div class="subs methods"><p class="caption">Methods</p><p class="src"><a name="v:listIDs" class="def">listIDs</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [b]</p><div class="doc"><p>Returns a list of all unique identifiers. </p></div><p class="src"><a name="v:listMessageFlags" class="def">listMessageFlags</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [(b, <a href="Network-Email-Mailbox.html#t:Flags">Flags</a>)]</p><div class="doc"><p>Returns a list of all unique identifiers as well as all flags. </p></div><p class="src"><a name="v:getAll" class="def">getAll</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [(b, <a href="Network-Email-Mailbox.html#t:Flags">Flags</a>, <a href="Network-Email-Mailbox.html#t:Message">Message</a>)]</p><div class="doc"><p>Returns a list of all messages, including their content,
flags, and unique identifiers. </p></div><p class="src"><a name="v:getMessages" class="def">getMessages</a> :: a -&gt; [b] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [(b, <a href="Network-Email-Mailbox.html#t:Flags">Flags</a>, <a href="Network-Email-Mailbox.html#t:Message">Message</a>)]</p><div class="doc"><p>Returns information about specific messages. </p></div></div></div><div class="top"><p class="src"><span class="keyword">class</span> <a href="Network-Email-Mailbox.html#t:MailboxReader">MailboxReader</a> a b =&gt; <a name="t:MailboxWriter" class="def">MailboxWriter</a> a b <span class="keyword">where</span></p><div class="subs methods"><p class="caption">Methods</p><p class="src"><a name="v:appendMessages" class="def">appendMessages</a> :: a -&gt; [(<a href="Network-Email-Mailbox.html#t:Flags">Flags</a>, <a href="Network-Email-Mailbox.html#t:Message">Message</a>)] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [b]</p><p class="src"><a name="v:deleteMessages" class="def">deleteMessages</a> :: a -&gt; [b] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><p class="src"><a name="v:addFlags" class="def">addFlags</a> :: a -&gt; [b] -&gt; <a href="Network-Email-Mailbox.html#t:Flags">Flags</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><p class="src"><a name="v:removeFlags" class="def">removeFlags</a> :: a -&gt; [b] -&gt; <a href="Network-Email-Mailbox.html#t:Flags">Flags</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><p class="src"><a name="v:setFlags" class="def">setFlags</a> :: a -&gt; [b] -&gt; <a href="Network-Email-Mailbox.html#t:Flags">Flags</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,9 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Network.Email.Sendmail</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Network-Email-Sendmail.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Network.Email.Sendmail</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This Haskell module provides an interface to transmitting a mail message.</p><p>This is not compatible with Windows at this time.</p><p>Written by John Goerzen, jgoerzen@complete.org</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:sendmail">sendmail</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:sendmail" class="def">sendmail</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>The envelope from address. If not specified, takes the system's default, which is usually based on the effective userid of the current process. This is not necessarily what you want, so I recommend specifying it.</p></td></tr><tr><td class="src">-&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</td><td class="doc"><p>A list of recipients for your message. An empty list is an error.</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>The message itself.</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Transmits an e-mail message using the system's mail transport agent.</p><p>This function takes a message, a list of recipients, and an optional sender,
and transmits it using the system's MTA, sendmail.</p><p>If <code>sendmail</code> is on the <code>PATH</code>, it will be used; otherwise, a list of system
default locations will be searched.</p><p>A failure will be logged, since this function uses <code><a href="System-Cmd-Utils.html#v:safeSystem">safeSystem</a></code>
internally.</p><p>This function will first try <code>sendmail</code>. If it does not exist, an error is
logged under <code>System.Cmd.Utils.pOpen3</code> and various default <code>sendmail</code> locations
are tried. If that still fails, an error is logged and an exception raised.</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,16 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Network.SocketServer</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Network-SocketServer.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>experimental</td></tr><tr><th>Portability</th><td>systems with networking</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Network.SocketServer</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Generic Options and Types</a></li><li><a href="#g:2">TCP server convenient setup</a></li><li><a href="#g:3">Lower-Level Processing</a></li><li><a href="#g:4">Combinators</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This module provides an infrastructure to simplify server design.</p><p>Written by John Goerzen, jgoerzen@complete.org</p><p>Please note: this module is designed to work with TCP, UDP, and Unix domain
sockets, but only TCP sockets have been tested to date.</p><p>This module is presently under-documented. For an example of usage, please
see the description of <a href="Network-FTP-Server.html">Network.FTP.Server</a>.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">data</span> <a href="#t:InetServerOptions">InetServerOptions</a> = <a href="#v:InetServerOptions">InetServerOptions</a> {<ul class="subs"><li><a href="#v:listenQueueSize">listenQueueSize</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></li><li><a href="#v:portNumber">portNumber</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket-Internal.html#t:PortNumber">PortNumber</a></li><li><a href="#v:interface">interface</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket-Internal.html#t:HostAddress">HostAddress</a></li><li><a href="#v:reuse">reuse</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li><a href="#v:family">family</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket-Internal.html#t:Family">Family</a></li><li><a href="#v:sockType">sockType</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket.html#t:SocketType">SocketType</a></li><li><a href="#v:protoStr">protoStr</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li></ul>}</li><li class="src short"><a href="#v:simpleTCPOptions">simpleTCPOptions</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="Network-SocketServer.html#t:InetServerOptions">InetServerOptions</a></li><li class="src short"><span class="keyword">data</span> <a href="#t:SocketServer">SocketServer</a> = <a href="#v:SocketServer">SocketServer</a> {<ul class="subs"><li><a href="#v:optionsSS">optionsSS</a> :: <a href="Network-SocketServer.html#t:InetServerOptions">InetServerOptions</a></li><li><a href="#v:sockSS">sockSS</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket.html#t:Socket">Socket</a></li></ul>}</li><li class="src short"><span class="keyword">type</span> <a href="#t:HandlerT">HandlerT</a> = <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket.html#t:Socket">Socket</a> -&gt; <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket-Internal.html#t:SockAddr">SockAddr</a> -&gt; <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket-Internal.html#t:SockAddr">SockAddr</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:serveTCPforever">serveTCPforever</a> :: <a href="Network-SocketServer.html#t:InetServerOptions">InetServerOptions</a> -&gt; <a href="Network-SocketServer.html#t:HandlerT">HandlerT</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:setupSocketServer">setupSocketServer</a> :: <a href="Network-SocketServer.html#t:InetServerOptions">InetServerOptions</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="Network-SocketServer.html#t:SocketServer">SocketServer</a></li><li class="src short"><a href="#v:handleOne">handleOne</a> :: <a href="Network-SocketServer.html#t:SocketServer">SocketServer</a> -&gt; <a href="Network-SocketServer.html#t:HandlerT">HandlerT</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:serveForever">serveForever</a> :: <a href="Network-SocketServer.html#t:SocketServer">SocketServer</a> -&gt; <a href="Network-SocketServer.html#t:HandlerT">HandlerT</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:closeSocketServer">closeSocketServer</a> :: <a href="Network-SocketServer.html#t:SocketServer">SocketServer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:loggingHandler">loggingHandler</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///Users/Line truncated
<code><a href="Network-SocketServer.html#t:SocketServer">SocketServer</a></code> and handle all incoming requests.</p><p>This function is literally this:</p><pre>serveTCPforever options func =
do sockserv &lt;- setupSocketServer options
serveForever sockserv func</pre></div></div><h1 id="g:3">Lower-Level Processing</h1><div class="top"><p class="src"><a name="v:setupSocketServer" class="def">setupSocketServer</a> :: <a href="Network-SocketServer.html#t:InetServerOptions">InetServerOptions</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="Network-SocketServer.html#t:SocketServer">SocketServer</a></p><div class="doc"><p>Takes some options and sets up the <code><a href="Network-SocketServer.html#t:SocketServer">SocketServer</a></code>. I will bind
and begin listening, but will not accept any connections itself. </p></div></div><div class="top"><p class="src"><a name="v:handleOne" class="def">handleOne</a> :: <a href="Network-SocketServer.html#t:SocketServer">SocketServer</a> -&gt; <a href="Network-SocketServer.html#t:HandlerT">HandlerT</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Handle one incoming request from the given <code><a href="Network-SocketServer.html#t:SocketServer">SocketServer</a></code>. </p></div></div><div class="top"><p class="src"><a name="v:serveForever" class="def">serveForever</a> :: <a href="Network-SocketServer.html#t:SocketServer">SocketServer</a> -&gt; <a href="Network-SocketServer.html#t:HandlerT">HandlerT</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Handle all incoming requests from the given <code><a href="Network-SocketServer.html#t:SocketServer">SocketServer</a></code>. </p></div></div><div class="top"><p class="src"><a name="v:closeSocketServer" class="def">closeSocketServer</a> :: <a href="Network-SocketServer.html#t:SocketServer">SocketServer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Close the socket server. Does not terminate active
handlers, if any. </p></div></div><h1 id="g:4">Combinators</h1><div class="top"><p class="src"><a name="v:loggingHandler" class="def">loggingHandler</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Name of logger to use</p></td></tr><tr><td class="src">-&gt; <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/hslogger-1.2.8/html/System-Log.html#t:Priority">Priority</a></td><td class="doc"><p>Priority of logged messages</p></td></tr><tr><td class="src">-&gt; <a href="Network-SocketServer.html#t:HandlerT">HandlerT</a></td><td class="doc"><p>Handler to call after logging</p></td></tr><tr><td class="src">-&gt; <a href="Network-SocketServer.html#t:HandlerT">HandlerT</a></td><td class="doc"><p>Resulting handler</p></td></tr></table></div><div class="doc"><p>Log each incoming connection using the interface in
<a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/hslogger-1.2.8/html/System-Log-Logger.html">System.Log.Logger</a>.</p><p>Log when the incoming connection disconnects.</p><p>Also, log any failures that may occur in the child handler. </p></div></div><div class="top"><p class="src"><a name="v:threadedHandler" class="def">threadedHandler</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="Network-SocketServer.html#t:HandlerT">HandlerT</a></td><td class="doc"><p>Handler to call in the new thread</p></td></tr><tr><td class="src">-&gt; <a href="Network-SocketServer.html#t:HandlerT">HandlerT</a></td><td class="doc"><p>Resulting handler</p></td></tr></table></div><div class="doc"><p>Handle each incoming connection in its own thread to
make the server multi-tasking.</p></div></div><div class="top"><p class="src"><a name="v:handleHandler" class="def">handleHandler</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a> -&gt; <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket-Internal.html#t:SockAddr">SockAddr</a> -&gt; <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket-Internal.html#t:SockAddr">SockAddr</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ())</td><td class="doc"><p>Handler to call</p></td></tr><tr><td class="src">-&gt; <a href="Network-SocketServer.html#t:HandlerT">HandlerT</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Give your handler function a Handle instead of a Socket.</p><p>The Handle will be opened with ReadWriteMode (you use one handle for both
directions of the Socket). Also, it will be initialized with LineBuffering.</p><p>Unlike other handlers, the handle will be closed when the function returns.
Therefore, if you are doing threading, you should to it before you call this
handler.</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,6 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Network.Utils</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Network-Utils.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>systems with networking</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Network.Utils</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This module provides various helpful utilities for dealing with networking</p><p>Written by John Goerzen, jgoerzen@complete.org</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:niceSocketsDo">niceSocketsDo</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a</li><li class="src short"><a href="#v:connectTCP">connectTCP</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket.html#t:HostName">HostName</a> -&gt; <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket-Internal.html#t:PortNumber">PortNumber</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket.html#t:Socket">Socket</a></li><li class="src short"><a href="#v:connectTCPAddr">connectTCPAddr</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket-Internal.html#t:SockAddr">SockAddr</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket.html#t:Socket">Socket</a></li><li class="src short"><a href="#v:listenTCPAddr">listenTCPAddr</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket-Internal.html#t:SockAddr">SockAddr</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket.html#t:Socket">Socket</a></li><li class="src short"><a href="#v:showSockAddr">showSockAddr</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket-Internal.html#t:SockAddr">SockAddr</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:niceSocketsDo" class="def">niceSocketsDo</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a</p><div class="doc"><p>Sets up the system for networking. Similar to the built-in
withSocketsDo (and actually, calls it), but also sets the SIGPIPE
handler so that signal is ignored.</p><p>Example:</p><pre>main = niceSocketsDo $ do { ... }</pre></div></div><div class="top"><p class="src"><a name="v:connectTCP" class="def">connectTCP</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket.html#t:HostName">HostName</a> -&gt; <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket-Internal.html#t:PortNumber">PortNumber</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket.html#t:Socket">Socket</a></p></div><div class="top"><p class="src"><a name="v:connectTCPAddr" class="def">connectTCPAddr</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket-Internal.html#t:SockAddr">SockAddr</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket.html#t:Socket">Socket</a></p></div><div class="top"><p class="src"><a name="v:listenTCPAddr" class="def">listenTCPAddr</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket-Internal.html#t:SockAddr">SockAddr</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket.html#t:Socket">Socket</a></p></div><div class="top"><p class="src"><a name="v:showSockAddr" class="def">showSockAddr</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/network-2.6.0.2/html/Network-Socket-Internal.html#t:SockAddr">SockAddr</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,51 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.Cmd.Utils</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-Cmd-Utils.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable to platforms with POSIX process\/signal tools</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.Cmd.Utils</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">High-Level Tools</a><ul><li><a href="#g:2">Piping with lazy strings</a></li><li><a href="#g:3">Piping with handles</a></li></ul></li><li><a href="#g:4">Low-Level Tools</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Command invocation utilities.</p><p>Written by John Goerzen, jgoerzen@complete.org</p><p>Please note: Most of this module is not compatible with Hugs.</p><p>Command lines executed will be logged using <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/hslogger-1.2.8/html/System-Log-Logger.html">System.Log.Logger</a> at the
DEBUG level. Failure messages will be logged at the WARNING level in addition
to being raised as an exception. Both are logged under
&quot;System.Cmd.Utils.funcname&quot; -- for instance,
&quot;System.Cmd.Utils.safeSystem&quot;. If you wish to suppress these messages
globally, you can simply run:</p><pre>updateGlobalLogger &quot;System.Cmd.Utils.safeSystem&quot;
(setLevel CRITICAL)</pre><p>See also: <code><a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/hslogger-1.2.8/html/System-Log-Logger.html#v:updateGlobalLogger">updateGlobalLogger</a></code>,
<a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/hslogger-1.2.8/html/System-Log-Logger.html">System.Log.Logger</a>.</p><p>It is possible to set up pipelines with these utilities. Example:</p><pre>(pid1, x1) &lt;- pipeFrom &quot;ls&quot; [&quot;/etc&quot;]
(pid2, x2) &lt;- pipeBoth &quot;grep&quot; [&quot;x&quot;] x1
putStr x2
... the grep output is displayed ...
forceSuccess pid2
forceSuccess pid1</pre><p>Remember, when you use the functions that return a String, you must not call
<code><a href="System-Cmd-Utils.html#v:forceSuccess">forceSuccess</a></code> until after all data from the String has been consumed. Failure
to wait will cause your program to appear to hang.</p><p>Here is an example of the wrong way to do it:</p><pre>(pid, x) &lt;- pipeFrom &quot;ls&quot; [&quot;/etc&quot;]
forceSuccess pid -- Hangs; the called program hasn't terminated yet
processTheData x</pre><p>You must instead process the data before calling <code><a href="System-Cmd-Utils.html#v:forceSuccess">forceSuccess</a></code>.</p><p>When using the hPipe family of functions, this is probably more obvious.</p><p>Most of this module will be incompatible with Windows.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">data</span> <a href="#t:PipeHandle">PipeHandle</a> = <a href="#v:PipeHandle">PipeHandle</a> {<ul class="subs"><li><a href="#v:processID">processID</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:ProcessID">ProcessID</a></li><li><a href="#v:phCommand">phCommand</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a></li><li><a href="#v:phArgs">phArgs</a> :: [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</li><li><a href="#v:phCreator">phCreator</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li></ul>}</li><li class="src short"><a href="#v:safeSystem">safeSystem</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:forceSuccess">forceSuccess</a> :: <a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:posixRawSystem">posixRawSystem</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/unix-2.7.1.0/System-Posix-Process-Internals.html#t:ProcessStatus">ProcessStatus</a></li><li class="src short"><a href="#v:forkRawSystem">forkRawSystem</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:ProcessID">ProcessID</a></li><li class="src short"><a href="#v:pipeFrom">pipeFrom</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</li><li class="src short"><a href="#v:pipeLinesFrom">pipeLinesFrom</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a>, [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>])</li><li class="src short"><a href="#v:pipeTo">pipeTo</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a></li><li class="src short"><a href="#v:pipeBoth">pipeBoth</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0Line truncated
<code><a href="System-Cmd-Utils.html#v:pipeBoth">pipeBoth</a></code>. Contains both a ProcessID and the original command that was
executed. If you prefer not to use <code><a href="System-Cmd-Utils.html#v:forceSuccess">forceSuccess</a></code> on the result of one
of these pipe calls, you can use (processID ph), assuming ph is your <code><a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a></code>,
as a parameter to <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/unix-2.7.1.0/System-Posix-Process-ByteString.html#v:getProcessStatus">getProcessStatus</a></code>. </p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:PipeHandle" class="def">PipeHandle</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div class="subs fields"><p class="caption">Fields</p><dl><dt class="src"><a name="v:processID" class="def">processID</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:ProcessID">ProcessID</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:phCommand" class="def">phCommand</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:phArgs" class="def">phArgs</a> :: [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:phCreator" class="def">phCreator</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></dt><dd class="doc"><p>Function that created it</p></dd></dl><div class="clear"></div></div></td></tr></table></div><div class="subs instances"><p id="control.i:PipeHandle" class="caption collapser" onclick="toggleSection('i:PipeHandle')">Instances</p><div id="section.i:PipeHandle" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> <a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><a name="v:safeSystem" class="def">safeSystem</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Invokes the specified command in a subprocess, waiting for the result.
If the command terminated successfully, return normally. Otherwise,
raises a userError with the problem.</p><p>Implemented in terms of <code><a href="System-Cmd-Utils.html#v:posixRawSystem">posixRawSystem</a></code> where supported, and System.Posix.rawSystem otherwise.</p></div></div><div class="top"><p class="src"><a name="v:forceSuccess" class="def">forceSuccess</a> :: <a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Uses <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/unix-2.7.1.0/System-Posix-Process-ByteString.html#v:getProcessStatus">getProcessStatus</a></code> to obtain the exit status
of the given process ID. If the process terminated normally, does nothing.
Otherwise, raises an exception with an appropriate error message.</p><p>This call will block waiting for the given pid to terminate.</p><p>Not available on Windows. </p></div></div><div class="top"><p class="src"><a name="v:posixRawSystem" class="def">posixRawSystem</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/unix-2.7.1.0/System-Posix-Process-Internals.html#t:ProcessStatus">ProcessStatus</a></p><div class="doc"><p>Invokes the specified command in a subprocess, waiting for the result.
Return the result status. Never raises an exception. Only available
on POSIX platforms.</p><p>Like system(3), this command ignores SIGINT and SIGQUIT and blocks SIGCHLD
during its execution.</p><p>Logs as System.Cmd.Utils.posixRawSystem </p></div></div><div class="top"><p class="src"><a name="v:forkRawSystem" class="def">forkRawSystem</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:ProcessID">ProcessID</a></p><div class="doc"><p>Invokes the specified command in a subprocess, without waiting for
the result. Returns the PID of the subprocess -- it is YOUR responsibility
to use getProcessStatus or getAnyProcessStatus on that at some point. Failure
to do so will lead to resource leakage (zombie processes).</p><p>This function does nothing with signals. That too is up to you.</p><p>Logs as System.Cmd.Utils.forkRawSystem </p></div></div><h2 id="g:2">Piping with lazy strings</h2><div class="top"><p class="src"><a name="v:pipeFrom" class="def">pipeFrom</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</p><div class="doc"><p>Read data from a pipe. Returns a lazy string and a <code><a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a></code>.</p><p>ONLY AFTER the string has been read completely, You must call either
<code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/unix-2.7.1.0/System-Posix-Process-ByteString.html#v:getProcessStatus">getProcessStatus</a></code> or <code><a href="System-Cmd-Utils.html#v:forceSuccess">forceSuccess</a></code> on the <code><a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a></code>.
Zombies will result otherwise.</p><p>Not available on Windows.</p></div></div><div class="top"><p class="src"><a name="v:pipeLinesFrom" class="def">pipeLinesFrom</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a>, [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>])</p><div class="doc"><p>Like <code><a href="System-Cmd-Utils.html#v:pipeFrom">pipeFrom</a></code>, but returns data in lines instead of just a String.
Shortcut for calling lines on the result from <code><a href="System-Cmd-Utils.html#v:pipeFrom">pipeFrom</a></code>.</p><p>Note: this function logs as pipeFrom.</p><p>Not available on Windows. </p></div></div><div class="top"><p class="src"><a name="v:pipeTo" class="def">pipeTo</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a></p><div class="doc"><p>Write data to a pipe. Returns a ProcessID.</p><p>You must call either
<code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/unix-2.7.1.0/System-Posix-Process-ByteString.html#v:getProcessStatus">getProcessStatus</a></code> or <code><a href="System-Cmd-Utils.html#v:forceSuccess">forceSuccess</a></code> on the ProcessID.
Zombies will result otherwise.</p><p>Not available on Windows.</p></div></div><div class="top"><p class="src"><a name="v:pipeBoth" class="def">pipeBoth</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</p><div class="doc"><p>Like a combination of <code><a href="System-Cmd-Utils.html#v:pipeTo">pipeTo</a></code> and <code><a href="System-Cmd-Utils.html#v:pipeFrom">pipeFrom</a></code>; forks an IO thread
to send data to the piped program, and simultaneously returns its output
stream.</p><p>The same note about checking the return status applies here as with <code><a href="System-Cmd-Utils.html#v:pipeFrom">pipeFrom</a></code>.</p><p>Not available on Windows. </p></div></div><h2 id="g:3">Piping with handles</h2><div class="top"><p class="src"><a name="v:hPipeFrom" class="def">hPipeFrom</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a>)</p><div class="doc"><p>Read data from a pipe. Returns a Handle and a <code><a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a></code>.</p><p>When done, you must hClose the handle, and then use either <code><a href="System-Cmd-Utils.html#v:forceSuccess">forceSuccess</a></code> or
getProcessStatus on the <code><a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a></code>. Zombies will result otherwise.</p><p>This function logs as pipeFrom.</p><p>Not available on Windows or with Hugs.</p></div></div><div class="top"><p class="src"><a name="v:hPipeTo" class="def">hPipeTo</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a>)</p><div class="doc"><p>Write data to a pipe. Returns a <code><a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a></code> and a new Handle to write
to.</p><p>When done, you must hClose the handle, and then use either <code><a href="System-Cmd-Utils.html#v:forceSuccess">forceSuccess</a></code> or
getProcessStatus on the <code><a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a></code>. Zombies will result otherwise.</p><p>This function logs as pipeTo.</p><p>Not available on Windows.</p></div></div><div class="top"><p class="src"><a name="v:hPipeBoth" class="def">hPipeBoth</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a>)</p><div class="doc"><p>Like a combination of <code><a href="System-Cmd-Utils.html#v:hPipeTo">hPipeTo</a></code> and <code><a href="System-Cmd-Utils.html#v:hPipeFrom">hPipeFrom</a></code>; returns
a 3-tuple of (<code><a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a></code>, Data From Pipe, Data To Pipe).</p><p>When done, you must hClose both handles, and then use either <code><a href="System-Cmd-Utils.html#v:forceSuccess">forceSuccess</a></code> or
getProcessStatus on the <code><a href="System-Cmd-Utils.html#t:PipeHandle">PipeHandle</a></code>. Zombies will result otherwise.</p><p>Hint: you will usually need to ForkIO a thread to handle one of the Handles;
otherwise, deadlock can result.</p><p>This function logs as pipeBoth.</p><p>Not available on Windows.</p></div></div><h1 id="g:4">Low-Level Tools</h1><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:PipeMode" class="def">PipeMode</a></p><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:ReadFromPipe" class="def">ReadFromPipe</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a name="v:WriteToPipe" class="def">WriteToPipe</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div><div class="top"><p class="src"><a name="v:pOpen" class="def">pOpen</a> :: <a href="System-Cmd-Utils.html#t:PipeMode">PipeMode</a> -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a</p><div class="doc"><p>Open a pipe to the specified command.</p><p>Passes the handle on to the specified function.</p><p>The <code><a href="System-Cmd-Utils.html#t:PipeMode">PipeMode</a></code> specifies what you will be doing. That is, specifing <code><a href="System-Cmd-Utils.html#v:ReadFromPipe">ReadFromPipe</a></code>
sets up a pipe from stdin, and <code><a href="System-Cmd-Utils.html#v:WriteToPipe">WriteToPipe</a></code> sets up a pipe from stdout.</p><p>Not available on Windows.</p></div></div><div class="top"><p class="src"><a name="v:pOpen3" class="def">pOpen3</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:Fd">Fd</a></td><td class="doc"><p>Send stdin to this fd</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:Fd">Fd</a></td><td class="doc"><p>Get stdout from this fd</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:Fd">Fd</a></td><td class="doc"><p>Get stderr from this fd</p></td></tr><tr><td class="src">-&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a></td><td class="doc"><p>Command to run</p></td></tr><tr><td class="src">-&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</td><td class="doc"><p>Command args</p></td></tr><tr><td class="src">-&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:ProcessID">ProcessID</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a)</td><td class="doc"><p>Action to run in parent</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</td><td class="doc"><p>Action to run in child before execing (if you don't need something, set this to <code>return ()</code>) -- IGNORED IN HUGS</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a</td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Runs a command, redirecting things to pipes.</p><p>Not available on Windows.</p><p>Note that you may not use the same fd on more than one item. If you
want to redirect stdout and stderr, dup it first.</p></div></div><div class="top"><p class="src"><a name="v:pOpen3Raw" class="def">pOpen3Raw</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:Fd">Fd</a></td><td class="doc"><p>Send stdin to this fd</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:Fd">Fd</a></td><td class="doc"><p>Get stdout from this fd</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:Fd">Fd</a></td><td class="doc"><p>Get stderr from this fd</p></td></tr><tr><td class="src">-&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a></td><td class="doc"><p>Command to run</p></td></tr><tr><td class="src">-&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</td><td class="doc"><p>Command args</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</td><td class="doc"><p>Action to run in child before execing (if you don't need something, set this to <code>return ()</code>) -- IGNORED IN HUGS</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:ProcessID">ProcessID</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Runs a command, redirecting things to pipes.</p><p>Not available on Windows.</p><p>Returns immediately with the PID of the child. Using <code>waitProcess</code> on it
is YOUR responsibility!</p><p>Note that you may not use the same fd on more than one item. If you
want to redirect stdout and stderr, dup it first.</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,13 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.Console.GetOpt.Utils</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-Console-GetOpt-Utils.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2005-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.Console.GetOpt.Utils</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Written by John Goerzen, jgoerzen@complete.org</p><p>Utilities for command-line parsing, including wrappers around
the standard System.Console.GetOpt module.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:parseCmdLine">parseCmdLine</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Console-GetOpt.html#t:ArgOrder">ArgOrder</a> a -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Console-GetOpt.html#t:OptDescr">OptDescr</a> a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ([a], [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>])</li><li class="src short"><a href="#v:validateCmdLine">validateCmdLine</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Console-GetOpt.html#t:ArgOrder">ArgOrder</a> a -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Console-GetOpt.html#t:OptDescr">OptDescr</a> a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; (([a], [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ([a], [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>])</li><li class="src short"><span class="keyword">type</span> <a href="#t:StdOption">StdOption</a> = (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</li><li class="src short"><a href="#v:stdRequired">stdRequired</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="System-Console-GetOpt-Utils.html#t:StdOption">StdOption</a></li><li class="src short"><a href="#v:stdOptional">stdOptional</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="System-Console-GetOpt-Utils.html#t:StdOption">StdOption</a></li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:parseCmdLine" class="def">parseCmdLine</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Console-GetOpt.html#t:ArgOrder">ArgOrder</a> a -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Console-GetOpt.html#t:OptDescr">OptDescr</a> a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ([a], [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>])</p><div class="doc"><p>Simple command line parser -- a basic wrapper around the system's
default getOpt. See the System.Console.GetOpt manual for a description of the
first two parameters.</p><p>The third parameter is a usage information header.</p><p>The return value consists of the list of parsed flags and a list of
non-option arguments. </p></div></div><div class="top"><p class="src"><a name="v:validateCmdLine" class="def">validateCmdLine</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Console-GetOpt.html#t:ArgOrder">ArgOrder</a> a -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Console-GetOpt.html#t:OptDescr">OptDescr</a> a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; (([a], [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ([a], [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>])</p><div class="doc"><p>Similar to <code><a href="System-Console-GetOpt-Utils.html#v:parseCmdLine">parseCmdLine</a></code>, but takes an additional function that validates
the post-parse command-line arguments. This is useful, for example, in
situations where there are two arguments that are mutually-exclusive and only
one may legitimately be given at a time.</p><p>The return value of the function indicates whether or not it detected an
error condition. If it returns Nothing, there is no error. If it returns
Just String, there was an error, described by the String.</p></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:StdOption" class="def">StdOption</a> = (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</p><div class="doc"><p>A type to standardize some common uses of GetOpt.</p><p>The first component of the tuple is the long name of the option.</p><p>The second component is empty if there is no arg, or has the arg otherwise. </p></div></div><div class="top"><p class="src"><a name="v:stdRequired" class="def">stdRequired</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Name of arg</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">-&gt; <a href="System-Console-GetOpt-Utils.html#t:StdOption">StdOption</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Handle a required argument. </p></div></div><div class="top"><p class="src"><a name="v:stdOptional" class="def">stdOptional</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Name of arg</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">-&gt; <a href="System-Console-GetOpt-Utils.html#t:StdOption">StdOption</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Handle an optional argument. </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,9 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.Daemon</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-Daemon.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2005-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable to platforms with POSIX process\/signal tools</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.Daemon</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Tools for writing daemons/server processes</p><p>Written by John Goerzen, jgoerzen@complete.org</p><p>Please note: Most of this module is not compatible with Hugs.</p><p>Messages from this module are logged under <code>System.Daemon</code>. See
<code><a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/hslogger-1.2.8/html/System-Log.html#t:Logger">Logger</a></code> for details.</p><p>Based on background
from <a href="http://www.erlenstar.demon.co.uk/unix/faq_2.html#SEC16">http://www.erlenstar.demon.co.uk/unix/faq_2.html#SEC16</a> and
<a href="http://www.haskell.org/hawiki/HaskellUnixDaemon">http://www.haskell.org/hawiki/HaskellUnixDaemon</a>.</p><p>This module is not available on Windows.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:detachDaemon">detachDaemon</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:detachDaemon" class="def">detachDaemon</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Detach the process from a controlling terminal and run it in the
background, handling it with standard Unix deamon semantics.</p><p>After running this, please note the following side-effects:</p><ul><li>The PID of the running process will change</li><li>stdin, stdout, and stderr will not work (they'll be set to
/dev/null)</li><li>CWD will be changed to /</li></ul><p>I <em>highly</em> suggest running this function before starting any threads.</p><p>Note that this is not intended for a daemon invoked from inetd(1).</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,5 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.Debian.ControlParser</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-Debian-ControlParser.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.Debian.ControlParser</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This module provides various helpful utilities for dealing with Debian
files and programs.</p><p>Written by John Goerzen, jgoerzen@complete.org</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:control">control</a> :: CharParser a [(<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)]</li><li class="src short"><a href="#v:depPart">depPart</a> :: CharParser a (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>), [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>])</li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:control" class="def">control</a> :: CharParser a [(<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)]</p><div class="doc"><p>Main parser for the control file </p></div></div><div class="top"><p class="src"><a name="v:depPart" class="def">depPart</a> :: CharParser a (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>), [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>])</p><div class="doc"><p>Dependency parser.</p><p>Returns (package name, Maybe version, arch list)</p><p>version is (operator, operand) </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,7 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.Debian</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-Debian.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.Debian</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Control or Similar File Utilities</a></li><li><a href="#g:2">Version Number Utilities</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This module provides various helpful utilities for dealing with Debian
files and programs.</p><p>Written by John Goerzen, jgoerzen@complete.org</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">type</span> <a href="#t:ControlFile">ControlFile</a> = [(<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)]</li><li class="src short"><span class="keyword">data</span> <a href="#t:DebVersion">DebVersion</a></li><li class="src short"><a href="#v:compareDebVersion">compareDebVersion</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ordering">Ordering</a></li><li class="src short"><a href="#v:checkDebVersion">checkDebVersion</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li></ul></div><div id="interface"><h1 id="g:1">Control or Similar File Utilities</h1><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:ControlFile" class="def">ControlFile</a> = [(<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)]</p><div class="doc"><p>The type representing the contents of a Debian control file,
or any control-like file (such as the output from apt-cache show, etc.) </p></div></div><h1 id="g:2">Version Number Utilities</h1><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:DebVersion" class="def">DebVersion</a></p><div class="doc"><p>The type representing a Debian version number. This type is an instance
of <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a></code>, but you can also use <code><a href="System-Debian.html#v:compareDebVersion">compareDebVersion</a></code> if you prefer. </p></div><div class="subs instances"><p id="control.i:DebVersion" class="caption collapser" onclick="toggleSection('i:DebVersion')">Instances</p><div id="section.i:DebVersion" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> <a href="System-Debian.html#t:DebVersion">DebVersion</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> <a href="System-Debian.html#t:DebVersion">DebVersion</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><a name="v:compareDebVersion" class="def">compareDebVersion</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ordering">Ordering</a></p><div class="doc"><p>Compare the versions of two packages. </p></div></div><div class="top"><p class="src"><a name="v:checkDebVersion" class="def">checkDebVersion</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Version 1</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Operator</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Version 2</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,25 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.FileArchive.GZip</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-FileArchive-GZip.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.FileArchive.GZip</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">GZip Files</a></li><li><a href="#g:2">Types</a></li><li><a href="#g:3">Whole-File Processing</a></li><li><a href="#g:4">Section Processing</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>GZip file decompression</p><p>Copyright (c) 2004 John Goerzen, jgoerzen@complete.org</p><p>The GZip format is described in RFC1952.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">data</span> <a href="#t:Header">Header</a> = <a href="#v:Header">Header</a> {<ul class="subs"><li><a href="#v:method">method</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></li><li><a href="#v:flags">flags</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></li><li><a href="#v:extra">extra</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li><a href="#v:filename">filename</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li><a href="#v:comment">comment</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li><a href="#v:mtime">mtime</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a></li><li><a href="#v:xfl">xfl</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></li><li><a href="#v:os">os</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></li></ul>}</li><li class="src short"><span class="keyword">type</span> <a href="#t:Section">Section</a> = (<a href="System-FileArchive-GZip.html#t:Header">Header</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="System-FileArchive-GZip.html#t:Footer">Footer</a>)</li><li class="src short"><span class="keyword">data</span> <a href="#t:GZipError">GZipError</a><ul class="subs"><li>= <a href="#v:CRCError">CRCError</a></li><li>| <a href="#v:NotGZIPFile">NotGZIPFile</a></li><li>| <a href="#v:UnknownMethod">UnknownMethod</a></li><li>| <a href="#v:UnknownError">UnknownError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li></ul></li><li class="src short"><span class="keyword">data</span> <a href="#t:Footer">Footer</a> = <a href="#v:Footer">Footer</a> {<ul class="subs"><li><a href="#v:size">size</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a></li><li><a href="#v:crc32">crc32</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a></li><li><a href="#v:crc32valid">crc32valid</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li></ul>}</li><li class="src short"><a href="#v:decompress">decompress</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8Line truncated
with a GZip <code><a href="System-FileArchive-GZip.html#t:Header">Header</a></code>, then stores the compressed data itself, and finally
stores a GZip <code><a href="System-FileArchive-GZip.html#t:Footer">Footer</a></code>.</p><p>The <code><a href="System-FileArchive-GZip.html#t:Header">Header</a></code> identifies the file as a GZip file, records the original
modification date and time, and, in some cases, also records the original
filename and comments.</p><p>The <code><a href="System-FileArchive-GZip.html#t:Footer">Footer</a></code> contains a GZip CRC32 checksum over the decompressed data as
well as a 32-bit length of the decompressed data. The module
<code><a href="Data-Hash-CRC32.html#t:GZip">GZip</a></code> is used to validate stored CRC32 values.</p><p>The vast majority of GZip files contain only one <code><a href="System-FileArchive-GZip.html#t:Section">Section</a></code>. Standard tools
that work with GZip files create single-section files by default.</p><p>Multi-section files can be created by simply concatenating two existing
GZip files together. The standard gunzip and zcat tools will simply
concatenate the decompressed data when reading these files back. The
<code><a href="System-FileArchive-GZip.html#v:decompress">decompress</a></code> function in this module will do the same.</p><p>When reading data from this module, please use caution regarding how you access
it. For instance, if you are wanting to write the decompressed stream
to disk and validate its CRC32 value, you could use the <code><a href="System-FileArchive-GZip.html#v:decompress">decompress</a></code>
function. However, you should process the entire stream before you check
the value of the Bool it returns. Otherwise, you will force Haskell to buffer
the entire file in memory just so it can check the CRC32.</p></div><h1 id="g:2">Types</h1><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:Header" class="def">Header</a></p><div class="doc"><p>The data structure representing the GZip header. This occurs
at the beginning of each <code><a href="System-FileArchive-GZip.html#t:Section">Section</a></code> on disk. </p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:Header" class="def">Header</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div class="subs fields"><p class="caption">Fields</p><dl><dt class="src"><a name="v:method" class="def">method</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></dt><dd class="doc"><p>Compression method. Only 8 is defined at present.</p></dd><dt class="src"><a name="v:flags" class="def">flags</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:extra" class="def">extra</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:filename" class="def">filename</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:comment" class="def">comment</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:mtime" class="def">mtime</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a></dt><dd class="doc"><p>Modification time of the original file</p></dd><dt class="src"><a name="v:xfl" class="def">xfl</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></dt><dd class="doc"><p>Extra flags</p></dd><dt class="src"><a name="v:os" class="def">os</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></dt><dd class="doc"><p>Creating operating system</p></dd></dl><div class="clear"></div></div></td></tr></table></div><div class="subs instances"><p id="control.i:Header" class="caption collapser" onclick="toggleSection('i:Header')">Instances</p><div id="section.i:Header" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> <a href="System-FileArchive-GZip.html#t:Header">Header</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="System-FileArchive-GZip.html#t:Header">Header</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:Section" class="def">Section</a> = (<a href="System-FileArchive-GZip.html#t:Header">Header</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="System-FileArchive-GZip.html#t:Footer">Footer</a>)</p><div class="doc"><p>A section represents a compressed component in a GZip file.
Every GZip file has at least one. </p></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:GZipError" class="def">GZipError</a></p><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:CRCError" class="def">CRCError</a></td><td class="doc"><p>CRC-32 check failed</p></td></tr><tr><td class="src"><a name="v:NotGZIPFile" class="def">NotGZIPFile</a></td><td class="doc"><p>Couldn't find a GZip header</p></td></tr><tr><td class="src"><a name="v:UnknownMethod" class="def">UnknownMethod</a></td><td class="doc"><p>Compressed with something other than method 8 (deflate)</p></td></tr><tr><td class="src"><a name="v:UnknownError" class="def">UnknownError</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Other problem arose</p></td></tr></table></div><div class="subs instances"><p id="control.i:GZipError" class="caption collapser" onclick="toggleSection('i:GZipError')">Instances</p><div id="section.i:GZipError" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> <a href="System-FileArchive-GZip.html#t:GZipError">GZipError</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="System-FileArchive-GZip.html#t:GZipError">GZipError</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/transformers-0.4.2.0/Control-Monad-Trans-Error.html#t:Error">Error</a> <a href="System-FileArchive-GZip.html#t:GZipError">GZipError</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:Footer" class="def">Footer</a></p><div class="doc"><p>Stored on-disk at the end of each section. </p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:Footer" class="def">Footer</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div class="subs fields"><p class="caption">Fields</p><dl><dt class="src"><a name="v:size" class="def">size</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a></dt><dd class="doc"><p>The size of the original, decompressed data</p></dd><dt class="src"><a name="v:crc32" class="def">crc32</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word32">Word32</a></dt><dd class="doc"><p>The stored GZip CRC-32 of the original, decompressed data</p></dd><dt class="src"><a name="v:crc32valid" class="def">crc32valid</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></dt><dd class="doc"><p>Whether or not the stored CRC-32 matches the calculated CRC-32 of the data</p></dd></dl><div class="clear"></div></div></td></tr></table></div></div><h1 id="g:3">Whole-File Processing</h1><div class="top"><p class="src"><a name="v:decompress" class="def">decompress</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="System-FileArchive-GZip.html#t:GZipError">GZipError</a>)</p><div class="doc"><p>Read a GZip file, decompressing all sections that are found.</p><p>Returns a decompresed data stream and Nothing, or an unreliable string
and Just (error). If you get anything other than Nothing, the String
returned should be discarded.</p></div></div><div class="top"><p class="src"><a name="v:hDecompress" class="def">hDecompress</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a></td><td class="doc"><p>Input handle</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a></td><td class="doc"><p>Output handle</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="System-FileArchive-GZip.html#t:GZipError">GZipError</a>)</td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Read a GZip file, decompressing all sections found.</p><p>Writes the decompressed data stream to the given output handle.</p><p>Returns Nothing if the action was successful, or Just GZipError if there
was a problem. If there was a problem, the data written to the output
handle should be discarded.</p></div></div><div class="top"><p class="src"><a name="v:read_sections" class="def">read_sections</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> <a href="System-FileArchive-GZip.html#t:GZipError">GZipError</a> [<a href="System-FileArchive-GZip.html#t:Section">Section</a>]</p><div class="doc"><p>Read all sections.</p></div></div><h1 id="g:4">Section Processing</h1><div class="top"><p class="src"><a name="v:read_header" class="def">read_header</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> <a href="System-FileArchive-GZip.html#t:GZipError">GZipError</a> (<a href="System-FileArchive-GZip.html#t:Header">Header</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</p><div class="doc"><p>Read the GZip header. Return (Header, Remainder).</p></div></div><div class="top"><p class="src"><a name="v:read_section" class="def">read_section</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Either.html#t:Either">Either</a> <a href="System-FileArchive-GZip.html#t:GZipError">GZipError</a> (<a href="System-FileArchive-GZip.html#t:Section">Section</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</p><div class="doc"><p>Read one section, returning (ThisSection, Remainder)</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,45 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.IO.Binary</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-IO-Binary.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable to platforms supporting binary I\/O</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.IO.Binary</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Support for different types of blocks</a></li><li><a href="#g:2">Entire File/Handle Utilities</a><ul><li><a href="#g:3">Opened Handle Data Copying</a></li><li><a href="#g:4">Disk File Data Copying</a></li></ul></li><li><a href="#g:5">Binary Single-Block I/O</a></li><li><a href="#g:6">Binary Multi-Block I/O</a></li><li><a href="#g:7">Lazy Interaction</a><ul><li><a href="#g:8">Binary Block-based</a></li></ul></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This module provides various helpful utilities for dealing with binary
input and output.</p><p>You can use this module to deal with binary blocks of data as either Strings
or lists of Word8. The BinaryConvertible class provides this abstraction.</p><p>Wherever you see HVIO, you can transparently substite a regular Handle.
This module can work with any HVIO object, however. See
<a href="System-IO-HVIO.html">System.IO.HVIO</a> for more details.</p><p>Versions of MissingH prior 0.11.6 lacked the <code><a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a></code> class
and worked only with Strings and Handles.</p><p>Important note: /binary functions are not supported in all Haskell
implementations/. Do not import or use this module unless you know you
are using an implementation that supports them. At this time, here
is the support status:</p><ul><li>GHC 6.2 and above: yes</li><li>GHC 6.x, earlier versions: unknown</li><li>GHC 5.x: no</li><li>nhc98: no</li><li>Hugs: partial (maybe complete; needs more testing)</li></ul><p>Non-binary functions may be found in <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html">System.IO</a>.</p><p>See also: <a href="System-IO-BlockIO.html">System.IO.BlockIO</a></p><p>Written by John Goerzen, jgoerzen@complete.org</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">class</span> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a) =&gt; <a href="#t:BinaryConvertible">BinaryConvertible</a> a <span class="keyword">where</span><ul class="subs"><li><a href="#v:toBuf">toBuf</a> :: [a] -&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Foreign-Ptr.html#t:Ptr">Ptr</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Foreign-C-Types.html#t:CChar">CChar</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> c) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> c</li><li><a href="#v:fromBuf">fromBuf</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Foreign-Ptr.html#t:Ptr">Ptr</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Foreign-C-Types.html#t:CChar">CChar</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a>) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [a]</li></ul></li><li class="src short"><a href="#v:hBlockCopy">hBlockCopy</a> :: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a, <a href="System-IO-HVIO.html#t:HVIO">HVIO</a> b) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; a -&gt; b -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:blockCopy">blockCopy</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:copyFileBlocksToFile">copyFileBlocksToFile</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:hPutBufStr">hPutBufStr</a> :: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a, <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> b) =&gt; a -&gt; [b] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:putBufStr">putBufStr</a> :: <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> b =&gt; [b] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:hGetBufStr">hGetBufStr</a> :: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a, <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> b) =&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [b]</li><li class="src short"><a href="#v:getBufStr">getBufStr</a> :: <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> b =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/Line truncated
types.</p><p>This module provides implementations for Strings and for [Word8] (lists of
Word8s). </p></div><div class="subs methods"><p class="caption">Methods</p><p class="src"><a name="v:toBuf" class="def">toBuf</a> :: [a] -&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Foreign-Ptr.html#t:Ptr">Ptr</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Foreign-C-Types.html#t:CChar">CChar</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> c) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> c</p><p class="src"><a name="v:fromBuf" class="def">fromBuf</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Foreign-Ptr.html#t:Ptr">Ptr</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Foreign-C-Types.html#t:CChar">CChar</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a>) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [a]</p></div><div class="subs instances"><p id="control.i:BinaryConvertible" class="caption collapser" onclick="toggleSection('i:BinaryConvertible')">Instances</p><div id="section.i:BinaryConvertible" class="show"><table><tr><td class="src"><a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Char.html#t:Char">Char</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Word.html#t:Word8">Word8</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><h1 id="g:2">Entire File/Handle Utilities</h1><h2 id="g:3">Opened Handle Data Copying</h2><div class="top"><p class="src"><a name="v:hBlockCopy" class="def">hBlockCopy</a> :: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a, <a href="System-IO-HVIO.html#t:HVIO">HVIO</a> b) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; a -&gt; b -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Copies everything from the input handle to the output handle using binary
blocks of the given size. This was once the following
beautiful implementation:</p><pre>hBlockCopy bs hin hout = hBlockInteract bs hin hout id</pre><p>(<code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Function.html#v:id">id</a></code> is the built-in Haskell function that just returns whatever is given
to it)</p><p>In more recent versions of MissingH, it uses a more optimized routine that
avoids ever having to convert the binary buffer at all.</p></div></div><div class="top"><p class="src"><a name="v:blockCopy" class="def">blockCopy</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Copies from <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:stdin">stdin</a></code> to <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:stdout">stdout</a></code> using binary blocks of the given size.
An alias for <code><a href="System-IO-Binary.html#v:hBlockCopy">hBlockCopy</a></code> over <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:stdin">stdin</a></code> and <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:stdout">stdout</a></code></p></div></div><h2 id="g:4">Disk File Data Copying</h2><div class="top"><p class="src"><a name="v:copyFileBlocksToFile" class="def">copyFileBlocksToFile</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Copies one filename to another in binary mode.</p><p>Please note that the Unix permission bits on the output file cannot
be set due to a limitation of the Haskell <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:openBinaryFile">openBinaryFile</a></code>
function. Therefore, you may need to adjust those bits after the copy
yourself.</p><p>This function is implemented using <code><a href="System-IO-Binary.html#v:hBlockCopy">hBlockCopy</a></code> internally. </p></div></div><h1 id="g:5">Binary Single-Block I/O</h1><div class="top"><p class="src"><a name="v:hPutBufStr" class="def">hPutBufStr</a> :: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a, <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> b) =&gt; a -&gt; [b] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>As a wrapper around the standard function <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#v:hPutBuf">hPutBuf</a></code>,
this function takes a standard Haskell <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></code> instead of the far less
convenient <code>Ptr a</code>. The entire contents of the string will be written
as a binary buffer using <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#v:hPutBuf">hPutBuf</a></code>. The length of the output will be
the length of the passed String or list.</p><p>If it helps, you can thing of this function as being of type
<code>Handle -&gt; String -&gt; IO ()</code> </p></div></div><div class="top"><p class="src"><a name="v:putBufStr" class="def">putBufStr</a> :: <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> b =&gt; [b] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>An alias for <code><a href="System-IO-Binary.html#v:hPutBufStr">hPutBufStr</a></code> <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:stdout">stdout</a></code></p></div></div><div class="top"><p class="src"><a name="v:hGetBufStr" class="def">hGetBufStr</a> :: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a, <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> b) =&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [b]</p><div class="doc"><p>Acts a wrapper around the standard function <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#v:hGetBuf">hGetBuf</a></code>,
this function returns a standard Haskell String (or [Word8]) instead of
modifying
a 'Ptr a' buffer. The length is the maximum length to read and the
semantice are the same as with <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#v:hGetBuf">hGetBuf</a></code>; namely, the empty string
is returned with EOF is reached, and any given read may read fewer
bytes than the given length.</p><p>(Actually, it's a wrapper around <code><a href="System-IO-HVIO.html#v:vGetBuf">vGetBuf</a></code>) </p></div></div><div class="top"><p class="src"><a name="v:getBufStr" class="def">getBufStr</a> :: <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> b =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [b]</p><div class="doc"><p>An alias for <code><a href="System-IO-Binary.html#v:hGetBufStr">hGetBufStr</a></code> <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:stdin">stdin</a></code></p></div></div><div class="top"><p class="src"><a name="v:hFullGetBufStr" class="def">hFullGetBufStr</a> :: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a, <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> b) =&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [b]</p><div class="doc"><p>Like <code><a href="System-IO-Binary.html#v:hGetBufStr">hGetBufStr</a></code>, but guarantees that it will only return fewer than
the requested number of bytes when EOF is encountered. </p></div></div><div class="top"><p class="src"><a name="v:fullGetBufStr" class="def">fullGetBufStr</a> :: <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> b =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [b]</p><div class="doc"><p>An alias for <code><a href="System-IO-Binary.html#v:hFullGetBufStr">hFullGetBufStr</a></code> <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:stdin">stdin</a></code></p></div></div><h1 id="g:6">Binary Multi-Block I/O</h1><div class="top"><p class="src"><a name="v:hGetBlocks" class="def">hGetBlocks</a> :: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a, <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> b) =&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [[b]]</p><div class="doc"><p>An alias for <code>hPutBlocks</code> <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:stdout">stdout</a></code>
putBlocks :: (BinaryConvertible b) =&gt; [[b]] -&gt; IO ()
putBlocks = hPutBlocks stdout </p><p>Returns a lazily-evaluated list of all blocks in the input file,
as read by <code><a href="System-IO-Binary.html#v:hGetBufStr">hGetBufStr</a></code>. There will be no 0-length block in this list.
The list simply ends at EOF. </p></div></div><div class="top"><p class="src"><a name="v:getBlocks" class="def">getBlocks</a> :: <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> b =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [[b]]</p><div class="doc"><p>An alias for <code><a href="System-IO-Binary.html#v:hGetBlocks">hGetBlocks</a></code> <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:stdin">stdin</a></code></p></div></div><div class="top"><p class="src"><a name="v:hFullGetBlocks" class="def">hFullGetBlocks</a> :: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a, <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> b) =&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [[b]]</p><div class="doc"><p>Same as <code><a href="System-IO-Binary.html#v:hGetBlocks">hGetBlocks</a></code>, but using <code><a href="System-IO-Binary.html#v:hFullGetBufStr">hFullGetBufStr</a></code> underneath. </p></div></div><div class="top"><p class="src"><a name="v:fullGetBlocks" class="def">fullGetBlocks</a> :: <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> b =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [[b]]</p><div class="doc"><p>An alias for <code><a href="System-IO-Binary.html#v:hFullGetBlocks">hFullGetBlocks</a></code> <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:stdin">stdin</a></code></p></div></div><h1 id="g:7">Lazy Interaction</h1><div class="top"><p class="src"><a name="v:readBinaryFile" class="def">readBinaryFile</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Like the built-in <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#v:readFile">readFile</a></code>, but opens the file in binary instead
of text mode. </p></div></div><div class="top"><p class="src"><a name="v:writeBinaryFile" class="def">writeBinaryFile</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Like the built-in <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#v:writeFile">writeFile</a></code>, but opens the file in binary instead
of text mode. </p></div></div><h2 id="g:8">Binary Block-based</h2><div class="top"><p class="src"><a name="v:hBlockInteract" class="def">hBlockInteract</a> :: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a, <a href="System-IO-HVIO.html#t:HVIO">HVIO</a> d, <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> b, <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> c) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; a -&gt; d -&gt; ([[b]] -&gt; [[c]]) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Binary block-based interaction. This is useful for scenarios that
take binary blocks, manipulate them in some way, and then write them
out. Take a look at <code><a href="System-IO-Binary.html#v:hBlockCopy">hBlockCopy</a></code> for an example. The integer argument
is the size of input binary blocks. This function uses <code><a href="System-IO-Binary.html#v:hGetBlocks">hGetBlocks</a></code>
internally.</p></div></div><div class="top"><p class="src"><a name="v:blockInteract" class="def">blockInteract</a> :: (<a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> b, <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> c) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; ([[b]] -&gt; [[c]]) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>An alias for <code><a href="System-IO-Binary.html#v:hBlockInteract">hBlockInteract</a></code> over <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:stdin">stdin</a></code> and <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:stdout">stdout</a></code></p></div></div><div class="top"><p class="src"><a name="v:hFullBlockInteract" class="def">hFullBlockInteract</a> :: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a, <a href="System-IO-HVIO.html#t:HVIO">HVIO</a> d, <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> b, <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> c) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; a -&gt; d -&gt; ([[b]] -&gt; [[c]]) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Same as <code><a href="System-IO-Binary.html#v:hBlockInteract">hBlockInteract</a></code>, but uses <code><a href="System-IO-Binary.html#v:hFullGetBlocks">hFullGetBlocks</a></code> instead of
<code><a href="System-IO-Binary.html#v:hGetBlocks">hGetBlocks</a></code> internally. </p></div></div><div class="top"><p class="src"><a name="v:fullBlockInteract" class="def">fullBlockInteract</a> :: (<a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> b, <a href="System-IO-Binary.html#t:BinaryConvertible">BinaryConvertible</a> c) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; ([[b]] -&gt; [[c]]) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>An alias for <code><a href="System-IO-Binary.html#v:hFullBlockInteract">hFullBlockInteract</a></code> over <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:stdin">stdin</a></code> and <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:stdout">stdout</a></code></p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,7 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.IO.HVFS.Combinators</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-IO-HVFS-Combinators.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.IO.HVFS.Combinators</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Restrictions</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Support for combining different HVFS modules together</p><p>Copyright (c) 2004-2005 John Goerzen, jgoerzen@complete.org</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">data</span> <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; <a href="#t:HVFSReadOnly">HVFSReadOnly</a> a = <a href="#v:HVFSReadOnly">HVFSReadOnly</a> a</li><li class="src short"><span class="keyword">data</span> <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; <a href="#t:HVFSChroot">HVFSChroot</a> a</li><li class="src short"><a href="#v:newHVFSChroot">newHVFSChroot</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="System-IO-HVFS-Combinators.html#t:HVFSChroot">HVFSChroot</a> a)</li></ul></div><div id="interface"><h1 id="g:1">Restrictions</h1><div class="top"><p class="src"><span class="keyword">data</span> <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; <a name="t:HVFSReadOnly" class="def">HVFSReadOnly</a> a</p><div class="doc"><p>Restrict access to the underlying filesystem to be strictly
read-only. Any write-type operations will cause an error.</p><p>No constructor is required; just say <code>HVFSReadOnly fs</code> to make a
new read-only wrapper around the <code><a href="System-IO-HVFS.html#t:HVFS">HVFS</a></code> instance <code>fs</code>.</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:HVFSReadOnly" class="def">HVFSReadOnly</a> a</td><td class="doc empty">&nbsp;</td></tr></table></div><div class="subs instances"><p id="control.i:HVFSReadOnly" class="caption collapser" onclick="toggleSection('i:HVFSReadOnly')">Instances</p><div id="section.i:HVFSReadOnly" class="show"><table><tr><td class="src">(<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a, <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> (<a href="System-IO-HVFS-Combinators.html#t:HVFSReadOnly">HVFSReadOnly</a> a)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> (<a href="System-IO-HVFS-Combinators.html#t:HVFSReadOnly">HVFSReadOnly</a> a)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFSOpenable">HVFSOpenable</a> a =&gt; <a href="System-IO-HVFS.html#t:HVFSOpenable">HVFSOpenable</a> (<a href="System-IO-HVFS-Combinators.html#t:HVFSReadOnly">HVFSReadOnly</a> a)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> (<a href="System-IO-HVFS-Combinators.html#t:HVFSReadOnly">HVFSReadOnly</a> a)</td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; <a name="t:HVFSChroot" class="def">HVFSChroot</a> a</p><div class="doc"><p>Access a subdirectory of a real filesystem as if it was the root
of that filesystem. </p></div><div class="subs instances"><p id="control.i:HVFSChroot" class="caption collapser" onclick="toggleSection('i:HVFSChroot')">Instances</p><div id="section.i:HVFSChroot" class="show"><table><tr><td class="src">(<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a, <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a) =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> (<a href="System-IO-HVFS-Combinators.html#t:HVFSChroot">HVFSChroot</a> a)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> (<a href="System-IO-HVFS-Combinators.html#t:HVFSChroot">HVFSChroot</a> a)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFSOpenable">HVFSOpenable</a> a =&gt; <a href="System-IO-HVFS.html#t:HVFSOpenable">HVFSOpenable</a> (<a href="System-IO-HVFS-Combinators.html#t:HVFSChroot">HVFSChroot</a> a)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> (<a href="System-IO-HVFS-Combinators.html#t:HVFSChroot">HVFSChroot</a> a)</td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><a name="v:newHVFSChroot" class="def">newHVFSChroot</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">=&gt; a</td><td class="doc"><p>The object to pass requests on to</p></td></tr><tr><td class="src">-&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a></td><td class="doc"><p>The path of the directory to make root</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="System-IO-HVFS-Combinators.html#t:HVFSChroot">HVFSChroot</a> a)</td><td class="doc"><p>The resulting new object</p></td></tr></table></div><div class="doc"><p>Create a new <code><a href="System-IO-HVFS-Combinators.html#t:HVFSChroot">HVFSChroot</a></code> object. </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,13 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.IO.HVFS.InstanceHelpers</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-IO-HVFS-InstanceHelpers.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.IO.HVFS.InstanceHelpers</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">HVFSStat objects</a></li><li><a href="#g:2">HVFS objects &amp; types</a><ul><li><a href="#g:3">MemoryVFS</a></li></ul></li><li><a href="#g:4">Utilities</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Utilities for creating instances of the items defined in
<a href="System-IO-HVFS.html">System.IO.HVFS</a>.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">data</span> <a href="#t:SimpleStat">SimpleStat</a> = <a href="#v:SimpleStat">SimpleStat</a> {<ul class="subs"><li><a href="#v:isFile">isFile</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li><a href="#v:fileSize">fileSize</a> :: <a href="System-IO-HVFS.html#t:FileOffset">FileOffset</a></li></ul>}</li><li class="src short"><span class="keyword">data</span> <a href="#t:MemoryVFS">MemoryVFS</a></li><li class="src short"><a href="#v:newMemoryVFS">newMemoryVFS</a> :: [<a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryNode">MemoryNode</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryVFS">MemoryVFS</a></li><li class="src short"><a href="#v:newMemoryVFSRef">newMemoryVFSRef</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-IORef.html#t:IORef">IORef</a> [<a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryNode">MemoryNode</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryVFS">MemoryVFS</a></li><li class="src short"><span class="keyword">type</span> <a href="#t:MemoryNode">MemoryNode</a> = (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryEntry">MemoryEntry</a>)</li><li class="src short"><span class="keyword">data</span> <a href="#t:MemoryEntry">MemoryEntry</a><ul class="subs"><li>= <a href="#v:MemoryDirectory">MemoryDirectory</a> [<a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryNode">MemoryNode</a>]</li><li>| <a href="#v:MemoryFile">MemoryFile</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li></ul></li><li class="src short"><a href="#v:nice_slice">nice_slice</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</li><li class="src short"><a href="#v:getFullPath">getFullPath</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:getFullSlice">getFullSlice</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</li></ul></div><div id="interface"><h1 id="g:1">HVFSStat objects</h1><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:SimpleStat" class="def">SimpleStat</a></p><div class="doc"><p>A simple <a href="System-IO-HVFS-HVFSStat.html">System.IO.HVFS.HVFSStat</a>
class that assumes that everything is either a file
or a directory. </p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:SimpleStat" class="def">SimpleStat</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div class="subs fields"><p class="caption">Fields</p><dl><dt class="src"><a name="v:isFile" class="def">isFile</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></dt><dd class="doc"><p>True if file, False if directory</p></dd><dt class="src"><a name="v:fileSize" class="def">fileSize</a> :: <a href="System-IO-HVFS.html#t:FileOffset">FileOffset</a></dt><dd class="doc"><p>Set to 0 if unknown or a directory</p></dd></dl><div class="clear"></div></div></td></tr></table></div><div class="subs instances"><p id="control.i:SimpleStat" class="caption collapser" onclick="toggleSection('i:SimpleStat')">Instances</p><div id="section.i:SimpleStat" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> <a href="System-IO-HVFS-InstanceHelpers.html#t:SimpleStat">SimpleStat</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="System-IO-HVFS-InstanceHelpers.html#t:SimpleStat">SimpleStat</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFSStat">HVFSStat</a> <a href="System-IO-HVFS-InstanceHelpers.html#t:SimpleStat">SimpleStat</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><h1 id="g:2">HVFS objects &amp; types</h1><h2 id="g:3">MemoryVFS</h2><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:MemoryVFS" class="def">MemoryVFS</a></p><div class="doc"><p>An in-memory read/write filesystem. Think of it as a dynamically
resizable ramdisk written in Haskell. </p></div><div class="subs instances"><p id="control.i:MemoryVFS" class="caption collapser" onclick="toggleSection('i:MemoryVFS')">Instances</p><div id="section.i:MemoryVFS" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryVFS">MemoryVFS</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFSOpenable">HVFSOpenable</a> <a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryVFS">MemoryVFS</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFS">HVFS</a> <a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryVFS">MemoryVFS</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><a name="v:newMemoryVFS" class="def">newMemoryVFS</a> :: [<a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryNode">MemoryNode</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryVFS">MemoryVFS</a></p><div class="doc"><p>Create a new <code><a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryVFS">MemoryVFS</a></code> object from an existing tree.
An empty filesystem may be created by using <code>[]</code> for the parameter.</p></div></div><div class="top"><p class="src"><a name="v:newMemoryVFSRef" class="def">newMemoryVFSRef</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-IORef.html#t:IORef">IORef</a> [<a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryNode">MemoryNode</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryVFS">MemoryVFS</a></p><div class="doc"><p>Create a new <code><a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryVFS">MemoryVFS</a></code> object using an IORef to an
existing tree.</p></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:MemoryNode" class="def">MemoryNode</a> = (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryEntry">MemoryEntry</a>)</p><div class="doc"><p>The basic node of a <code><a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryVFS">MemoryVFS</a></code>. The String corresponds to the filename,
and the entry to the contents. </p></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:MemoryEntry" class="def">MemoryEntry</a></p><div class="doc"><p>The content of a file or directory in a <code><a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryVFS">MemoryVFS</a></code>. </p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:MemoryDirectory" class="def">MemoryDirectory</a> [<a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryNode">MemoryNode</a>]</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a name="v:MemoryFile" class="def">MemoryFile</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="subs instances"><p id="control.i:MemoryEntry" class="caption collapser" onclick="toggleSection('i:MemoryEntry')">Instances</p><div id="section.i:MemoryEntry" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> <a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryEntry">MemoryEntry</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryEntry">MemoryEntry</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><h1 id="g:4">Utilities</h1><div class="top"><p class="src"><a name="v:nice_slice" class="def">nice_slice</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</p><div class="doc"><p>Similar to <code><a href="System-Path.html#t:NameManip">NameManip</a></code> but the first element
won't be <code>/</code>.</p><pre>nice_slice &quot;/&quot; -&gt; []
nice_slice &quot;/foo/bar&quot; -&gt; [&quot;foo&quot;, &quot;bar&quot;]</pre></div></div><div class="top"><p class="src"><a name="v:getFullPath" class="def">getFullPath</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Gets a full path, after investigating the cwd.</p></div></div><div class="top"><p class="src"><a name="v:getFullSlice" class="def">getFullSlice</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</p><div class="doc"><p>Gets the full path via <code><a href="System-IO-HVFS-InstanceHelpers.html#v:getFullPath">getFullPath</a></code>, then splits it via <code><a href="System-IO-HVFS-InstanceHelpers.html#v:nice_slice">nice_slice</a></code>.</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,14 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.IO.HVFS.Utils</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-IO-HVFS-Utils.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.IO.HVFS.Utils</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This module provides various helpful utilities for dealing
filesystems.</p><p>Written by John Goerzen, jgoerzen@complete.org</p><p>To operate on your system's main filesystem, just pass SystemFS as the
first parameter to these functions.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:recurseDir">recurseDir</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [<a href="System-IO-HVFS.html#t:FilePath">FilePath</a>]</li><li class="src short"><a href="#v:recurseDirStat">recurseDirStat</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [(<a href="System-IO-HVFS.html#t:FilePath">FilePath</a>, <a href="System-IO-HVFS.html#t:HVFSStatEncap">HVFSStatEncap</a>)]</li><li class="src short"><a href="#v:recursiveRemove">recursiveRemove</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:lsl">lsl</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><span class="keyword">data</span> <a href="#t:SystemFS">SystemFS</a> = <a href="#v:SystemFS">SystemFS</a></li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:recurseDir" class="def">recurseDir</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [<a href="System-IO-HVFS.html#t:FilePath">FilePath</a>]</p><div class="doc"><p>Obtain a recursive listing of all files/directories beneath
the specified directory. The traversal is depth-first
and the original
item is always present in the returned list.</p><p>If the passed value is not a directory, the return value
be only that value.</p><p>The &quot;.&quot; and &quot;..&quot; entries are removed from the data returned.</p></div></div><div class="top"><p class="src"><a name="v:recurseDirStat" class="def">recurseDirStat</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [(<a href="System-IO-HVFS.html#t:FilePath">FilePath</a>, <a href="System-IO-HVFS.html#t:HVFSStatEncap">HVFSStatEncap</a>)]</p><div class="doc"><p>Like <code><a href="System-IO-HVFS-Utils.html#v:recurseDir">recurseDir</a></code>, but return the stat() (System.Posix.Files.FileStatus)
information with them. This is an optimization if you will be statting files
yourself later.</p><p>The items are returned lazily.</p><p>WARNING: do not change your current working directory until you have consumed
all the items. Doing so could cause strange effects.</p><p>Alternatively, you may wish to pass an absolute path to this function.</p></div></div><div class="top"><p class="src"><a name="v:recursiveRemove" class="def">recursiveRemove</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Removes a file or a directory. If a directory, also removes all its
child files/directories.</p></div></div><div class="top"><p class="src"><a name="v:lsl" class="def">lsl</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Provide a result similar to the command ls -l over a directory.</p><p>Known bug: setuid bit semantics are inexact compared with standard ls.</p></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:SystemFS" class="def">SystemFS</a></p><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:SystemFS" class="def">SystemFS</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="subs instances"><p id="control.i:SystemFS" class="caption collapser" onclick="toggleSection('i:SystemFS')">Instances</p><div id="section.i:SystemFS" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> <a href="System-IO-HVFS-Utils.html#t:SystemFS">SystemFS</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="System-IO-HVFS-Utils.html#t:SystemFS">SystemFS</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFSOpenable">HVFSOpenable</a> <a href="System-IO-HVFS-Utils.html#t:SystemFS">SystemFS</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFS">HVFS</a> <a href="System-IO-HVFS-Utils.html#t:SystemFS">SystemFS</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,31 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.IO.HVFS</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-IO-HVFS.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.IO.HVFS</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Implementation Classes / Types</a></li><li><a href="#g:2">Re-exported types from other modules</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Haskell Virtual FS -- generic support for real or virtual filesystem in Haskell</p><p>Copyright (c) 2004-2005 John Goerzen, jgoerzen@complete.org</p><p>The idea of this module is to provide virtualization of filesystem calls.
In addition to the &quot;real&quot; system filesystem, you can also provide access
to other, virtual, filesystems using the same set of calls. Examples of
such virtual filesystems might include a remote FTP server, WebDAV server,
a local Hashtable, a ConfigParser object, or any other data structure
you can represent as a tree of named nodes containing strings.</p><p>Each <code><a href="System-IO-HVFS.html#t:HVFS">HVFS</a></code> function takes a <code><a href="System-IO-HVFS.html#t:HVFS">HVFS</a></code> &quot;handle&quot; (<code><a href="System-IO-HVFS.html#t:HVFS">HVFS</a></code> instance) as its
first parameter. If you wish to operate on the standard system filesystem,
you can just use <code><a href="System-IO-HVFS.html#t:SystemFS">SystemFS</a></code>.</p><p>The <a href="MissingH-HVFS-IO-InstanceHelpers.html">MissingH.HVFS.IO.InstanceHelpers</a> module contains some code to help
you make your own HVFS instances.</p><p>The <code><a href="System-IO-HVFS.html#t:HVFSOpenable">HVFSOpenable</a></code> class works together with the <a href="System-IO-HVIO.html">System.IO.HVIO</a> module
to provide a complete virtual filesystem and I/O model that allows you
to open up virtual filesystem files and act upon them in a manner similar
to standard Handles.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">class</span> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a =&gt; <a href="#t:HVFS">HVFS</a> a <span class="keyword">where</span><ul class="subs"><li><a href="#v:vGetCurrentDirectory">vGetCurrentDirectory</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="System-IO-HVFS.html#t:FilePath">FilePath</a></li><li><a href="#v:vSetCurrentDirectory">vSetCurrentDirectory</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li><a href="#v:vGetDirectoryContents">vGetDirectoryContents</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [<a href="System-IO-HVFS.html#t:FilePath">FilePath</a>]</li><li><a href="#v:vDoesFileExist">vDoesFileExist</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li><a href="#v:vDoesDirectoryExist">vDoesDirectoryExist</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li><a href="#v:vDoesExist">vDoesExist</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li><a href="#v:vCreateDirectory">vCreateDirectory</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li><a href="#v:vRemoveDirectory">vRemoveDirectory</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li><a href="#v:vRenameDirectory">vRenameDirectory</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li><a href="#v:vRemoveFile">vRemoveFile</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li><a href="#v:vRenameFile">vRenameFile</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li><a href="#v:vGetFileStatus">vGetFileStatus</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="System-IO-HVFS.html#t:HVFSStatEncap">HVFSStatEncap</a></li><li><a href="#v:vGetSymbolicLinkStatus">vGetSymbolicLinkStatus</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="System-IO-HVFS.html#t:HVFSStatEncap">HVFSStatEncap</a></li><li><a href="#v:vGetModificationTime">vGetModificationTime</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:ClockTime">ClockTime</a></li><li><a href="#v:vRaiseError">vRaiseError</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO-Error.html#t:IOErrorType">IOErrorType</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/Line truncated
will generate an isIllegalOperation error, since they are assumed to be
un-implemented.</p><p>You should always provide at least a <code><a href="System-IO-HVFS.html#v:vGetFileStatus">vGetFileStatus</a></code> call, and almost
certainly several of the others.</p><p>Most of these functions correspond to functions in System.Directory or
System.Posix.Files. Please see detailed documentation on them there.</p></div><div class="subs minimal"><p class="caption">Minimal complete definition</p><p class="src"><a href="System-IO-HVFS.html#v:vGetFileStatus">vGetFileStatus</a></p></div><div class="subs methods"><p class="caption">Methods</p><p class="src"><a name="v:vGetCurrentDirectory" class="def">vGetCurrentDirectory</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="System-IO-HVFS.html#t:FilePath">FilePath</a></p><p class="src"><a name="v:vSetCurrentDirectory" class="def">vSetCurrentDirectory</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><p class="src"><a name="v:vGetDirectoryContents" class="def">vGetDirectoryContents</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [<a href="System-IO-HVFS.html#t:FilePath">FilePath</a>]</p><p class="src"><a name="v:vDoesFileExist" class="def">vDoesFileExist</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><p class="src"><a name="v:vDoesDirectoryExist" class="def">vDoesDirectoryExist</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><p class="src"><a name="v:vDoesExist" class="def">vDoesExist</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>True if the file exists, regardless of what type it is.
This is even True if the given path is a broken symlink. </p></div><p class="src"><a name="v:vCreateDirectory" class="def">vCreateDirectory</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><p class="src"><a name="v:vRemoveDirectory" class="def">vRemoveDirectory</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><p class="src"><a name="v:vRenameDirectory" class="def">vRenameDirectory</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><p class="src"><a name="v:vRemoveFile" class="def">vRemoveFile</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><p class="src"><a name="v:vRenameFile" class="def">vRenameFile</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><p class="src"><a name="v:vGetFileStatus" class="def">vGetFileStatus</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="System-IO-HVFS.html#t:HVFSStatEncap">HVFSStatEncap</a></p><p class="src"><a name="v:vGetSymbolicLinkStatus" class="def">vGetSymbolicLinkStatus</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="System-IO-HVFS.html#t:HVFSStatEncap">HVFSStatEncap</a></p><p class="src"><a name="v:vGetModificationTime" class="def">vGetModificationTime</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:ClockTime">ClockTime</a></p><p class="src"><a name="v:vRaiseError" class="def">vRaiseError</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO-Error.html#t:IOErrorType">IOErrorType</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> c</p><div class="doc"><p>Raise an error relating to actions on this class. </p></div><p class="src"><a name="v:vCreateSymbolicLink" class="def">vCreateSymbolicLink</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><p class="src"><a name="v:vReadSymbolicLink" class="def">vReadSymbolicLink</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="System-IO-HVFS.html#t:FilePath">FilePath</a></p><p class="src"><a name="v:vCreateLink" class="def">vCreateLink</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p></div><div class="subs instances"><p id="control.i:HVFS" class="caption collapser" onclick="toggleSection('i:HVFS')">Instances</p><div id="section.i:HVFS" class="show"><table><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFS">HVFS</a> <a href="System-IO-HVFS.html#t:SystemFS">SystemFS</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFS">HVFS</a> <a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryVFS">MemoryVFS</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> (<a href="System-IO-HVFS-Combinators.html#t:HVFSChroLine truncated
that is one instance of this class.</p><p>Inplementators must, at minimum, implement <code><a href="System-IO-HVFS.html#v:vIsDirectory">vIsDirectory</a></code> and
<code><a href="System-IO-HVFS.html#v:vIsRegularFile">vIsRegularFile</a></code>.</p><p>Default implementations of everything else are provided, returning
reasonable values.</p><p>A default implementation of this is not currently present on Windows.</p></div><div class="subs minimal"><p class="caption">Minimal complete definition</p><p class="src"><a href="System-IO-HVFS.html#v:vIsRegularFile">vIsRegularFile</a>, <a href="System-IO-HVFS.html#v:vIsDirectory">vIsDirectory</a></p></div><div class="subs methods"><p class="caption">Methods</p><p class="src"><a name="v:vDeviceID" class="def">vDeviceID</a> :: a -&gt; <a href="System-IO-HVFS.html#t:DeviceID">DeviceID</a></p><p class="src"><a name="v:vFileID" class="def">vFileID</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FileID">FileID</a></p><p class="src"><a name="v:vFileMode" class="def">vFileMode</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FileMode">FileMode</a></p><div class="doc"><p>Refers to file permissions, NOT the st_mode field from stat(2) </p></div><p class="src"><a name="v:vLinkCount" class="def">vLinkCount</a> :: a -&gt; <a href="System-IO-HVFS.html#t:LinkCount">LinkCount</a></p><p class="src"><a name="v:vFileOwner" class="def">vFileOwner</a> :: a -&gt; <a href="System-IO-HVFS.html#t:UserID">UserID</a></p><p class="src"><a name="v:vFileGroup" class="def">vFileGroup</a> :: a -&gt; <a href="System-IO-HVFS.html#t:GroupID">GroupID</a></p><p class="src"><a name="v:vSpecialDeviceID" class="def">vSpecialDeviceID</a> :: a -&gt; <a href="System-IO-HVFS.html#t:DeviceID">DeviceID</a></p><p class="src"><a name="v:vFileSize" class="def">vFileSize</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FileOffset">FileOffset</a></p><p class="src"><a name="v:vAccessTime" class="def">vAccessTime</a> :: a -&gt; <a href="System-IO-HVFS.html#t:EpochTime">EpochTime</a></p><p class="src"><a name="v:vModificationTime" class="def">vModificationTime</a> :: a -&gt; <a href="System-IO-HVFS.html#t:EpochTime">EpochTime</a></p><p class="src"><a name="v:vStatusChangeTime" class="def">vStatusChangeTime</a> :: a -&gt; <a href="System-IO-HVFS.html#t:EpochTime">EpochTime</a></p><p class="src"><a name="v:vIsBlockDevice" class="def">vIsBlockDevice</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><p class="src"><a name="v:vIsCharacterDevice" class="def">vIsCharacterDevice</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><p class="src"><a name="v:vIsNamedPipe" class="def">vIsNamedPipe</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><p class="src"><a name="v:vIsRegularFile" class="def">vIsRegularFile</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><p class="src"><a name="v:vIsDirectory" class="def">vIsDirectory</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><p class="src"><a name="v:vIsSymbolicLink" class="def">vIsSymbolicLink</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><p class="src"><a name="v:vIsSocket" class="def">vIsSocket</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p></div><div class="subs instances"><p id="control.i:HVFSStat" class="caption collapser" onclick="toggleSection('i:HVFSStat')">Instances</p><div id="section.i:HVFSStat" class="show"><table><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFSStat">HVFSStat</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/unix-2.7.1.0/System-Posix-Files-ByteString.html#t:FileStatus">FileStatus</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFSStat">HVFSStat</a> <a href="System-IO-HVFS-InstanceHelpers.html#t:SimpleStat">SimpleStat</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">class</span> <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; <a name="t:HVFSOpenable" class="def">HVFSOpenable</a> a <span class="keyword">where</span></p><div class="doc"><p>Types that can open a HVIO object should be instances of this class.
You need only implement <code><a href="System-IO-HVFS.html#v:vOpen">vOpen</a></code>. </p></div><div class="subs minimal"><p class="caption">Minimal complete definition</p><p class="src"><a href="System-IO-HVFS.html#v:vOpen">vOpen</a></p></div><div class="subs methods"><p class="caption">Methods</p><p class="src"><a name="v:vOpen" class="def">vOpen</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="System-IO-HVFS.html#t:IOMode">IOMode</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="System-IO-HVFS.html#t:HVFSOpenEncap">HVFSOpenEncap</a></p><p class="src"><a name="v:vReadFile" class="def">vReadFile</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><p class="src"><a name="v:vWriteFile" class="def">vWriteFile</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><p class="src"><a name="v:vOpenBinaryFile" class="def">vOpenBinaryFile</a> :: a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="System-IO-HVFS.html#t:IOMode">IOMode</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="System-IO-HVFS.html#t:HVFSOpenEncap">HVFSOpenEncap</a></p></div><div class="subs instances"><p id="control.i:HVFSOpenable" class="caption collapser" onclick="toggleSection('i:HVFSOpenable')">Instances</p><div id="section.i:HVFSOpenable" class="show"><table><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFSOpenable">HVFSOpenable</a> <a href="System-IO-HVFS.html#t:SystemFS">SystemFS</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFSOpenable">HVFSOpenable</a> <a href="System-IO-HVFS-InstanceHelpers.html#t:MemoryVFS">MemoryVFS</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFSOpenable">HVFSOpenable</a> a =&gt; <a href="System-IO-HVFS.html#t:HVFSOpenable">HVFSOpenable</a> (<a href="System-IO-HVFS-Combinators.html#t:HVFSChroot">HVFSChroot</a> a)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFSOpenable">HVFSOpenable</a> a =&gt; <a href="System-IO-HVFS.html#t:HVFSOpenable">HVFSOpenable</a> (<a href="System-IO-HVFS-Combinators.html#t:HVFSReadOnly">HVFSReadOnly</a> a)</td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:HVFSOpenEncap" class="def">HVFSOpenEncap</a></p><div class="doc"><p>Similar to <code><a href="System-IO-HVFS.html#t:HVFSStatEncap">HVFSStatEncap</a></code>, but for <code><a href="System-IO-HVFS.html#v:vOpen">vOpen</a></code> result.</p></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><span class="keyword">forall</span> a . <a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a =&gt; <a name="v:HVFSOpenEncap" class="def">HVFSOpenEncap</a> a</td><td class="doc empty">&nbsp;</td></tr></table></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:HVFSStatEncap" class="def">HVFSStatEncap</a></p><div class="doc"><p>Encapsulate a <code><a href="System-IO-HVFS.html#t:HVFSStat">HVFSStat</a></code> result. This is required due to Haskell
typing restrictions. You can get at it with:</p><pre>case encap of
HVFSStatEncap x -&gt; -- now use x</pre></div><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><span class="keyword">forall</span> a . <a href="System-IO-HVFS.html#t:HVFSStat">HVFSStat</a> a =&gt; <a name="v:HVFSStatEncap" class="def">HVFSStatEncap</a> a</td><td class="doc empty">&nbsp;</td></tr></table></div></div><div class="top"><p class="src"><a name="v:withStat" class="def">withStat</a> :: <span class="keyword">forall</span> b. <a href="System-IO-HVFS.html#t:HVFSStatEncap">HVFSStatEncap</a> -&gt; (<span class="keyword">forall</span> a. <a href="System-IO-HVFS.html#t:HVFSStat">HVFSStat</a> a =&gt; a -&gt; b) -&gt; b</p><div class="doc"><p>Convenience function for working with stat -- takes a stat result
and a function that uses it, and returns the result. </p><p>Here is an example from the HVFS source:</p><pre> vGetModificationTime fs fp =
do s &lt;- vGetFileStatus fs fp
return $ epochToClockTime (withStat s vModificationTime)</pre><p>See <code><a href="System-Time-Utils.html#v:epochToClockTime">epochToClockTime</a></code> for more information.</p></div></div><div class="top"><p class="src"><a name="v:withOpen" class="def">withOpen</a> :: <span class="keyword">forall</span> b. <a href="System-IO-HVFS.html#t:HVFSOpenEncap">HVFSOpenEncap</a> -&gt; (<span class="keyword">forall</span> a. <a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a =&gt; a -&gt; b) -&gt; b</p><div class="doc"><p>Similar to <code><a href="System-IO-HVFS.html#v:withStat">withStat</a></code>, but for the <code><a href="System-IO-HVFS.html#v:vOpen">vOpen</a></code> result. </p></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:SystemFS" class="def">SystemFS</a></p><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:SystemFS" class="def">SystemFS</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="subs instances"><p id="control.i:SystemFS" class="caption collapser" onclick="toggleSection('i:SystemFS')">Instances</p><div id="section.i:SystemFS" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> <a href="System-IO-HVFS.html#t:SystemFS">SystemFS</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="System-IO-HVFS.html#t:SystemFS">SystemFS</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFSOpenable">HVFSOpenable</a> <a href="System-IO-HVFS.html#t:SystemFS">SystemFS</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVFS.html#t:HVFS">HVFS</a> <a href="System-IO-HVFS.html#t:SystemFS">SystemFS</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><h1 id="g:2">Re-exported types from other modules</h1><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:FilePath" class="def">FilePath</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>File and directory names are values of type <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></code>, whose precise
meaning is operating system dependent. Files can be opened, yielding a
handle which can then be used to operate on the contents of that file.</p></div></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:DeviceID" class="def">DeviceID</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:CDev">CDev</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:FileID" class="def">FileID</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:CIno">CIno</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:FileMode" class="def">FileMode</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:CMode">CMode</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:LinkCount" class="def">LinkCount</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:CNlink">CNlink</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:UserID" class="def">UserID</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:CUid">CUid</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:GroupID" class="def">GroupID</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:CGid">CGid</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:FileOffset" class="def">FileOffset</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html#t:COff">COff</a></p></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:EpochTime" class="def">EpochTime</a> = <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Foreign-C-Types.html#t:CTime">CTime</a></p></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:IOMode" class="def">IOMode</a> :: *</p><div class="doc"><p>See <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#v:openFile">openFile</a></code></p></div><div class="subs instances"><p id="control.i:IOMode" class="caption collapser" onclick="toggleSection('i:IOMode')">Instances</p><div id="section.i:IOMode" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Enum">Enum</a> <a href="System-IO-HVFS.html#t:IOMode">IOMode</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> <a href="System-IO-HVFS.html#t:IOMode">IOMode</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ord.html#t:Ord">Ord</a> <a href="System-IO-HVFS.html#t:IOMode">IOMode</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Read.html#t:Read">Read</a> <a href="System-IO-HVFS.html#t:IOMode">IOMode</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="System-IO-HVFS.html#t:IOMode">IOMode</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Ix.html#t:Ix">Ix</a> <a href="System-IO-HVFS.html#t:IOMode">IOMode</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,121 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.IO.HVIO</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-IO-HVIO.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.IO.HVIO</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Implementation Classes</a></li><li><a href="#g:2">Standard HVIO Implementations</a><ul><li><a href="#g:3">Handle</a></li><li><a href="#g:4">Stream Reader</a></li><li><a href="#g:5">Memory Buffer</a></li><li><a href="#g:6">Haskell Pipe</a></li></ul></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Haskell Virtual I/O -- a system to increase the flexibility of input and
output in Haskell</p><p>Copyright (c) 2004-2005 John Goerzen, jgoerzen@complete.org</p><p>HVIO provides the following general features:</p><ul><li>The ability to use a single set of functions on various different
types of objects, including standard Handles, in-memory buffers,
compressed files, network data streams, etc.</li><li>The ability to transparently add filters to the I/O process.
These filters could include things such as character set conversions,
compression or decompression of a data stream, and more.</li><li>The ability to define new objects that have the properties
of I/O objects and can be used interchangably with them.</li><li>Specification compatibility with, and complete support for,
existing I/O on Handles.</li><li>Provide easier unit testing capabilities for I/O actions</li></ul><p>HVIO defines several basic type classes that you can use. You will mostly
be interested in <code><a href="System-IO-HVIO.html#t:HVIO">HVIO</a></code>.</p><p>It's trivial to adapt old code to work with HVIO. For instance, consider
this example of old and new code:</p><pre>printMsg :: Handle -&gt; String -&gt; IO ()
printMsg h msg = hPutStr h (&quot;msg: &quot; ++ msg)</pre><p>And now, the new way:</p><pre>printMsg :: HVIO h =&gt; h -&gt; String -&gt; IO ()
printMsg h msg = vPutStr h (&quot;msg: &quot; ++ msg)</pre><p>There are several points to note about this conversion:</p><ul><li>The new method can still accept a Handle in exactly the same way as
the old method. Changing your functions to use HVIO will require no
changes from functions that call them with Handles.</li><li>Most &quot;h&quot; functions have equivolent &quot;v&quot; functions that operate
on HVIO classes instead of the more specific Handle. The &quot;v&quot; functions
behave identically to the &quot;h&quot; functions whenever possible.</li><li>There is no equivolent of &quot;openFile&quot; in any HVIO class. You must
create your Handle (or other HVIO object) using normal means.
This is because the creation is so different that it cannot be standardized.</li></ul><p>In addition to Handle, there are several pre-defined classes for your use.
<code><a href="System-IO-HVIO.html#t:StreamReader">StreamReader</a></code> is a particularly interesting one. At creation time, you pass
it a String. Its contents are read lazily whenever a read call is made. It
can be used, therefore, to implement filters (simply initialize it with the
result from, say, a map over hGetContents from another HVIO object), codecs,
and simple I/O testing. Because it is lazy, it need not hold the entire
string in memory. You can create a <code><a href="System-IO-HVIO.html#t:StreamReader">StreamReader</a></code> with a call to
<code><a href="System-IO-HVIO.html#v:newStreamReader">newStreamReader</a></code>.</p><p><code><a href="System-IO-HVIO.html#t:MemoryBuffer">MemoryBuffer</a></code> is a similar class, but with a different purpose. It provides
a full interface like Handle (it implements <code>HVIOReader</code>, <code>HVIOWriter</code>,
and <code>HVIOSeeker</code>). However, it maintains an in-memory buffer with the
contents of the file, rather than an actual on-disk file. You can access
the entire contents of this buffer at any time. This can be quite useful
for testing I/O code, or for cases where existing APIs use I/O, but you
prefer a String representation. You can create a <code><a href="System-IO-HVIO.html#t:MemoryBuffer">MemoryBuffer</a></code> with a call
to <code><a href="System-IO-HVIO.html#v:newMemoryBuffer">newMemoryBuffer</a></code>.</p><p>Finally, there are pipes. These pipes are analogous to the Unix
pipes that are available from System.Posix, but don't require Unix and work
only in Haskell. When you create a pipe, you actually get two HVIO objects:
a <code><a href="System-IO-HVIO.html#t:PipeReader">PipeReader</a></code> and a <code><a href="System-IO-HVIO.html#t:PipeWriter">PipeWriter</a></code>. You must use the <code><a href="System-IO-HVIO.html#t:PipeWriter">PipeWriter</a></code> in one
thread and the <code><a href="System-IO-HVIO.html#t:PipeReader">PipeReader</a></code> in another thread. Data that's written to the
<code><a href="System-IO-HVIO.html#t:PipeWriter">PipeWriter</a></code> will then be available for reading with the <code><a href="System-IO-HVIO.html#t:PipeReader">PipeReader</a></code>. The
pipes are implemented completely with existing Haskell threading primitives,
and require no special operating system support. Unlike Unix pipes, these
pipes cannot be used across a fork(). Also unlike Unix pipes, these pipes
are portable and interact well with Haskell threads. A new pipe can be created
with a call to <code><a href="System-IO-HVIO.html#v:newHVIOPipe">newHVIOPipe</a></code>.</p><p>Together with <a href="System-IO-HVFS.html">System.IO.HVFS</a>, this module is part of a complete
virtual filesystem solution.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">class</span> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a =&gt; <a href="#t:HVIO">HVIO</a> a <span class="keyword">where</span><ul class="subs"><li><a href="#v:vClose">vClose</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li><a href="#v:vIsOpen">vIsOpen</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li><a href="#v:vIsClosed">vIsClosed</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li><a href="#v:vTestOpen">vTestOpen</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li><a href="#v:vIsEOF">vIsEOF</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li><a href="#v:vShow">vShow</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li><a href="#v:vMkIOError">vMkIOError</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO-Error.html#t:IOErrorType">IOErrorType</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO-Error.html#t:IOError">IOError</a></li><li><a href="#v:vThrow">vThrow</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO-Error.html#t:IOErrorType">IOErrorType</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> b</li><li><a href="#v:vGetFP">vGetFP</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="System-IO-HVFS.html#t:FilePath">FilePath</a>)</li><li><a href="#v:vTestEOF">vTestEOF</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li><a href="#v:vGetChar">vGetChar</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Char.html#t:Char">Char</a></li><li><a href="#v:vGetLine">vGetLine</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li><a href="#v:vGetContents">vGetContents</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li><a href="#v:vReady">vReady</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li><a href="#v:vIsReadable">vIsReadable</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li><a href="#v:vPutChar">vPutChar</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.Line truncated
in the HVIO system must provide an instance of <code><a href="System-IO-HVIO.html#t:HVIO">HVIO</a></code>.</p><p>Functions in this class provide an interface with the same specification as
the similar functions in System.IO. Please refer to that documentation
for a more complete specification than is provided here.</p><p>Instances of <code><a href="System-IO-HVIO.html#t:HVIO">HVIO</a></code> must provide <code><a href="System-IO-HVIO.html#v:vClose">vClose</a></code>, <code><a href="System-IO-HVIO.html#v:vIsEOF">vIsEOF</a></code>, and either
<code><a href="System-IO-HVIO.html#v:vIsOpen">vIsOpen</a></code> or <code><a href="System-IO-HVIO.html#v:vIsClosed">vIsClosed</a></code>.</p><p>Implementators of readable objects must provide at least <code><a href="System-IO-HVIO.html#v:vGetChar">vGetChar</a></code>
and <code><a href="System-IO-HVIO.html#v:vIsReadable">vIsReadable</a></code>.
An implementation of <code><a href="System-IO-HVIO.html#v:vGetContents">vGetContents</a></code> is also highly suggested, since
the default cannot implement proper partial closing semantics.</p><p>Implementators of writable objects must provide at least <code><a href="System-IO-HVIO.html#v:vPutChar">vPutChar</a></code> and
<code><a href="System-IO-HVIO.html#v:vIsWritable">vIsWritable</a></code>.</p><p>Implementators of seekable objects must provide at least
<code><a href="System-IO-HVIO.html#v:vIsSeekable">vIsSeekable</a></code>, <code><a href="System-IO-HVIO.html#v:vTell">vTell</a></code>, and <code><a href="System-IO-HVIO.html#v:vSeek">vSeek</a></code>.</p></div><div class="subs minimal"><p class="caption">Minimal complete definition</p><p class="src"><a href="System-IO-HVIO.html#v:vClose">vClose</a>, <a href="System-IO-HVIO.html#v:vIsEOF">vIsEOF</a></p></div><div class="subs methods"><p class="caption">Methods</p><p class="src"><a name="v:vClose" class="def">vClose</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Close a file</p></div><p class="src"><a name="v:vIsOpen" class="def">vIsOpen</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>Test if a file is open</p></div><p class="src"><a name="v:vIsClosed" class="def">vIsClosed</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>Test if a file is closed</p></div><p class="src"><a name="v:vTestOpen" class="def">vTestOpen</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Raise an error if the file is not open.
This is a new HVIO function and is implemented in terms of
<code><a href="System-IO-HVIO.html#v:vIsOpen">vIsOpen</a></code>.</p></div><p class="src"><a name="v:vIsEOF" class="def">vIsEOF</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>Whether or not we're at EOF. This may raise on exception
on some items, most notably write-only Handles such as stdout.
In general, this is most reliable on items opened for reading.
vIsEOF implementations must implicitly call vTestOpen.</p></div><p class="src"><a name="v:vShow" class="def">vShow</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Detailed show output.</p></div><p class="src"><a name="v:vMkIOError" class="def">vMkIOError</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO-Error.html#t:IOErrorType">IOErrorType</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO-Error.html#t:IOError">IOError</a></p><div class="doc"><p>Make an IOError.</p></div><p class="src"><a name="v:vThrow" class="def">vThrow</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO-Error.html#t:IOErrorType">IOErrorType</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> b</p><div class="doc"><p>Throw an IOError.</p></div><p class="src"><a name="v:vGetFP" class="def">vGetFP</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="System-IO-HVFS.html#t:FilePath">FilePath</a>)</p><div class="doc"><p>Get the filename/object/whatever that this corresponds to.
May be Nothing.</p></div><p class="src"><a name="v:vTestEOF" class="def">vTestEOF</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Throw an isEOFError if we're at EOF; returns nothing otherwise.
If an implementation overrides the default, make sure that it
calls vTestOpen at some point. The default implementation is
a wrapper around a call to <code><a href="System-IO-HVIO.html#v:vIsEOF">vIsEOF</a></code>.</p></div><p class="src"><a name="v:vGetChar" class="def">vGetChar</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Char.html#t:Char">Char</a></p><div class="doc"><p>Read one character</p></div><p class="src"><a name="v:vGetLine" class="def">vGetLine</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Read one line</p></div><p class="src"><a name="v:vGetContents" class="def">vGetContents</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Get the remaining contents. Please note that as a user of this
function, the same partial-closing semantics as are used in the
standard <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#v:hGetContents">hGetContents</a></code> are <em>encouraged</em> from implementators,
but are not <em>required</em>. That means that, for instance,
a <code><a href="System-IO-HVIO.html#v:vGetChar">vGetChar</a></code> after a <code><a href="System-IO-HVIO.html#v:vGetContents">vGetContents</a></code> may return some undefined
result instead of the error you would normally get. You should
use caution to make sure your code doesn't fall into that trap,
or make sure to test your code with Handle or one of the
default instances defined in this module. Also, some implementations
may essentially provide a complete close after a call to <code><a href="System-IO-HVIO.html#v:vGetContents">vGetContents</a></code>.
The bottom line: after a call to <code><a href="System-IO-HVIO.html#v:vGetContents">vGetContents</a></code>, you should do nothing
else with the object save closing it with <code><a href="System-IO-HVIO.html#v:vClose">vClose</a></code>.</p><p>For implementators, you are highly encouraged to provide a correct
implementation. </p></div><p class="src"><a name="v:vReady" class="def">vReady</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>Indicate whether at least one item is ready for reading.
This will always be True for a great many implementations.</p></div><p class="src"><a name="v:vIsReadable" class="def">vIsReadable</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>Indicate whether a particular item is available for reading.</p></div><p class="src"><a name="v:vPutChar" class="def">vPutChar</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Char.html#t:Char">Char</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Write one character</p></div><p class="src"><a name="v:vPutStr" class="def">vPutStr</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Write a string</p></div><p class="src"><a name="v:vPutStrLn" class="def">vPutStrLn</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Write a string with newline character after it</p></div><p class="src"><a name="v:vPrint" class="def">vPrint</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> b =&gt; a -&gt; b -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Write a string representation of the argument, plus a newline.</p></div><p class="src"><a name="v:vFlush" class="def">vFlush</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Flush any output buffers.
Note: implementations should assure that a vFlush is automatically
performed
on file close, if necessary to ensure all data sent is written.</p></div><p class="src"><a name="v:vIsWritable" class="def">vIsWritable</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>Indicate whether or not this particular object supports writing.</p></div><p class="src"><a name="v:vSeek" class="def">vSeek</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Device.html#t:SeekMode">SeekMode</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Seek to a specific location.</p></div><p class="src"><a name="v:vTell" class="def">vTell</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a></p><div class="doc"><p>Get the current position.</p></div><p class="src"><a name="v:vRewind" class="def">vRewind</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Convenience function to reset the file pointer to the beginning
of the file. A call to <code>vRewind h</code> is the
same as <code><code><a href="System-IO-HVIO.html#v:vSeek">vSeek</a></code> h AbsoluteSeek 0</code>.</p></div><p class="src"><a name="v:vIsSeekable" class="def">vIsSeekable</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p><div class="doc"><p>Indicate whether this instance supports seeking.</p></div><p class="src"><a name="v:vSetBuffering" class="def">vSetBuffering</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:BufferMode">BufferMode</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Set buffering; the default action is a no-op.</p></div><p class="src"><a name="v:vGetBuffering" class="def">vGetBuffering</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:BufferMode">BufferMode</a></p><div class="doc"><p>Get buffering; the default action always returns NoBuffering.</p></div><p class="src"><a name="v:vPutBuf" class="def">vPutBuf</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Foreign-Ptr.html#t:Ptr">Ptr</a> b -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Binary output: write the specified number of octets from the specified
buffer location.</p></div><p class="src"><a name="v:vGetBuf" class="def">vGetBuf</a> :: a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Foreign-Ptr.html#t:Ptr">Ptr</a> b -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></p><div class="doc"><p>Binary input: read the specified number of octets from the
specified buffer location, continuing to read
until it either consumes that much data or EOF is encountered.
Returns the number of octets actually read. EOF errors are never
raised; fewer bytes than requested are returned on EOF.</p></div></div><div class="subs instances"><p id="control.i:HVIO" class="caption collapser" onclick="toggleSection('i:HVIO')">Instances</p><div id="section.i:HVIO" class="show"><table><tr><td class="src"><a href="System-IO-HVIO.html#t:HVIO">HVIO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle.html#t:Handle">Handle</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVIO.html#t:HVIO">HVIO</a> <a href="System-IO-HVIO.html#t:PipeWriter">PipeWriter</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVIO.html#t:HVIO">HVIO</a> <a href="System-IO-HVIO.html#t:PipeReader">PipeReader</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVIO.html#t:HVIO">HVIO</a> <a href="System-IO-HVIO.html#t:MemoryBuffer">MemoryBuffer</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVIO.html#t:HVIO">HVIO</a> <a href="System-IO-HVIO.html#t:StreamReader">StreamReader</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><h1 id="g:2">Standard HVIO Implementations</h1><h2 id="g:3">Handle</h2><div class="doc"><p>Handle is a member of <code><a href="System-IO-HVIO.html#t:HVIO">HVIO</a></code>.</p></div><h2 id="g:4">Stream Reader</h2><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:StreamReader" class="def">StreamReader</a></p><div class="doc"><p>Simulate I/O based on a string buffer.</p><p>When a <code><a href="System-IO-HVIO.html#t:StreamReader">StreamReader</a></code> is created, it is initialized based on the contents of
a <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></code>. Its contents are read lazily whenever a request is made to read
something from the <code><a href="System-IO-HVIO.html#t:StreamReader">StreamReader</a></code>. It
can be used, therefore, to implement filters (simply initialize it with the
result from, say, a map over hGetContents from another HVIO object), codecs,
and simple I/O testing. Because it is lazy, it need not hold the entire
string in memory. You can create a <code><a href="System-IO-HVIO.html#t:StreamReader">StreamReader</a></code> with a call to
<code><a href="System-IO-HVIO.html#v:newStreamReader">newStreamReader</a></code>.</p></div><div class="subs instances"><p id="control.i:StreamReader" class="caption collapser" onclick="toggleSection('i:StreamReader')">Instances</p><div id="section.i:StreamReader" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="System-IO-HVIO.html#t:StreamReader">StreamReader</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVIO.html#t:HVIO">HVIO</a> <a href="System-IO-HVIO.html#t:StreamReader">StreamReader</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><a name="v:newStreamReader" class="def">newStreamReader</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Initial contents of the <code><a href="System-IO-HVIO.html#t:StreamReader">StreamReader</a></code></p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="System-IO-HVIO.html#t:StreamReader">StreamReader</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Create a new <code><a href="System-IO-HVIO.html#t:StreamReader">StreamReader</a></code> object. </p></div></div><h2 id="g:5">Memory Buffer</h2><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:MemoryBuffer" class="def">MemoryBuffer</a></p><div class="doc"><p>A <code><a href="System-IO-HVIO.html#t:MemoryBuffer">MemoryBuffer</a></code> simulates true I/O, but uses an in-memory buffer instead
of on-disk storage.</p><p>It provides
a full interface like Handle (it implements <code>HVIOReader</code>, <code>HVIOWriter</code>,
and <code>HVIOSeeker</code>). However, it maintains an in-memory buffer with the
contents of the file, rather than an actual on-disk file. You can access
the entire contents of this buffer at any time. This can be quite useful
for testing I/O code, or for cases where existing APIs use I/O, but you
prefer a String representation. You can create a <code><a href="System-IO-HVIO.html#t:MemoryBuffer">MemoryBuffer</a></code> with a call
to <code><a href="System-IO-HVIO.html#v:newMemoryBuffer">newMemoryBuffer</a></code>.</p><p>The present <code><a href="System-IO-HVIO.html#t:MemoryBuffer">MemoryBuffer</a></code> implementation is rather inefficient, particularly
when reading towards the end of large files. It's best used for smallish
data storage. This problem will be fixed eventually.</p></div><div class="subs instances"><p id="control.i:MemoryBuffer" class="caption collapser" onclick="toggleSection('i:MemoryBuffer')">Instances</p><div id="section.i:MemoryBuffer" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="System-IO-HVIO.html#t:MemoryBuffer">MemoryBuffer</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVIO.html#t:HVIO">HVIO</a> <a href="System-IO-HVIO.html#t:MemoryBuffer">MemoryBuffer</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><a name="v:newMemoryBuffer" class="def">newMemoryBuffer</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Initial Contents</p></td></tr><tr><td class="src">-&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ())</td><td class="doc"><p>close func</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="System-IO-HVIO.html#t:MemoryBuffer">MemoryBuffer</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Create a new <code><a href="System-IO-HVIO.html#t:MemoryBuffer">MemoryBuffer</a></code> instance. The buffer is initialized
to the value passed, and the pointer is placed at the beginning of the file.</p><p>You can put things in it by using the normal <code><a href="System-IO-HVIO.html#v:vPutStr">vPutStr</a></code> calls, and reset to
the beginning by using the normal <code><a href="System-IO-HVIO.html#v:vRewind">vRewind</a></code> call.</p><p>The function is called when <code><a href="System-IO-HVIO.html#v:vClose">vClose</a></code> is called, and is passed the contents of
the buffer at close time. You can use <code><a href="System-IO-HVIO.html#v:mbDefaultCloseFunc">mbDefaultCloseFunc</a></code> if you don't want to
do anything.</p><p>To create an empty buffer, pass the initial value <code>&quot;&quot;</code>. </p></div></div><div class="top"><p class="src"><a name="v:mbDefaultCloseFunc" class="def">mbDefaultCloseFunc</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Default (no-op) memory buf close function. </p></div></div><div class="top"><p class="src"><a name="v:getMemoryBuffer" class="def">getMemoryBuffer</a> :: <a href="System-IO-HVIO.html#t:MemoryBuffer">MemoryBuffer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Grab the entire contents of the buffer as a string.
Unlike <code><a href="System-IO-HVIO.html#v:vGetContents">vGetContents</a></code>, this has no effect on the open status of the
item, the EOF status, or the current position of the file pointer. </p></div></div><h2 id="g:6">Haskell Pipe</h2><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:PipeReader" class="def">PipeReader</a></p><div class="doc"><p>The reading side of a Haskell pipe. Please see <code><a href="System-IO-HVIO.html#v:newHVIOPipe">newHVIOPipe</a></code> for more
details. </p></div><div class="subs instances"><p id="control.i:PipeReader" class="caption collapser" onclick="toggleSection('i:PipeReader')">Instances</p><div id="section.i:PipeReader" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="System-IO-HVIO.html#t:PipeReader">PipeReader</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVIO.html#t:HVIO">HVIO</a> <a href="System-IO-HVIO.html#t:PipeReader">PipeReader</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:PipeWriter" class="def">PipeWriter</a></p><div class="doc"><p>The writing side of a Haskell pipe. Please see <code><a href="System-IO-HVIO.html#v:newHVIOPipe">newHVIOPipe</a></code> for more
details. </p></div><div class="subs instances"><p id="control.i:PipeWriter" class="caption collapser" onclick="toggleSection('i:PipeWriter')">Instances</p><div id="section.i:PipeWriter" class="show"><table><tr><td class="src"><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> <a href="System-IO-HVIO.html#t:PipeWriter">PipeWriter</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src"><a href="System-IO-HVIO.html#t:HVIO">HVIO</a> <a href="System-IO-HVIO.html#t:PipeWriter">PipeWriter</a></td><td class="doc empty">&nbsp;</td></tr></table></div></div></div><div class="top"><p class="src"><a name="v:newHVIOPipe" class="def">newHVIOPipe</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> (<a href="System-IO-HVIO.html#t:PipeReader">PipeReader</a>, <a href="System-IO-HVIO.html#t:PipeWriter">PipeWriter</a>)</p><div class="doc"><p>Create a Haskell pipe.</p><p>These pipes are analogous to the Unix
pipes that are available from System.Posix, but don't require Unix and work
only in Haskell. When you create a pipe, you actually get two HVIO objects:
a <code><a href="System-IO-HVIO.html#t:PipeReader">PipeReader</a></code> and a <code><a href="System-IO-HVIO.html#t:PipeWriter">PipeWriter</a></code>. You must use the <code><a href="System-IO-HVIO.html#t:PipeWriter">PipeWriter</a></code> in one
thread and the <code><a href="System-IO-HVIO.html#t:PipeReader">PipeReader</a></code> in another thread. Data that's written to the
<code><a href="System-IO-HVIO.html#t:PipeWriter">PipeWriter</a></code> will then be available for reading with the <code><a href="System-IO-HVIO.html#t:PipeReader">PipeReader</a></code>. The
pipes are implemented completely with existing Haskell threading primitives,
and require no special operating system support. Unlike Unix pipes, these
pipes cannot be used across a fork(). Also unlike Unix pipes, these pipes
are portable and interact well with Haskell threads. </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.IO.PlafCompat</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-IO-PlafCompat.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2005-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.IO.PlafCompat</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>On Unix, exports System.Posix.Types and System.Posix.Files.</p><p>On Windows, exports System.Posix.Types and <a href="System-IO-WindowsCompat.html">System.IO.WindowsCompat</a>.</p><p>The result should be roughly the same set of defined variables and types.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:nullFileName">nullFileName</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short">module <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/unix-2.7.1.0/System-Posix-Files.html">System.Posix.Files</a></li><li class="src short">module <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html">System.Posix.Types</a></li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:nullFileName" class="def">nullFileName</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>The name of the null device. NUL: on Windows, /dev/null everywhere else.</p></div></div><div class="top"><p class="src">module <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/unix-2.7.1.0/System-Posix-Files.html">System.Posix.Files</a></p></div><div class="top"><p class="src">module <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html">System.Posix.Types</a></p></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,5 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.IO.StatCompat</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-IO-StatCompat.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2005-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.IO.StatCompat</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Provide a stat-like structure for use in MissingH. Especially
useful with HVFS and on Windows. See also <a href="System-IO-WindowsCompat.html">System.IO.WindowsCompat</a>.</p></div></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><span class="keyword">data</span> <a name="t:FileStatusCompat" class="def">FileStatusCompat</a></p><div class="subs constructors"><p class="caption">Constructors</p><table><tr><td class="src"><a name="v:FileStatusCompat" class="def">FileStatusCompat</a></td><td class="doc empty">&nbsp;</td></tr><tr><td colspan="2"><div class="subs fields"><p class="caption">Fields</p><dl><dt class="src"><a name="v:deviceID" class="def">deviceID</a> :: <a href="System-IO-HVFS.html#t:DeviceID">DeviceID</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:fileID" class="def">fileID</a> :: <a href="System-IO-HVFS.html#t:FileID">FileID</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:fileMode" class="def">fileMode</a> :: <a href="System-IO-HVFS.html#t:FileMode">FileMode</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:linkCount" class="def">linkCount</a> :: <a href="System-IO-HVFS.html#t:LinkCount">LinkCount</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:fileOwner" class="def">fileOwner</a> :: <a href="System-IO-HVFS.html#t:UserID">UserID</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:fileGroup" class="def">fileGroup</a> :: <a href="System-IO-HVFS.html#t:GroupID">GroupID</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:specialDeviceID" class="def">specialDeviceID</a> :: <a href="System-IO-HVFS.html#t:DeviceID">DeviceID</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:fileSize" class="def">fileSize</a> :: <a href="System-IO-HVFS.html#t:FileOffset">FileOffset</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:accessTime" class="def">accessTime</a> :: <a href="System-IO-HVFS.html#t:EpochTime">EpochTime</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:modificationTime" class="def">modificationTime</a> :: <a href="System-IO-HVFS.html#t:EpochTime">EpochTime</a></dt><dd class="doc empty">&nbsp;</dd><dt class="src"><a name="v:statusChangeTime" class="def">statusChangeTime</a> :: <a href="System-IO-HVFS.html#t:EpochTime">EpochTime</a></dt><dd class="doc empty">&nbsp;</dd></dl><div class="clear"></div></div></td></tr></table></div></div><div class="top"><p class="src"><a name="v:sc_helper" class="def">sc_helper</a> :: <a href="System-IO-HVFS.html#t:FileMode">FileMode</a> -&gt; <a href="System-IO-StatCompat.html#t:FileStatusCompat">FileStatusCompat</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p></div><div class="top"><p class="src"><a name="v:isBlockDevice" class="def">isBlockDevice</a> :: <a href="System-IO-StatCompat.html#t:FileStatusCompat">FileStatusCompat</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p></div><div class="top"><p class="src"><a name="v:isCharacterDevice" class="def">isCharacterDevice</a> :: <a href="System-IO-StatCompat.html#t:FileStatusCompat">FileStatusCompat</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p></div><div class="top"><p class="src"><a name="v:isNamedPipe" class="def">isNamedPipe</a> :: <a href="System-IO-StatCompat.html#t:FileStatusCompat">FileStatusCompat</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p></div><div class="top"><p class="src"><a name="v:isRegularFile" class="def">isRegularFile</a> :: <a href="System-IO-StatCompat.html#t:FileStatusCompat">FileStatusCompat</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p></div><div class="top"><p class="src"><a name="v:isDirectory" class="def">isDirectory</a> :: <a href="System-IO-StatCompat.html#t:FileStatusCompat">FileStatusCompat</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p></div><div class="top"><p class="src"><a name="v:isSymbolicLink" class="def">isSymbolicLink</a> :: <a href="System-IO-StatCompat.html#t:FileStatusCompat">FileStatusCompat</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p></div><div class="top"><p class="src"><a name="v:isSocket" class="def">isSocket</a> :: <a href="System-IO-StatCompat.html#t:FileStatusCompat">FileStatusCompat</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></p></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,27 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.IO.Utils</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-IO-Utils.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.IO.Utils</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Entire File Handle Utilities</a><ul><li><a href="#g:2">Opened Handle Data Copying</a></li><li><a href="#g:3">Disk File Data Copying</a></li></ul></li><li><a href="#g:4">Line Processing Utilities</a></li><li><a href="#g:5">Lazy Interaction</a><ul><li><a href="#g:6">Character-based</a></li><li><a href="#g:7">Line-based</a></li><li><a href="#g:8">Misc. Lazy</a></li></ul></li><li><a href="#g:9">Optimizations</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc empty">&nbsp;</div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:hCopy">hCopy</a> :: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a, <a href="System-IO-HVIO.html#t:HVIO">HVIO</a> b) =&gt; a -&gt; b -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:hCopyProgress">hCopyProgress</a> :: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> b, <a href="System-IO-HVIO.html#t:HVIO">HVIO</a> c, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integral">Integral</a> a) =&gt; b -&gt; c -&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a></li><li class="src short"><a href="#v:hLineCopy">hLineCopy</a> :: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a, <a href="System-IO-HVIO.html#t:HVIO">HVIO</a> b) =&gt; a -&gt; b -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:lineCopy">lineCopy</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:copyFileLinesToFile">copyFileLinesToFile</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:hPutStrLns">hPutStrLns</a> :: <a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a =&gt; a -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:hGetLines">hGetLines</a> :: <a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a =&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</li><li class="src short"><a href="#v:hInteract">hInteract</a> :: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a, <a href="System-IO-HVIO.html#t:HVIO">HVIO</a> b) =&gt; a -&gt; b -&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a Line truncated
hGetContents).</p></div></div><div class="top"><p class="src"><a name="v:hCopyProgress" class="def">hCopyProgress</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> b, <a href="System-IO-HVIO.html#t:HVIO">HVIO</a> c, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integral">Integral</a> a)</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">=&gt; b</td><td class="doc"><p>Input handle</p></td></tr><tr><td class="src">-&gt; c</td><td class="doc"><p>Output handle</p></td></tr><tr><td class="src">-&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ())</td><td class="doc"><p>Progress function -- the bool is always False unless this is the final call</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Int.html#t:Int">Int</a></td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> a</td><td class="doc empty">&nbsp;</td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Copies from one handle to another in raw mode (using hGetContents).
Takes a function to provide progress updates to the user.</p></div></div><div class="top"><p class="src"><a name="v:hLineCopy" class="def">hLineCopy</a> :: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a, <a href="System-IO-HVIO.html#t:HVIO">HVIO</a> b) =&gt; a -&gt; b -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Copies from one handle to another in text mode (with lines).
Like <code>hBlockCopy</code>, this implementation is nice:</p><pre>hLineCopy hin hout = hLineInteract hin hout id</pre></div></div><div class="top"><p class="src"><a name="v:lineCopy" class="def">lineCopy</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Copies from <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:stdin">stdin</a></code> to <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:stdout">stdout</a></code> using lines. An alias for <code><a href="System-IO-Utils.html#v:hLineCopy">hLineCopy</a></code>
over <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:stdin">stdin</a></code> and <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-IO-Handle-FD.html#v:stdout">stdout</a></code>. </p></div></div><h2 id="g:3">Disk File Data Copying</h2><div class="top"><p class="src"><a name="v:copyFileLinesToFile" class="def">copyFileLinesToFile</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Copies one filename to another in text mode.</p><p>Please note that the Unix permission bits are set at a default; you may
need to adjust them after the copy yourself.</p><p>This function is implemented using <code><a href="System-IO-Utils.html#v:hLineCopy">hLineCopy</a></code> internally. </p></div></div><h1 id="g:4">Line Processing Utilities</h1><div class="top"><p class="src"><a name="v:hPutStrLns" class="def">hPutStrLns</a> :: <a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a =&gt; a -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Given a list of strings, output a line containing each item, adding
newlines as appropriate. The list is not expected to have newlines already.</p></div></div><div class="top"><p class="src"><a name="v:hGetLines" class="def">hGetLines</a> :: <a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a =&gt; a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</p><div class="doc"><p>Given a handle, returns a list of all the lines in that handle.
Thanks to lazy evaluation, this list does not have to be read all at once.</p><p>Combined with <code><a href="System-IO-Utils.html#v:hPutStrLns">hPutStrLns</a></code>, this can make a powerful way to develop
filters. See the <code><a href="System-IO-Utils.html#v:lineInteract">lineInteract</a></code> function for more on that concept.</p><p>Example:</p><pre>main = do
l &lt;- hGetLines stdin
hPutStrLns stdout $ filter (startswith &quot;1&quot;) l</pre></div></div><h1 id="g:5">Lazy Interaction</h1><h2 id="g:6">Character-based</h2><div class="top"><p class="src"><a name="v:hInteract" class="def">hInteract</a> :: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a, <a href="System-IO-HVIO.html#t:HVIO">HVIO</a> b) =&gt; a -&gt; b -&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>This is similar to the built-in <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#v:interact">interact</a></code>, but works
on any handle, not just stdin and stdout.</p><p>In other words:</p><pre>interact = hInteract stdin stdout</pre></div></div><h2 id="g:7">Line-based</h2><div class="top"><p class="src"><a name="v:hLineInteract" class="def">hLineInteract</a> :: (<a href="System-IO-HVIO.html#t:HVIO">HVIO</a> a, <a href="System-IO-HVIO.html#t:HVIO">HVIO</a> b) =&gt; a -&gt; b -&gt; ([<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Line-based interaction over arbitrary handles. This is similar
to wrapping hInteract with <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-OldList.html#v:lines">lines</a></code> and <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-OldList.html#v:unlines">unlines</a></code>.</p><p>One could view this function like this:</p><pre>hLineInteract finput foutput func =
let newf = unlines . func . lines in
hInteract finput foutput newf</pre><p>Though the actual implementation is this for efficiency:</p><pre>hLineInteract finput foutput func =
do
lines &lt;- hGetLines finput
hPutStrLns foutput (func lines)</pre></div></div><div class="top"><p class="src"><a name="v:lineInteract" class="def">lineInteract</a> :: ([<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Line-based interaction. This is similar to wrapping your
interact functions with <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-OldList.html#v:lines">lines</a></code> and <code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/GHC-OldList.html#v:unlines">unlines</a></code>. This equality holds:</p><pre>lineInteract = hLineInteract stdin stdout</pre><p>Here's an example:</p><pre>main = lineInteract (filter (startswith &quot;1&quot;))</pre><p>This will act as a simple version of grep -- all lines that start with 1
will be displayed; all others will be ignored.</p></div></div><h2 id="g:8">Misc. Lazy</h2><div class="top"><p class="src"><a name="v:lazyMapM" class="def">lazyMapM</a> :: (a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> b) -&gt; [a] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [b]</p><div class="doc"><p>Applies a given function to every item in a list, and returns
the new list. Unlike the system's mapM, items are evaluated lazily. </p></div></div><h1 id="g:9">Optimizations</h1><div class="top"><p class="src"><a name="v:optimizeForBatch" class="def">optimizeForBatch</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Sets stdin and stdout to be block-buffered. This can save a huge amount
of system resources since far fewer syscalls are made, and can make programs
run much faster. </p></div></div><div class="top"><p class="src"><a name="v:optimizeForInteraction" class="def">optimizeForInteraction</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Sets stdin and stdout to be line-buffered. This saves resources
on stdout, but not many on stdin, since it it still looking for newlines. </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,15 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.IO.WindowsCompat</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-IO-WindowsCompat.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2005-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.IO.WindowsCompat</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Provides some types and related items on Windows to be compatible with
the System.Posix.* libraries</p><p>See also <a href="System-IO-StatCompat.html">System.IO.StatCompat</a>, which this module re-exports.</p><p>On non-Windows platforms, this module does nothing.</p><p>On Windows, it re-exports <a href="System-IO-StatCompat.html">System.IO.StatCompat</a>. It also provides various
file type information modes that are otherwise in <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-Posix-Types.html">System.Posix.Types</a> or
<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/unix-2.7.1.0/System-Posix-Files.html">System.Posix.Files</a>. It also provides
a rudimentary implemention of getFileStatus that emulates the Posix call
to stat(2).</p><p>Common usage might be like this:</p><pre>import System.Posix.Types
#if (defined(mingw32_HOST_OS) || defined(mingw32_TARGET_OS) || defined(__MINGW32__))
import System.IO.WindowsCompat
#else
import System.Posix.Files
#endif</pre><p>Or, to avoid having to use CPP and make things even easier, just import
<a href="System-IO-PlafCompat.html">System.IO.PlafCompat</a>, which essentially does the above.</p></div></div><div id="interface"></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,9 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.Path.Glob</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-Path-Glob.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2006-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.Path.Glob</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Functions for expanding wildcards, filenames, and pathnames.</p><p>For information on the metacharacters recognized, please see the notes
in <a href="System-Path-WildMatch.html">System.Path.WildMatch</a>.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:glob">glob</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [<a href="System-IO-HVFS.html#t:FilePath">FilePath</a>]</li><li class="src short"><a href="#v:vGlob">vGlob</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [<a href="System-IO-HVFS.html#t:FilePath">FilePath</a>]</li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:glob" class="def">glob</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [<a href="System-IO-HVFS.html#t:FilePath">FilePath</a>]</p><div class="doc"><p>Takes a pattern. Returns a list of names that match that pattern.
The pattern is evaluated by <a href="System-Path-WildMatch.html">System.Path.WildMatch</a>. This function
does not perform tilde or environment variable expansion.</p><p>Filenames that begin with a dot are not included in the result set unless
that component of the pattern also begins with a dot.</p><p>In MissingH, this function is defined as:</p><pre>glob = vGlob SystemFS</pre></div></div><div class="top"><p class="src"><a name="v:vGlob" class="def">vGlob</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [<a href="System-IO-HVFS.html#t:FilePath">FilePath</a>]</p><div class="doc"><p>Like <code><a href="System-Path-Glob.html#v:glob">glob</a></code>, but works on both the system (&quot;real&quot;) and HVFS virtual
filesystems. </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,87 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.Path.NameManip</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-Path-NameManip.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004 Volker Wysk</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.Path.NameManip</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Low-level path name manipulations.</p><p>Written by Volker Wysk</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:slice_path">slice_path</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</li><li class="src short"><a href="#v:unslice_path">unslice_path</a> :: [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:normalise_path">normalise_path</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:slice_filename">slice_filename</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</li><li class="src short"><a href="#v:slice_filename-39-">slice_filename'</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</li><li class="src short"><a href="#v:unslice_filename">unslice_filename</a> :: [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>] -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:split_path">split_path</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</li><li class="src short"><a href="#v:dir_part">dir_part</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:filename_part">filename_part</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:unsplit_path">unsplit_path</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:split_filename">split_filename</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/Line truncated
components. &quot;<code>.</code>&quot; path components are removed. If the path is absolute, the first component
will start with &quot;<code>/</code>&quot;. &quot;<code>..</code>&quot; components are left intact. They can't be simply
removed, because the preceding component might be a symlink. In this case,
<code>realpath</code> is probably what you need.</p><p>The case that the path is empty, is probably an error. However, it is
treated like &quot;<code>.</code>&quot;, yielding an empty path components list.</p><p>Examples:</p><pre>slice_path &quot;/&quot; = [&quot;/&quot;]
slice_path &quot;/foo/bar&quot; = [&quot;/foo&quot;,&quot;bar&quot;]
slice_path &quot;..//./&quot; = [&quot;..&quot;]
slice_path &quot;.&quot; = []</pre><p>See <code><a href="System-Path-NameManip.html#v:unslice_path">unslice_path</a></code>, <code>realpath</code>, <code>realpath_s</code>.</p></div></div><div class="top"><p class="src"><a name="v:unslice_path" class="def">unslice_path</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</td><td class="doc"><p>List of path components</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>The path which consists of the supplied path components</p></td></tr></table></div><div class="doc"><p>Form a path from path components. This isn't the inverse
of <code><a href="System-Path-NameManip.html#v:slice_path">slice_path</a></code>, since <code><code><a href="System-Path-NameManip.html#v:unslice_path">unslice_path</a></code> . <code><a href="System-Path-NameManip.html#v:slice_path">slice_path</a></code></code>
normalises the path.</p><p>See <code><a href="System-Path-NameManip.html#v:slice_path">slice_path</a></code>.</p></div></div><div class="top"><p class="src"><a name="v:normalise_path" class="def">normalise_path</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Path to be normalised</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Path in normalised form</p></td></tr></table></div><div class="doc"><p>Normalise a path. This is done by reducing repeated <code>/</code> characters to one, and removing
<code>.</code> path components. <code>..</code> path components are left intact, because of possible symlinks.</p><pre><code><a href="System-Path-NameManip.html#v:normalise_path">normalise_path</a></code> = <code><a href="System-Path-NameManip.html#v:unslice_path">unslice_path</a></code> . <code><a href="System-Path-NameManip.html#v:slice_path">slice_path</a></code></pre></div></div><div class="top"><p class="src"><a name="v:slice_filename" class="def">slice_filename</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Path</p></td></tr><tr><td class="src">-&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</td><td class="doc"><p>List of components the file name is made up of</p></td></tr></table></div><div class="doc"><p>Split a file name in components. This are the base file name and the
suffixes, which are separated by dots. If the name starts with a dot, it is
regarded as part of the base name. The result is a list of file name
components. The filename may be a path. In this case, everything up to the
last path component will be returned as part of the base file name. The
path gets normalised thereby.</p><p>No empty suffixes are returned. If the file name contains several
consecutive dots, they are regared as part of the preceding file name
component.</p><p>Concateneting the name components and adding dots, reproduces the
original name, with a normalised path:
<code>concat . intersperse &quot;.&quot; . <code><a href="System-Path-NameManip.html#v:slice_filename">slice_filename</a></code> == <code>normalise</code></code>.</p><p>Note that the last path component might be &quot;<code>..</code>&quot;. Then it is not
possible to deduce the refered directory's name from the path. An IO
action for getting the real path is then necessary.</p><p>Examples:</p><pre><code><a href="System-Path-NameManip.html#v:slice_filename">slice_filename</a></code> &quot;a.b//./.foo.tar.gz&quot; == [&quot;a.b/.foo&quot;,&quot;tar&quot;,&quot;gz&quot;]
<code><a href="System-Path-NameManip.html#v:slice_filename">slice_filename</a></code> &quot;.x..y.&quot; == [&quot;.x.&quot;, &quot;y.&quot;]
</pre><p>See <code><a href="System-Path-NameManip.html#v:unslice_filename">unslice_filename</a></code>, <code>slice_filename'</code>.</p></div></div><div class="top"><p class="src"><a name="v:slice_filename-39-" class="def">slice_filename'</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>File name without path</p></td></tr><tr><td class="src">-&gt; [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</td><td class="doc"><p>List of components the file name is made up of</p></td></tr></table></div><div class="doc"><p>This is a variant of <code><a href="System-Path-NameManip.html#v:slice_filename">slice_filename</a></code>. It is like <code><a href="System-Path-NameManip.html#v:slice_filename">slice_filename</a></code>, except for
being more efficient, and the filename must not contain any preceding path,
since this case isn't considered.</p><p>See <code><a href="System-Path-NameManip.html#v:slice_filename">slice_filename</a></code>, <code><a href="System-Path-NameManip.html#v:unslice_filename">unslice_filename</a></code>.</p></div></div><div class="top"><p class="src"><a name="v:unslice_filename" class="def">unslice_filename</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</td><td class="doc"><p>List of file name components</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Name of the file which consists of the supplied components</p></td></tr></table></div><div class="doc"><p>Form file name from file name components, interspersing dots. This is
the inverse of <code><a href="System-Path-NameManip.html#v:slice_filename">slice_filename</a></code>, except for normalisation of any path.</p><pre>unslice_filename = concat . intersperse &quot;.&quot;</pre><p>See <code><a href="System-Path-NameManip.html#v:slice_filename">slice_filename</a></code>.</p></div></div><div class="top"><p class="src"><a name="v:split_path" class="def">split_path</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Path to be split</p></td></tr><tr><td class="src">-&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</td><td class="doc"><p>Directory and file name components of the path. The directory path is normalized.</p></td></tr></table></div><div class="doc"><p>Split a path in directory and file name. Only in the case that the
supplied path is empty, both parts are empty strings. Otherwise, <code>&quot;.&quot;</code> is filled in
for the corresponding part, if necessary. Unless the path is empty,
concatenating the returned path and file name components with a slash in
between, makes a valid path to the file.</p><p><code>split_path</code> splits off the last path component. This
isn't the same as the text after the last <code>/</code>.</p><p>Note that the last path component might be <code>&quot;..&quot;</code>. Then it is not
possible to deduce the refered directory's name from the path. Then an IO
action for getting the real path is necessary.</p><p>Examples:</p><pre>split_path &quot;/a/b/c&quot; == (&quot;/a/b&quot;, &quot;c&quot;)
split_path &quot;foo&quot; == (&quot;.&quot;, &quot;foo&quot;)
split_path &quot;foo/bar&quot; == (&quot;foo&quot;, &quot;bar&quot;)
split_path &quot;foo/..&quot; == (&quot;foo&quot;, &quot;..&quot;)
split_path &quot;.&quot; == (&quot;.&quot;, &quot;.&quot;)
split_path &quot;&quot; == (&quot;&quot;, &quot;&quot;)
split_path &quot;/foo&quot; == (&quot;/&quot;, &quot;foo&quot;)
split_path &quot;foo/&quot; == (&quot;.&quot;, &quot;foo&quot;)
split_path &quot;foo/.&quot; == (&quot;.&quot;, &quot;foo&quot;)
split_path &quot;foo///./bar&quot; == (&quot;foo&quot;, &quot;bar&quot;)</pre><p>See <code><a href="System-Path-NameManip.html#v:slice_path">slice_path</a></code>.</p></div></div><div class="top"><p class="src"><a name="v:dir_part" class="def">dir_part</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Get the directory part of a path.</p><pre>dir_part = fst . split_path</pre><p>See <code><a href="System-Path-NameManip.html#v:split_path">split_path</a></code>.</p></div></div><div class="top"><p class="src"><a name="v:filename_part" class="def">filename_part</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Get the last path component of a path.</p><pre>filename_part = snd . split_path</pre><p>Examples:</p><pre>filename_part &quot;foo/bar&quot; == &quot;bar&quot;
filename_part &quot;.&quot; == &quot;.&quot;</pre><p>See <code><a href="System-Path-NameManip.html#v:split_path">split_path</a></code>.</p></div></div><div class="top"><p class="src"><a name="v:unsplit_path" class="def">unsplit_path</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</td><td class="doc"><p>Directory and file name</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Path formed from the directory and file name parts</p></td></tr></table></div><div class="doc"><p>Inverse of <code><a href="System-Path-NameManip.html#v:split_path">split_path</a></code>, except for normalisation.</p><p>This concatenates two paths, and takes care of <code>&quot;.&quot;</code> and empty paths. When the two components are the result of <code>split_path</code>, then <code>unsplit_path</code>
creates a normalised path. It is best documented by its definition:</p><pre>unsplit_path (&quot;.&quot;, &quot;&quot;) = &quot;.&quot;
unsplit_path (&quot;&quot;, &quot;.&quot;) = &quot;.&quot;
unsplit_path (&quot;.&quot;, q) = q
unsplit_path (&quot;&quot;, q) = q
unsplit_path (p, &quot;&quot;) = p
unsplit_path (p, &quot;.&quot;) = p
unsplit_path (p, q) = p ++ &quot;/&quot; ++ q</pre><p>Examples:</p><pre>unsplit_path (&quot;&quot;, &quot;&quot;) == &quot;&quot;
unsplit_path (&quot;.&quot;, &quot;&quot;) == &quot;.&quot;
unsplit_path (&quot;.&quot;, &quot;.&quot;) == &quot;.&quot;
unsplit_path (&quot;foo&quot;, &quot;.&quot;) == &quot;foo&quot;</pre><p>See <code><a href="System-Path-NameManip.html#v:split_path">split_path</a></code>.</p></div></div><div class="top"><p class="src"><a name="v:split_filename" class="def">split_filename</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Path including the file name to be split</p></td></tr><tr><td class="src">-&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</td><td class="doc"><p>The normalised path with the file prefix, and the file suffix.</p></td></tr></table></div><div class="doc"><p>Split a file name in prefix and suffix. If there isn't any suffix in
the file name, then return an empty suffix. A dot at the beginning or at
the end is not regarded as introducing a suffix.</p><p>The last path component is what is being split. This isn't the same as
splitting the string at the last dot. For instance, if the file name
doesn't contain any dot, dots in previous path component's aren't mistaken
as introducing suffixes.</p><p>The path part is returned in normalised form. This means, <code>&quot;.&quot;</code> components
are removed, and multiple &quot;<code>/</code>&quot;s are reduced to one.</p><p>Note that there isn't any plausibility check performed on the suffix. If the file name doesn't have a suffix, but happens to contain a dot, then this
dot is mistaken as introducing a suffix.</p><p>Examples:</p><pre>split_filename &quot;path/to/foo.bar&quot; = (&quot;path/to/foo&quot;,&quot;bar&quot;)
split_filename &quot;path/to/foo&quot; = (&quot;path/to/foo&quot;,&quot;&quot;)
split_filename &quot;/path.to/foo&quot; = (&quot;/path.to/foo&quot;,&quot;&quot;)
split_filename &quot;a///./x&quot; = (&quot;a/x&quot;,&quot;&quot;)
split_filename &quot;dir.suffix/./&quot; = (&quot;dir&quot;,&quot;suffix&quot;)
split_filename &quot;Photographie, Das 20. Jahrhundert (300 dpi)&quot; = (&quot;Photographie, Das 20&quot;, &quot; Jahrhundert (300 dpi)&quot;)</pre><p>See <code><a href="System-Path-NameManip.html#v:slice_path">slice_path</a></code>, 'split_filename\''</p></div></div><div class="top"><p class="src"><a name="v:split_filename-39-" class="def">split_filename'</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Filename to be split</p></td></tr><tr><td class="src">-&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</td><td class="doc"><p>Base name and the last suffix</p></td></tr></table></div><div class="doc"><p>Variant of <code><a href="System-Path-NameManip.html#v:split_filename">split_filename</a></code>. This is a more efficient version
of <code><a href="System-Path-NameManip.html#v:split_filename">split_filename</a></code>, for the case that you know the string is
is a pure file name without any slashes.</p><p>See <code><a href="System-Path-NameManip.html#v:split_filename">split_filename</a></code>.</p></div></div><div class="top"><p class="src"><a name="v:unsplit_filename" class="def">unsplit_filename</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</td><td class="doc"><p>File name prefix and suffix</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Path</p></td></tr></table></div><div class="doc"><p>Inverse of <code><a href="System-Path-NameManip.html#v:split_filename">split_filename</a></code>. Concatenate prefix and suffix, adding
a dot in between, iff the suffix is not empty. The path part of the prefix is
normalised.</p><p>See <code><a href="System-Path-NameManip.html#v:split_filename">split_filename</a></code>.</p></div></div><div class="top"><p class="src"><a name="v:split3" class="def">split3</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Path to split</p></td></tr><tr><td class="src">-&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</td><td class="doc"><p>Directory part, base file name part and suffix part</p></td></tr></table></div><div class="doc"><p>Split a path in directory, base file name and suffix.</p></div></div><div class="top"><p class="src"><a name="v:unsplit3" class="def">unsplit3</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</td><td class="doc"><p>Directory part, base file name part and suffix part</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Path consisting of dir, base and suffix</p></td></tr></table></div><div class="doc"><p>Form path from directory, base file name and suffix parts.</p></div></div><div class="top"><p class="src"><a name="v:test_suffix" class="def">test_suffix</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Suffix to split off</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Path to test</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Prefix without the suffix or <code>Nothing</code></p></td></tr></table></div><div class="doc"><p>Test a path for a specific suffix and split it off.</p><p>If the path ends with the suffix, then the result is <code>Just
prefix</code>, where <code>prefix</code> is the normalised path
without the suffix. Otherwise it's <code>Nothing</code>.</p></div></div><div class="top"><p class="src"><a name="v:absolute_path" class="def">absolute_path</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>The path to be made absolute</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Absulte path</p></td></tr></table></div><div class="doc"><p>Make a path absolute, using the current working directory.</p><p>This makes a relative path absolute with respect to the current
working directory. An absolute path is returned unmodified.</p><p>The current working directory is determined with <code>getCurrentDirectory</code>
which means that symbolic links in it are expanded and the path is
normalised. This is different from <code>pwd</code>.</p></div></div><div class="top"><p class="src"><a name="v:absolute_path_by" class="def">absolute_path_by</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>The directory relative to which the path is made absolute</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>The path to be made absolute</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Absolute path</p></td></tr></table></div><div class="doc"><p>Make a path absolute.</p><p>This makes a relative path absolute with respect to a specified
directory. An absolute path is returned unmodified.</p></div></div><div class="top"><p class="src"><a name="v:absolute_path-39-" class="def">absolute_path'</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>The path to be made absolute</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>The directory relative to which the path is made absolute</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Absolute path</p></td></tr></table></div><div class="doc"><p>Make a path absolute.</p><p>This makes a relative path absolute with respect to a specified
directory. An absolute path is returned unmodified.</p><p>The order of the arguments can be confusing. You should rather use <code><a href="System-Path-NameManip.html#v:absolute_path_by">absolute_path_by</a></code>. <code>absolute_path'</code> is included for backwards compatibility.</p></div></div><div class="top"><p class="src"><a name="v:guess_dotdot_comps" class="def">guess_dotdot_comps</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</td><td class="doc"><p>List of path components</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> [<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>]</td><td class="doc"><p>In case the path could be transformed, the <code>&quot;..&quot;</code>-component free list of path components.</p></td></tr></table></div><div class="doc"><p>Guess the <code>&quot;..&quot;</code>-component free form of a path, specified as a list of path components, by syntactically removing them, along with the preceding
path components. This will produce
erroneous results when the path contains symlinks. If the path contains leading <code>&quot;..&quot;</code> components, or more <code>&quot;..&quot;</code> components than preceeding normal
components, then the <code>&quot;..&quot;</code> components can't be normalised away. In this case, the result is <code>Nothing</code>.</p></div></div><div class="top"><p class="src"><a name="v:guess_dotdot" class="def">guess_dotdot</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Path to be normalised</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>In case the path could be transformed, the normalised, <code>&quot;..&quot;</code>-component free form of the path.</p></td></tr></table></div><div class="doc"><p>Guess the <code>&quot;..&quot;</code>-component free, normalised form of a path. The transformation is purely syntactic. <code>&quot;..&quot;</code> path components will be removed, along
with their preceding path components. This will produce
erroneous results when the path contains symlinks. If the path contains leading <code>&quot;..&quot;</code> components, or more <code>&quot;..&quot;</code> components than preceeding normal
components, then the <code>&quot;..&quot;</code> components can't be normalised away. In this case, the result is <code>Nothing</code>.</p><pre>guess_dotdot = fmap unslice_path . guess_dotdot_comps . slice_path</pre></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,16 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.Path.WildMatch</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-Path-WildMatch.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2006-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.Path.WildMatch</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Wildcard matching</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Matching filenames with wildcards. See also <a href="System-Path-Glob.html">System.Path.Glob</a> for
support for generating lists of files based on wildcards.</p><p>Inspired by fnmatch.py, part of the Python standard library.</p><p>Written by John Goerzen, jgoerzen@complete.org</p><p>The input wildcard for functions in this module is expected to be in
the standard style of Posix shells.</p><p>That is:</p><pre>? matches exactly one character
\* matches zero or more characters
[list] matches any character in list
[!list] matches any character not in the list</pre><p>The returned regular expression will always end in $ but never begins
with ^, making it suitable for appending to the end of paths. If you want to
match a given filename directly, you should prepend the ^ character to the
returned value from this function.</p><p>Please note:</p><ul><li>Neither the path separator (the slash or backslash) nor the period carry
any special meaning for the functions in this module. That is, <code>*</code> will
match <code>/</code> in a filename. If this is not the behavior you want, you probably
want <a href="System-Path-Glob.html">System.Path.Glob</a> instead of this module.</li><li>Unlike the Unix shell, filenames that begin with a period are not ignored
by this module. That is, <code>*.txt</code> will match <code>.test.txt</code>.</li><li>This module does not current permit escaping of special characters.</li></ul></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:wildCheckCase">wildCheckCase</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></li><li class="src short"><a href="#v:wildToRegex">wildToRegex</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li></ul></div><div id="interface"><h1 id="g:1">Wildcard matching</h1><div class="top"><p class="src"><a name="v:wildCheckCase" class="def">wildCheckCase</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>The wildcard pattern to use as the base</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>The filename to check against it</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a></td><td class="doc"><p>Result</p></td></tr></table></div><div class="doc"><p>Check the given name against the given pattern, being case-sensitive.</p><p>The given pattern is forced to match the given name starting at the beginning.</p></div></div><div class="top"><p class="src"><a name="v:wildToRegex" class="def">wildToRegex</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Convert a wildcard to an (uncompiled) regular expression.</p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,29 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.Path</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-Path.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt;</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.Path</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Name processing</a></li><li><a href="#g:2">Directory Processing</a></li><li><a href="#g:3">Temporary Directories</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This module provides various helpful utilities for dealing with path and
file names, directories, and related support.</p><p>Written by John Goerzen, jgoerzen@complete.org</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:splitExt">splitExt</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a>)</li><li class="src short"><a href="#v:absNormPath">absNormPath</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:secureAbsNormPath">secureAbsNormPath</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:recurseDir">recurseDir</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [<a href="System-IO-HVFS.html#t:FilePath">FilePath</a>]</li><li class="src short"><a href="#v:recurseDirStat">recurseDirStat</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [(<a href="System-IO-HVFS.html#t:FilePath">FilePath</a>, <a href="System-IO-HVFS.html#t:HVFSStatEncap">HVFSStatEncap</a>)]</li><li class="src short"><a href="#v:recursiveRemove">recursiveRemove</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</li><li class="src short"><a href="#v:bracketCWD">bracketCWD</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a</li><li class="src short"><a href="#v:mktmpdir">mktmpdir</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:brackettmpdir">brackettmpdir</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a</li><li class="src short"><a href="#v:brackettmpdirCWD">brackettmpdirCWD</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a</li></ul></div><div id="interface"><h1 id="g:1">Name processing</h1><div class="top"><p class="src"><a name="v:splitExt" class="def">splitExt</a> :: <a Line truncated
the extension. The extension is considered to be all characters from the last
dot after the last slash to the end. Either returned string may be empty. </p></div></div><div class="top"><p class="src"><a name="v:absNormPath" class="def">absNormPath</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Absolute path for use with starting directory</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>The path name to make absolute</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Result</p></td></tr></table></div><div class="doc"><p>Make an absolute, normalized version of a path with all double slashes,
dot, and dotdot entries removed.</p><p>The first parameter is the base for the absolut calculation; in many cases,
it would correspond to the current working directory.</p><p>The second parameter is the pathname to transform. If it is already absolute,
the first parameter is ignored.</p><p>Nothing may be returned if there's an error; for instance, too many <code>..</code> entries
for the given path.</p></div></div><div class="top"><p class="src"><a name="v:secureAbsNormPath" class="def">secureAbsNormPath</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Absolute path for use with starting directory</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>The path to make absolute</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc empty">&nbsp;</td></tr></table></div><div class="doc"><p>Like absNormPath, but returns Nothing if the generated result is not
the passed base path or a subdirectory thereof. </p></div></div><h1 id="g:2">Directory Processing</h1><div class="top"><p class="src"><a name="v:recurseDir" class="def">recurseDir</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [<a href="System-IO-HVFS.html#t:FilePath">FilePath</a>]</p><div class="doc"><p>Obtain a recursive listing of all files/directories beneath
the specified directory. The traversal is depth-first
and the original
item is always present in the returned list.</p><p>If the passed value is not a directory, the return value
be only that value.</p><p>The &quot;.&quot; and &quot;..&quot; entries are removed from the data returned.</p></div></div><div class="top"><p class="src"><a name="v:recurseDirStat" class="def">recurseDirStat</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> [(<a href="System-IO-HVFS.html#t:FilePath">FilePath</a>, <a href="System-IO-HVFS.html#t:HVFSStatEncap">HVFSStatEncap</a>)]</p><div class="doc"><p>Like <code><a href="System-Path.html#v:recurseDir">recurseDir</a></code>, but return the stat() (System.Posix.Files.FileStatus)
information with them. This is an optimization if you will be statting files
yourself later.</p><p>The items are returned lazily.</p><p>WARNING: do not change your current working directory until you have consumed
all the items. Doing so could cause strange effects.</p><p>Alternatively, you may wish to pass an absolute path to this function.</p></div></div><div class="top"><p class="src"><a name="v:recursiveRemove" class="def">recursiveRemove</a> :: <a href="System-IO-HVFS.html#t:HVFS">HVFS</a> a =&gt; a -&gt; <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> ()</p><div class="doc"><p>Removes a file or a directory. If a directory, also removes all its
child files/directories.</p></div></div><div class="top"><p class="src"><a name="v:bracketCWD" class="def">bracketCWD</a> :: <a href="System-IO-HVFS.html#t:FilePath">FilePath</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a</p><div class="doc"><p>Changes the current working directory to the given path,
executes the given I/O action, then changes back to the original directory,
even if the I/O action raised an exception. </p></div></div><h1 id="g:3">Temporary Directories</h1><div class="top"><p class="src"><a name="v:mktmpdir" class="def">mktmpdir</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Creates a temporary directory for your use.</p><p>The passed string should be a template suitable for mkstemp; that is, end with
<code>&quot;XXXXXX&quot;</code>.</p><p>Your string should probably start with the value returned from
System.Directory.getTemporaryDirectory.</p><p>The name of the directory created will be returned.</p></div></div><div class="top"><p class="src"><a name="v:brackettmpdir" class="def">brackettmpdir</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a) -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a</p><div class="doc"><p>Creates a temporary directory for your use via <code><a href="System-Path.html#v:mktmpdir">mktmpdir</a></code>,
runs the specified action (passing in the directory name), then
removes the directory and all its contents when the action completes (or raises
an exception. </p></div></div><div class="top"><p class="src"><a name="v:brackettmpdirCWD" class="def">brackettmpdirCWD</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> a</p><div class="doc"><p>Runs the given I/O action with the CWD set to the given tmp dir,
removing the tmp dir and changing CWD back afterwards, even if there
was an exception. </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,5 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.Posix.Consts</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-Posix-Consts.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2005-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.Posix.Consts</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Exports some POSIX constants and functions that are not exported in fptools
by default.</p></div></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:blockSpecialMode" class="def">blockSpecialMode</a> :: <a href="System-IO-HVFS.html#t:FileMode">FileMode</a></p></div><div class="top"><p class="src"><a name="v:characterSpecialMode" class="def">characterSpecialMode</a> :: <a href="System-IO-HVFS.html#t:FileMode">FileMode</a></p></div><div class="top"><p class="src"><a name="v:namedPipeMode" class="def">namedPipeMode</a> :: <a href="System-IO-HVFS.html#t:FileMode">FileMode</a></p></div><div class="top"><p class="src"><a name="v:regularFileMode" class="def">regularFileMode</a> :: <a href="System-IO-HVFS.html#t:FileMode">FileMode</a></p></div><div class="top"><p class="src"><a name="v:directoryMode" class="def">directoryMode</a> :: <a href="System-IO-HVFS.html#t:FileMode">FileMode</a></p></div><div class="top"><p class="src"><a name="v:fileTypeModes" class="def">fileTypeModes</a> :: <a href="System-IO-HVFS.html#t:FileMode">FileMode</a></p></div><div class="top"><p class="src"><a name="v:socketMode" class="def">socketMode</a> :: <a href="System-IO-HVFS.html#t:FileMode">FileMode</a></p></div><div class="top"><p class="src"><a name="v:symbolicLinkMode" class="def">symbolicLinkMode</a> :: <a href="System-IO-HVFS.html#t:FileMode">FileMode</a></p></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,22 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.Time.ParseDate</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-Time-ParseDate.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>(c) by Bj&#246;rn Bringert</td></tr><tr><th>License</th><td>GPL2</td></tr><tr><th>Maintainer</th><td>Bj&#246;rn Bringert</td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.Time.ParseDate</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Utility for parsing dates.</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:parseCalendarTime">parseCalendarTime</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-locale-1.0.0.7/html/System-Locale.html#t:TimeLocale">TimeLocale</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:CalendarTime">CalendarTime</a></li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:parseCalendarTime" class="def">parseCalendarTime</a></p><div class="subs arguments"><p class="caption">Arguments</p><table><tr><td class="src">:: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-locale-1.0.0.7/html/System-Locale.html#t:TimeLocale">TimeLocale</a></td><td class="doc"><p>Time locale</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>Date format</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></td><td class="doc"><p>String to parse</p></td></tr><tr><td class="src">-&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:CalendarTime">CalendarTime</a></td><td class="doc"><p><code><a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#v:Nothing">Nothing</a></code> if parsing failed.</p></td></tr></table></div><div class="doc"><p>Parse a date string as formatted by <code><a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#v:formatCalendarTime">formatCalendarTime</a></code>.</p><p>The resulting <code><a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:CalendarTime">CalendarTime</a></code> will only have those fields set that
are represented by a format specifier in the format string, and those
fields will be set to the values given in the date string.
If the same field is specified multiple times, the rightmost
occurence takes precedence.</p><p>The resulting date is not neccessarily a valid date. For example,
if there is no day of the week specifier in the format string,
the value of <code><a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#v:ctWDay">ctWDay</a></code> will most likely be invalid.</p><p>Format specifiers are % followed by some character. All other
characters are treated literally. Whitespace in the format string
matches zero or more arbitrary whitespace characters.</p><p>Format specifiers marked with * are matched, but do not set any
field in the output.</p><p>Some of the format specifiers are marked as space-padded or
zero-padded. Regardless of this, space-padded, zero-padded
or unpadded inputs are accepted. Note that strings using
unpadded fields without separating the fields may cause
strange parsing.</p><p>Supported format specfiers:</p><dl><dt>%%</dt><dd>a % character.<dl><dt>%a</dt><dd>locale's abbreviated weekday name (Sun ... Sat)</dd><dt>%A</dt><dd>locale's full weekday name (Sunday .. Saturday)</dd><dt>%b</dt><dd>locale's abbreviated month name (Jan..Dec)</dd><dt>%B</dt><dd>locale's full month name (January..December)</dd><dt>%c</dt><dd>locale's date and time format (Thu Mar 25 17:47:03 CET 2004)</dd><dt>%C</dt><dd>century [00-99]</dd><dt>%d</dt><dd>day of month, zero padded (01..31)</dd><dt>%D</dt><dd>date (%m/%d/%y)</dd><dt>%e</dt><dd>day of month, space padded ( 1..31)</dd><dt>%h</dt><dd>same as %b</dd><dt>%H</dt><dd>hour, 24-hour clock, zero padded (00..23)</dd><dt>%I</dt><dd>hour, 12-hour clock, zero padded (01..12)</dd><dt>%j</dt><dd>day of the year, zero padded (001..366)</dd><dt>%k</dt><dd>hour, 24-hour clock, space padded ( 0..23)</dd><dt>%l</dt><dd>hour, 12-hour clock, space padded ( 1..12)</dd><dt>%m</dt><dd>month, zero padded (01..12)</dd><dt>%M</dt><dd>minute, zero padded (00..59)</dd><dt>%n</dt><dd>a newline character</dd><dt>%p</dt><dd>locale's AM or PM indicator</dd><dt>%r</dt><dd>locale's 12-hour time format (hh:mm:ss AM/PM)</dd><dt>%R</dt><dd>hours and minutes, 24-hour clock (hh:mm)</dd><dt>%s</dt><dd>* seconds since '00:00:00 1970-01-01 UTC'</dd><dt>%S</dt><dd>seconds, zero padded (00..59)</dd><dt>%t</dt><dd>a horizontal tab character</dd><dt>%T</dt><dd>time, 24-hour clock (hh:mm:ss)</dd><dt>%u</dt><dd>numeric day of the week (1=Monday, 7=Sunday)</dd><dt>%U</dt><dd>* week number, weeks starting on Sunday, zero padded (01-53)</dd><dt>%V</dt><dd>* week number (as per ISO-8601),
week 1 is the first week with a Thursday,
zero padded, (01-53)</dd><dt>%w</dt><dd>numeric day of the week, (0=Sunday, 6=Monday)</dd><dt>%W</dt><dd>* week number, weeks starting on Monday, zero padded (01-53)</dd><dt>%x</dt><dd>locale's preferred way of printing dates (%m/%d/%y)</dd><dt>%X</dt><dd>locale's preferred way of printing time. (%H:%M:%S)</dd><dt>%y</dt><dd>year, within century, zero padded (00..99)</dd><dt>%Y</dt><dd>year, including century. Not padded
(this is probably a bug, but formatCalendarTime does
it this way). (0-9999)</dd><dt>%Z</dt><dd>time zone abbreviation (e.g. CET) or RFC-822 style numeric
timezone (-0500) </dd></dl></dd></dl></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,20 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>System.Time.Utils</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_System-Time-Utils.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">System.Time.Utils</p></div><div id="description"><p class="caption">Description</p><div class="doc"><p>This module provides various Haskell utilities for dealing with times and
dates.</p><p>Written by John Goerzen, jgoerzen@complete.org</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><a href="#v:timelocal">timelocal</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:CalendarTime">CalendarTime</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a></li><li class="src short"><a href="#v:timegm">timegm</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:CalendarTime">CalendarTime</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a></li><li class="src short"><a href="#v:timeDiffToSecs">timeDiffToSecs</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:TimeDiff">TimeDiff</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a></li><li class="src short"><a href="#v:epoch">epoch</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:CalendarTime">CalendarTime</a></li><li class="src short"><a href="#v:epochToClockTime">epochToClockTime</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Real">Real</a> a =&gt; a -&gt; <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:ClockTime">ClockTime</a></li><li class="src short"><a href="#v:clockTimeToEpoch">clockTimeToEpoch</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Num">Num</a> a =&gt; <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:ClockTime">ClockTime</a> -&gt; a</li><li class="src short"><a href="#v:renderSecs">renderSecs</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li><li class="src short"><a href="#v:renderTD">renderTD</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:TimeDiff">TimeDiff</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></li></ul></div><div id="interface"><h1>Documentation</h1><div class="top"><p class="src"><a name="v:timelocal" class="def">timelocal</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:CalendarTime">CalendarTime</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/System-IO.html#t:IO">IO</a> <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a></p><div class="doc"><p>Converts the specified CalendarTime (see System.Time) to
seconds-since-epoch format.</p><p>The input CalendarTime is assumed to be the time as given in your local
timezone. All timezone and DST fields in the object are ignored.</p><p>This behavior is equivolent to the timelocal() and mktime() functions that
C programmers are accustomed to.</p><p>Please note that the behavior for this function during the hour immediately
before or after a DST switchover may produce a result with a different hour
than you expect.</p></div></div><div class="top"><p class="src"><a name="v:timegm" class="def">timegm</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:CalendarTime">CalendarTime</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a></p><div class="doc"><p>Converts the specified CalendarTime (see System.Time) to seconds-since-epoch time.</p><p>This conversion does respect the timezone specified on the input object.
If you want a conversion from UTC, specify ctTZ = 0 and ctIsDST = False.</p><p>When called like that, the behavior is equivolent to the GNU C function
timegm(). Unlike the C library, Haskell's CalendarTime supports
timezone information, so if such information is specified, it will impact
the result.</p></div></div><div class="top"><p class="src"><a name="v:timeDiffToSecs" class="def">timeDiffToSecs</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:TimeDiff">TimeDiff</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a></p><div class="doc"><p>Converts the given timeDiff to the number of seconds it represents. </p><p>Uses the same algorithm as normalizeTimeDiff in GHC. </p></div></div><div class="top"><p class="src"><a name="v:epoch" class="def">epoch</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:CalendarTime">CalendarTime</a></p><div class="doc"><p>January 1, 1970, midnight, UTC, represented as a CalendarTime. </p></div></div><div class="top"><p class="src"><a name="v:epochToClockTime" class="def">epochToClockTime</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Real">Real</a> a =&gt; a -&gt; <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:ClockTime">ClockTime</a></p><div class="doc"><p>Converts an Epoch time represented with an arbitrary Real to a ClockTime.
This input could be a CTime from Foreign.C.Types or an EpochTime from
System.Posix.Types. </p></div></div><div class="top"><p class="src"><a name="v:clockTimeToEpoch" class="def">clockTimeToEpoch</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Num">Num</a> a =&gt; <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:ClockTime">ClockTime</a> -&gt; a</p><div class="doc"><p>Converts a ClockTime to something represented with an arbitrary Real.
The result could be treated as a CTime from Foreign.C.Types or EpochTime from
System.Posix.Types. The inverse of <code><a href="System-Time-Utils.html#v:epochToClockTime">epochToClockTime</a></code>.</p><p>Fractions of a second are not preserved by this function. </p></div></div><div class="top"><p class="src"><a name="v:renderSecs" class="def">renderSecs</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Prelude.html#t:Integer">Integer</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Render a number of seconds as a human-readable amount. Shows the two
most significant places. For instance:</p><pre>renderSecs 121 = &quot;2m1s&quot;</pre><p>See also <code><a href="System-Time-Utils.html#v:renderTD">renderTD</a></code> for a function that works on a TimeDiff.</p></div></div><div class="top"><p class="src"><a name="v:renderTD" class="def">renderTD</a> :: <a href="file:///Users/sidharta/.cabal/share/doc/x86_64-osx-ghc-7.10.1/old-time-1.1.0.3/html/System-Time.html#t:TimeDiff">TimeDiff</a> -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a></p><div class="doc"><p>Like <code><a href="System-Time-Utils.html#v:renderSecs">renderSecs</a></code>, but takes a TimeDiff instead of an integer second
count. </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,10 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Text.ParserCombinators.Parsec.Utils</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();setSynopsis("mini_Text-ParserCombinators-Parsec-Utils.html");};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="module-header"><table class="info"><tr><th>Copyright</th><td>Copyright (C) 2004-2011 John Goerzen</td></tr><tr><th>License</th><td>BSD3</td></tr><tr><th>Maintainer</th><td>John Goerzen &lt;jgoerzen@complete.org&gt; </td></tr><tr><th>Stability</th><td>provisional</td></tr><tr><th>Portability</th><td>portable</td></tr><tr><th>Safe Haskell</th><td>None</td></tr><tr><th>Language</th><td>Haskell98</td></tr></table><p class="caption">Text.ParserCombinators.Parsec.Utils</p></div><div id="table-of-contents"><p class="caption">Contents</p><ul><li><a href="#g:1">Generalized Utilities</a></li><li><a href="#g:2">Other Utilities</a></li></ul></div><div id="description"><p class="caption">Description</p><div class="doc"><p>Written by John Goerzen, jgoerzen@complete.org</p></div></div><div id="synopsis"><p id="control.syn" class="caption expander" onclick="toggleSection('syn')">Synopsis</p><ul id="section.syn" class="hide" onclick="toggleSection('syn')"><li class="src short"><span class="keyword">type</span> <a href="#t:GeneralizedToken">GeneralizedToken</a> a = (SourcePos, a)</li><li class="src short"><span class="keyword">type</span> <a href="#t:GeneralizedTokenParser">GeneralizedTokenParser</a> a st b = GenParser (<a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedToken">GeneralizedToken</a> a) st b</li><li class="src short"><a href="#v:togtok">togtok</a> :: a -&gt; GenParser b st (<a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedToken">GeneralizedToken</a> a)</li><li class="src short"><a href="#v:tokeng">tokeng</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a =&gt; (a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> b) -&gt; <a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedTokenParser">GeneralizedTokenParser</a> a st b</li><li class="src short"><a href="#v:satisfyg">satisfyg</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a =&gt; (a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a>) -&gt; <a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedTokenParser">GeneralizedTokenParser</a> a st a</li><li class="src short"><a href="#v:oneOfg">oneOfg</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a) =&gt; [a] -&gt; <a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedTokenParser">GeneralizedTokenParser</a> a st a</li><li class="src short"><a href="#v:noneOfg">noneOfg</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a) =&gt; [a] -&gt; <a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedTokenParser">GeneralizedTokenParser</a> a st a</li><li class="src short"><a href="#v:specificg">specificg</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a) =&gt; a -&gt; <a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedTokenParser">GeneralizedTokenParser</a> a st a</li><li class="src short"><a href="#v:allg">allg</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a =&gt; <a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedTokenParser">GeneralizedTokenParser</a> a st [a]</li><li class="src short"><a href="#v:notMatching">notMatching</a> :: GenParser a b c -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; GenParser a b ()</li></ul></div><div id="interface"><h1 id="g:1">Generalized Utilities</h1><div class="doc"><p>These functions are generalized versions of
ones you might see in the Char parser.</p></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:GeneralizedToken" class="def">GeneralizedToken</a> a = (SourcePos, a)</p></div><div class="top"><p class="src"><span class="keyword">type</span> <a name="t:GeneralizedTokenParser" class="def">GeneralizedTokenParser</a> a st b = GenParser (<a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedToken">GeneralizedToken</a> a) st b</p></div><div class="top"><p class="src"><a name="v:togtok" class="def">togtok</a> :: a -&gt; GenParser b st (<a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedToken">GeneralizedToken</a> a)</p><div class="doc"><p>Generate (return) a <code><a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedToken">GeneralizedToken</a></code>. </p></div></div><div class="top"><p class="src"><a name="v:tokeng" class="def">tokeng</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a =&gt; (a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Maybe.html#t:Maybe">Maybe</a> b) -&gt; <a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedTokenParser">GeneralizedTokenParser</a> a st b</p><div class="doc"><p>Retrieve the next token from a <code><a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedToken">GeneralizedToken</a></code> stream.
The given function should return the value to use, or Nothing
to cause an error. </p></div></div><div class="top"><p class="src"><a name="v:satisfyg" class="def">satisfyg</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a =&gt; (a -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Bool.html#t:Bool">Bool</a>) -&gt; <a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedTokenParser">GeneralizedTokenParser</a> a st a</p><div class="doc"><p>A shortcut to <code><a href="Text-ParserCombinators-Parsec-Utils.html#v:tokeng">tokeng</a></code>; the test here is just a function that returns
a Bool. If the result is true; return that value -- otherwise, an error.</p></div></div><div class="top"><p class="src"><a name="v:oneOfg" class="def">oneOfg</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a) =&gt; [a] -&gt; <a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedTokenParser">GeneralizedTokenParser</a> a st a</p><div class="doc"><p>Matches one item in a list and returns it. </p></div></div><div class="top"><p class="src"><a name="v:noneOfg" class="def">noneOfg</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a) =&gt; [a] -&gt; <a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedTokenParser">GeneralizedTokenParser</a> a st a</p><div class="doc"><p>Matches one item not in a list and returns it. </p></div></div><div class="top"><p class="src"><a name="v:specificg" class="def">specificg</a> :: (<a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-Eq.html#t:Eq">Eq</a> a, <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a) =&gt; a -&gt; <a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedTokenParser">GeneralizedTokenParser</a> a st a</p><div class="doc"><p>Matches one specific token and returns it. </p></div></div><div class="top"><p class="src"><a name="v:allg" class="def">allg</a> :: <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Text-Show.html#t:Show">Show</a> a =&gt; <a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedTokenParser">GeneralizedTokenParser</a> a st [a]</p><div class="doc"><p>Matches all items and returns them </p></div></div><h1 id="g:2">Other Utilities</h1><div class="top"><p class="src"><a name="v:notMatching" class="def">notMatching</a> :: GenParser a b c -&gt; <a href="file:///usr/local/Cellar/ghc/7.10.1/share/doc/ghc/html/libraries/base-4.8.0.0/Data-String.html#t:String">String</a> -&gt; GenParser a b ()</p><div class="doc"><p>Running <code>notMatching p msg</code> will try to apply parser p.
If it fails, returns (). If it succeds, cause a failure and raise
the given error message. It will not consume input in either case. </p></div></div></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>MissingH-1.3.0.1: Large utility library (Index - A)</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="alphabet"><ul><li><a href="doc-index-A.html">A</a></li><li><a href="doc-index-B.html">B</a></li><li><a href="doc-index-C.html">C</a></li><li><a href="doc-index-D.html">D</a></li><li><a href="doc-index-E.html">E</a></li><li><a href="doc-index-F.html">F</a></li><li><a href="doc-index-G.html">G</a></li><li><a href="doc-index-H.html">H</a></li><li><a href="doc-index-I.html">I</a></li><li><a href="doc-index-J.html">J</a></li><li><a href="doc-index-K.html">K</a></li><li><a href="doc-index-L.html">L</a></li><li><a href="doc-index-M.html">M</a></li><li><a href="doc-index-N.html">N</a></li><li><a href="doc-index-O.html">O</a></li><li><a href="doc-index-P.html">P</a></li><li><a href="doc-index-Q.html">Q</a></li><li><a href="doc-index-R.html">R</a></li><li><a href="doc-index-S.html">S</a></li><li><a href="doc-index-T.html">T</a></li><li><a href="doc-index-U.html">U</a></li><li><a href="doc-index-V.html">V</a></li><li><a href="doc-index-W.html">W</a></li><li><a href="doc-index-X.html">X</a></li><li><a href="doc-index-Z.html">Z</a></li><li><a href="doc-index-All.html">All</a></li></ul></div><div id="index"><p class="caption">Index - A</p><table><tr><td class="src">ABCD</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Type/Class)</td><td class="module"><a href="Data-Hash-MD5.html#t:ABCD">Data.Hash.MD5</a></td></tr><tr><td class="alt">2 (Data Constructor)</td><td class="module"><a href="Data-Hash-MD5.html#v:ABCD">Data.Hash.MD5</a></td></tr><tr><td class="src">absNormPath</td><td class="module"><a href="System-Path.html#v:absNormPath">System.Path</a></td></tr><tr><td class="src">absolute_path</td><td class="module"><a href="System-Path-NameManip.html#v:absolute_path">System.Path.NameManip</a></td></tr><tr><td class="src">absolute_path'</td><td class="module"><a href="System-Path-NameManip.html#v:absolute_path-39-">System.Path.NameManip</a></td></tr><tr><td class="src">absolute_path_by</td><td class="module"><a href="System-Path-NameManip.html#v:absolute_path_by">System.Path.NameManip</a></td></tr><tr><td class="src">accessModes</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">accessTime</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Function)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Function)</td><td class="module"><a href="System-IO-StatCompat.html#v:accessTime">System.IO.StatCompat</a></td></tr><tr><td class="src">accessTimeHiRes</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">addCallback</td><td class="module"><a href="Data-Progress-Tracker.html#v:addCallback">Data.Progress.Tracker</a></td></tr><tr><td class="src">addComponent</td><td class="module"><a href="Data-Progress-Meter.html#v:addComponent">Data.Progress.Meter</a></td></tr><tr><td class="src">addFlags</td><td class="module"><a href="Network-Email-Mailbox.html#v:addFlags">Network.Email.Mailbox</a></td></tr><tr><td class="src">addParent</td><td class="module"><a href="Data-Progress-Tracker.html#v:addParent">Data.Progress.Tracker</a></td></tr><tr><td class="src">addToAL</td><td class="module"><a href="Data-List-Utils.html#v:addToAL">Data.List.Utils</a></td></tr><tr><td class="src">allg</td><td class="module"><a href="Text-ParserCombinators-Parsec-Utils.html#v:allg">Text.ParserCombinators.Parsec.Utils</a></td></tr><tr><td class="src">alwaysElemRIndex</td><td class="module"><a href="Data-List-Utils.html#v:alwaysElemRIndex">Data.List.Utils</a></td></tr><tr><td class="src">ANSWERED</td><td class="module"><a href="Network-Email-Mailbox.html#v:ANSWERED">Network.Email.Mailbox</a></td></tr><tr><td class="src">appendMessages</td><td class="module"><a href="Network-Email-Mailbox.html#v:appendMessages">Network.Email.Mailbox</a></td></tr><tr><td class="src">AsyncIOAvailable</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">autoDisplayMeter</td><td class="module"><a href="Data-Progress-Meter.html#v:autoDisplayMeter">Data.Progress.Meter</a></td></tr></table></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>MissingH-1.3.0.1: Large utility library (Index)</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="index"><p class="caption">Index</p><table><tr><td class="src">ABCD</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Type/Class)</td><td class="module"><a href="Data-Hash-MD5.html#t:ABCD">Data.Hash.MD5</a></td></tr><tr><td class="alt">2 (Data Constructor)</td><td class="module"><a href="Data-Hash-MD5.html#v:ABCD">Data.Hash.MD5</a></td></tr><tr><td class="src">absNormPath</td><td class="module"><a href="System-Path.html#v:absNormPath">System.Path</a></td></tr><tr><td class="src">absolute_path</td><td class="module"><a href="System-Path-NameManip.html#v:absolute_path">System.Path.NameManip</a></td></tr><tr><td class="src">absolute_path'</td><td class="module"><a href="System-Path-NameManip.html#v:absolute_path-39-">System.Path.NameManip</a></td></tr><tr><td class="src">absolute_path_by</td><td class="module"><a href="System-Path-NameManip.html#v:absolute_path_by">System.Path.NameManip</a></td></tr><tr><td class="src">accessModes</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">accessTime</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Function)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Function)</td><td class="module"><a href="System-IO-StatCompat.html#v:accessTime">System.IO.StatCompat</a></td></tr><tr><td class="src">accessTimeHiRes</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">addCallback</td><td class="module"><a href="Data-Progress-Tracker.html#v:addCallback">Data.Progress.Tracker</a></td></tr><tr><td class="src">addComponent</td><td class="module"><a href="Data-Progress-Meter.html#v:addComponent">Data.Progress.Meter</a></td></tr><tr><td class="src">addFlags</td><td class="module"><a href="Network-Email-Mailbox.html#v:addFlags">Network.Email.Mailbox</a></td></tr><tr><td class="src">addParent</td><td class="module"><a href="Data-Progress-Tracker.html#v:addParent">Data.Progress.Tracker</a></td></tr><tr><td class="src">addToAL</td><td class="module"><a href="Data-List-Utils.html#v:addToAL">Data.List.Utils</a></td></tr><tr><td class="src">allg</td><td class="module"><a href="Text-ParserCombinators-Parsec-Utils.html#v:allg">Text.ParserCombinators.Parsec.Utils</a></td></tr><tr><td class="src">alwaysElemRIndex</td><td class="module"><a href="Data-List-Utils.html#v:alwaysElemRIndex">Data.List.Utils</a></td></tr><tr><td class="src">ANSWERED</td><td class="module"><a href="Network-Email-Mailbox.html#v:ANSWERED">Network.Email.Mailbox</a></td></tr><tr><td class="src">appendMessages</td><td class="module"><a href="Network-Email-Mailbox.html#v:appendMessages">Network.Email.Mailbox</a></td></tr><tr><td class="src">AsyncIOAvailable</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">autoDisplayMeter</td><td class="module"><a href="Data-Progress-Meter.html#v:autoDisplayMeter">Data.Progress.Meter</a></td></tr><tr><td class="src">base</td><td class="module"><a href="Data-Quantity.html#v:base">Data.Quantity</a></td></tr><tr><td class="src">BinaryConvertible</td><td class="module"><a href="System-IO-Binary.html#t:BinaryConvertible">System.IO.Binary</a></td></tr><tr><td class="src">binaryOpts</td><td class="module"><a href="Data-Quantity.html#v:binaryOpts">Data.Quantity</a></td></tr><tr><td class="src">BinPacker</td><td class="module"><a href="Data-BinPacking.html#t:BinPacker">Data.BinPacking</a></td></tr><tr><td class="src">BinPackerError</td><td class="module"><a href="Data-BinPacking.html#t:BinPackerError">Data.BinPacking</a></td></tr><tr><td class="src">Bit</td><td class="module"><a href="Data-Compression-Inflate.html#t:Bit">Data.Compression.Inflate</a></td></tr><tr><td class="src">bits_to_word32</td><td class="module"><a href="Data-Compression-Inflate.html#v:bits_to_word32">Data.Compression.Inflate</a></td></tr><tr><td class="src">blockCopy</td><td class="module"><a href="System-IO-Binary.html#v:blockCopy">System.IO.Binary</a></td></tr><tr><td class="src">blockInteract</td><td class="module"><a href="System-IO-Binary.html#v:blockInteract">System.IO.Binary</a></td></tr><tr><td class="src">blockSpecialMode</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Function)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Function)</td><td class="module"><a href="System-Posix-Consts.html#v:blockSpecialMode">System.Posix.Consts</a></td></tr><tr><td class="src">BoolList</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Type/Class)</td><td class="module"><a href="Data-Hash-MD5.html#t:BoolList">Data.Hash.MD5</a></td></tr><tr><td class="alt">2 (Data Constructor)</td><td class="module"><a href="Data-Hash-MD5.html#v:BoolList">Data.Hash.MD5</a></td></tr><tr><td class="src">BPOther</td><td class="module"><a href="Data-BinPacking.html#v:BPOther">Data.BinPackinLine truncated
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>MissingH-1.3.0.1: Large utility library (Index - B)</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="alphabet"><ul><li><a href="doc-index-A.html">A</a></li><li><a href="doc-index-B.html">B</a></li><li><a href="doc-index-C.html">C</a></li><li><a href="doc-index-D.html">D</a></li><li><a href="doc-index-E.html">E</a></li><li><a href="doc-index-F.html">F</a></li><li><a href="doc-index-G.html">G</a></li><li><a href="doc-index-H.html">H</a></li><li><a href="doc-index-I.html">I</a></li><li><a href="doc-index-J.html">J</a></li><li><a href="doc-index-K.html">K</a></li><li><a href="doc-index-L.html">L</a></li><li><a href="doc-index-M.html">M</a></li><li><a href="doc-index-N.html">N</a></li><li><a href="doc-index-O.html">O</a></li><li><a href="doc-index-P.html">P</a></li><li><a href="doc-index-Q.html">Q</a></li><li><a href="doc-index-R.html">R</a></li><li><a href="doc-index-S.html">S</a></li><li><a href="doc-index-T.html">T</a></li><li><a href="doc-index-U.html">U</a></li><li><a href="doc-index-V.html">V</a></li><li><a href="doc-index-W.html">W</a></li><li><a href="doc-index-X.html">X</a></li><li><a href="doc-index-Z.html">Z</a></li><li><a href="doc-index-All.html">All</a></li></ul></div><div id="index"><p class="caption">Index - B</p><table><tr><td class="src">base</td><td class="module"><a href="Data-Quantity.html#v:base">Data.Quantity</a></td></tr><tr><td class="src">BinaryConvertible</td><td class="module"><a href="System-IO-Binary.html#t:BinaryConvertible">System.IO.Binary</a></td></tr><tr><td class="src">binaryOpts</td><td class="module"><a href="Data-Quantity.html#v:binaryOpts">Data.Quantity</a></td></tr><tr><td class="src">BinPacker</td><td class="module"><a href="Data-BinPacking.html#t:BinPacker">Data.BinPacking</a></td></tr><tr><td class="src">BinPackerError</td><td class="module"><a href="Data-BinPacking.html#t:BinPackerError">Data.BinPacking</a></td></tr><tr><td class="src">Bit</td><td class="module"><a href="Data-Compression-Inflate.html#t:Bit">Data.Compression.Inflate</a></td></tr><tr><td class="src">bits_to_word32</td><td class="module"><a href="Data-Compression-Inflate.html#v:bits_to_word32">Data.Compression.Inflate</a></td></tr><tr><td class="src">blockCopy</td><td class="module"><a href="System-IO-Binary.html#v:blockCopy">System.IO.Binary</a></td></tr><tr><td class="src">blockInteract</td><td class="module"><a href="System-IO-Binary.html#v:blockInteract">System.IO.Binary</a></td></tr><tr><td class="src">blockSpecialMode</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Function)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Function)</td><td class="module"><a href="System-Posix-Consts.html#v:blockSpecialMode">System.Posix.Consts</a></td></tr><tr><td class="src">BoolList</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Type/Class)</td><td class="module"><a href="Data-Hash-MD5.html#t:BoolList">Data.Hash.MD5</a></td></tr><tr><td class="alt">2 (Data Constructor)</td><td class="module"><a href="Data-Hash-MD5.html#v:BoolList">Data.Hash.MD5</a></td></tr><tr><td class="src">BPOther</td><td class="module"><a href="Data-BinPacking.html#v:BPOther">Data.BinPacking</a></td></tr><tr><td class="src">BPSizeTooLarge</td><td class="module"><a href="Data-BinPacking.html#v:BPSizeTooLarge">Data.BinPacking</a></td></tr><tr><td class="src">BPTooFewBins</td><td class="module"><a href="Data-BinPacking.html#v:BPTooFewBins">Data.BinPacking</a></td></tr><tr><td class="src">bracketCWD</td><td class="module"><a href="System-Path.html#v:bracketCWD">System.Path</a></td></tr><tr><td class="src">brackettmpdir</td><td class="module"><a href="System-Path.html#v:brackettmpdir">System.Path</a></td></tr><tr><td class="src">brackettmpdirCWD</td><td class="module"><a href="System-Path.html#v:brackettmpdirCWD">System.Path</a></td></tr><tr><td class="src">breakList</td><td class="module"><a href="Data-List-Utils.html#v:breakList">Data.List.Utils</a></td></tr><tr><td class="src">ByteCount</td><td class="module">System.IO.PlafCompat</td></tr></table></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>MissingH-1.3.0.1: Large utility library (Index - C)</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="alphabet"><ul><li><a href="doc-index-A.html">A</a></li><li><a href="doc-index-B.html">B</a></li><li><a href="doc-index-C.html">C</a></li><li><a href="doc-index-D.html">D</a></li><li><a href="doc-index-E.html">E</a></li><li><a href="doc-index-F.html">F</a></li><li><a href="doc-index-G.html">G</a></li><li><a href="doc-index-H.html">H</a></li><li><a href="doc-index-I.html">I</a></li><li><a href="doc-index-J.html">J</a></li><li><a href="doc-index-K.html">K</a></li><li><a href="doc-index-L.html">L</a></li><li><a href="doc-index-M.html">M</a></li><li><a href="doc-index-N.html">N</a></li><li><a href="doc-index-O.html">O</a></li><li><a href="doc-index-P.html">P</a></li><li><a href="doc-index-Q.html">Q</a></li><li><a href="doc-index-R.html">R</a></li><li><a href="doc-index-S.html">S</a></li><li><a href="doc-index-T.html">T</a></li><li><a href="doc-index-U.html">U</a></li><li><a href="doc-index-V.html">V</a></li><li><a href="doc-index-W.html">W</a></li><li><a href="doc-index-X.html">X</a></li><li><a href="doc-index-Z.html">Z</a></li><li><a href="doc-index-All.html">All</a></li></ul></div><div id="index"><p class="caption">Index - C</p><table><tr><td class="src">c2w8</td><td class="module"><a href="Data-Bits-Utils.html#v:c2w8">Data.Bits.Utils</a></td></tr><tr><td class="src">calc_crc32</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Function)</td><td class="module"><a href="Data-Hash-CRC32-GZip.html#v:calc_crc32">Data.Hash.CRC32.GZip</a></td></tr><tr><td class="alt">2 (Function)</td><td class="module"><a href="Data-Hash-CRC32-Posix.html#v:calc_crc32">Data.Hash.CRC32.Posix</a></td></tr><tr><td class="src">CCc</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Data Constructor)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Type/Class)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">CDev</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Data Constructor)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Type/Class)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">CGid</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Data Constructor)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Type/Class)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">characterSpecialMode</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Function)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Function)</td><td class="module"><a href="System-Posix-Consts.html#v:characterSpecialMode">System.Posix.Consts</a></td></tr><tr><td class="src">checkDebVersion</td><td class="module"><a href="System-Debian.html#v:checkDebVersion">System.Debian</a></td></tr><tr><td class="src">CIno</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Data Constructor)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Type/Class)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">clearMeter</td><td class="module"><a href="Data-Progress-Meter.html#v:clearMeter">Data.Progress.Meter</a></td></tr><tr><td class="src">ClockTick</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">clockTimeToEpoch</td><td class="module"><a href="System-Time-Utils.html#v:clockTimeToEpoch">System.Time.Utils</a></td></tr><tr><td class="src">closeSocketServer</td><td class="module"><a href="Network-SocketServer.html#v:closeSocketServer">Network.SocketServer</a></td></tr><tr><td class="src">CMode</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Data Constructor)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Type/Class)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">CNlink</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Data Constructor)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Type/Class)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">COff</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Data Constructor)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Type/Class)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">comment</td><td class="module"><a href="System-FileArchive-GZip.html#v:comment">System.FileArchive.GZip</a></td></tr><tr><td class="src">commonTypesMap</td><td class="module"><a href="Data-MIME-Types.html#v:commonTypesMap">Data.MIME.Types</a></td></tr><tr><td class="src">compareDebVersion</td><td class="module"><a href="System-Debian.html#v:compareDebVersion">System.Debian</a></td></tr><tr><td class="src">completedUnits</td><td class="module"><a href="Data-Progress-Tracker.html#v:completedUnits">Data.Progress.Tracker</a></td></tr><tr><td class="sLine truncated
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>MissingH-1.3.0.1: Large utility library (Index - D)</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="alphabet"><ul><li><a href="doc-index-A.html">A</a></li><li><a href="doc-index-B.html">B</a></li><li><a href="doc-index-C.html">C</a></li><li><a href="doc-index-D.html">D</a></li><li><a href="doc-index-E.html">E</a></li><li><a href="doc-index-F.html">F</a></li><li><a href="doc-index-G.html">G</a></li><li><a href="doc-index-H.html">H</a></li><li><a href="doc-index-I.html">I</a></li><li><a href="doc-index-J.html">J</a></li><li><a href="doc-index-K.html">K</a></li><li><a href="doc-index-L.html">L</a></li><li><a href="doc-index-M.html">M</a></li><li><a href="doc-index-N.html">N</a></li><li><a href="doc-index-O.html">O</a></li><li><a href="doc-index-P.html">P</a></li><li><a href="doc-index-Q.html">Q</a></li><li><a href="doc-index-R.html">R</a></li><li><a href="doc-index-S.html">S</a></li><li><a href="doc-index-T.html">T</a></li><li><a href="doc-index-U.html">U</a></li><li><a href="doc-index-V.html">V</a></li><li><a href="doc-index-W.html">W</a></li><li><a href="doc-index-X.html">X</a></li><li><a href="doc-index-Z.html">Z</a></li><li><a href="doc-index-All.html">All</a></li></ul></div><div id="index"><p class="caption">Index - D</p><table><tr><td class="src">DebVersion</td><td class="module"><a href="System-Debian.html#t:DebVersion">System.Debian</a></td></tr><tr><td class="src">decompress</td><td class="module"><a href="System-FileArchive-GZip.html#v:decompress">System.FileArchive.GZip</a></td></tr><tr><td class="src">defaultmtd</td><td class="module"><a href="Data-MIME-Types.html#v:defaultmtd">Data.MIME.Types</a></td></tr><tr><td class="src">defaultTimeSource</td><td class="module"><a href="Data-Progress-Tracker.html#v:defaultTimeSource">Data.Progress.Tracker</a></td></tr><tr><td class="src">DELETED</td><td class="module"><a href="Network-Email-Mailbox.html#v:DELETED">Network.Email.Mailbox</a></td></tr><tr><td class="src">deleteMessages</td><td class="module"><a href="Network-Email-Mailbox.html#v:deleteMessages">Network.Email.Mailbox</a></td></tr><tr><td class="src">delFromAL</td><td class="module"><a href="Data-List-Utils.html#v:delFromAL">Data.List.Utils</a></td></tr><tr><td class="src">depPart</td><td class="module"><a href="System-Debian-ControlParser.html#v:depPart">System.Debian.ControlParser</a></td></tr><tr><td class="src">detachDaemon</td><td class="module"><a href="System-Daemon.html#v:detachDaemon">System.Daemon</a></td></tr><tr><td class="src">DeviceID</td><td class="module">System.IO.PlafCompat, <a href="System-IO-HVFS.html#t:DeviceID">System.IO.HVFS</a></td></tr><tr><td class="src">deviceID</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Function)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Function)</td><td class="module"><a href="System-IO-StatCompat.html#v:deviceID">System.IO.StatCompat</a></td></tr><tr><td class="src">directoryMode</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Function)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Function)</td><td class="module"><a href="System-Posix-Consts.html#v:directoryMode">System.Posix.Consts</a></td></tr><tr><td class="src">dir_part</td><td class="module"><a href="System-Path-NameManip.html#v:dir_part">System.Path.NameManip</a></td></tr><tr><td class="src">displayMeter</td><td class="module"><a href="Data-Progress-Meter.html#v:displayMeter">Data.Progress.Meter</a></td></tr><tr><td class="src">DRAFT</td><td class="module"><a href="Network-Email-Mailbox.html#v:DRAFT">Network.Email.Mailbox</a></td></tr><tr><td class="src">dropWhileList</td><td class="module"><a href="Data-List-Utils.html#v:dropWhileList">Data.List.Utils</a></td></tr></table></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>MissingH-1.3.0.1: Large utility library (Index - E)</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="alphabet"><ul><li><a href="doc-index-A.html">A</a></li><li><a href="doc-index-B.html">B</a></li><li><a href="doc-index-C.html">C</a></li><li><a href="doc-index-D.html">D</a></li><li><a href="doc-index-E.html">E</a></li><li><a href="doc-index-F.html">F</a></li><li><a href="doc-index-G.html">G</a></li><li><a href="doc-index-H.html">H</a></li><li><a href="doc-index-I.html">I</a></li><li><a href="doc-index-J.html">J</a></li><li><a href="doc-index-K.html">K</a></li><li><a href="doc-index-L.html">L</a></li><li><a href="doc-index-M.html">M</a></li><li><a href="doc-index-N.html">N</a></li><li><a href="doc-index-O.html">O</a></li><li><a href="doc-index-P.html">P</a></li><li><a href="doc-index-Q.html">Q</a></li><li><a href="doc-index-R.html">R</a></li><li><a href="doc-index-S.html">S</a></li><li><a href="doc-index-T.html">T</a></li><li><a href="doc-index-U.html">U</a></li><li><a href="doc-index-V.html">V</a></li><li><a href="doc-index-W.html">W</a></li><li><a href="doc-index-X.html">X</a></li><li><a href="doc-index-Z.html">Z</a></li><li><a href="doc-index-All.html">All</a></li></ul></div><div id="index"><p class="caption">Index - E</p><table><tr><td class="src">eitherToMonadError</td><td class="module"><a href="Data-Either-Utils.html#v:eitherToMonadError">Data.Either.Utils</a></td></tr><tr><td class="src">elemRIndex</td><td class="module"><a href="Data-List-Utils.html#v:elemRIndex">Data.List.Utils</a></td></tr><tr><td class="src">encodingsMap</td><td class="module"><a href="Data-MIME-Types.html#v:encodingsMap">Data.MIME.Types</a></td></tr><tr><td class="src">endswith</td><td class="module"><a href="Data-List-Utils.html#v:endswith">Data.List.Utils</a>, <a href="Data-String-Utils.html#v:endswith">Data.String.Utils</a></td></tr><tr><td class="src">epoch</td><td class="module"><a href="System-Time-Utils.html#v:epoch">System.Time.Utils</a></td></tr><tr><td class="src">EpochTime</td><td class="module">System.IO.PlafCompat, <a href="System-IO-HVFS.html#t:EpochTime">System.IO.HVFS</a></td></tr><tr><td class="src">epochToClockTime</td><td class="module"><a href="System-Time-Utils.html#v:epochToClockTime">System.Time.Utils</a></td></tr><tr><td class="src">escapeRe</td><td class="module"><a href="Data-String-Utils.html#v:escapeRe">Data.String.Utils</a></td></tr><tr><td class="src">extra</td><td class="module"><a href="System-FileArchive-GZip.html#v:extra">System.FileArchive.GZip</a></td></tr></table></div></div><div id="footer"><p>Produced by <a href="http://www.haskell.org/haddock/">Haddock</a> version 2.16.0</p></div></body></html>
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>MissingH-1.3.0.1: Large utility library (Index - F)</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="alphabet"><ul><li><a href="doc-index-A.html">A</a></li><li><a href="doc-index-B.html">B</a></li><li><a href="doc-index-C.html">C</a></li><li><a href="doc-index-D.html">D</a></li><li><a href="doc-index-E.html">E</a></li><li><a href="doc-index-F.html">F</a></li><li><a href="doc-index-G.html">G</a></li><li><a href="doc-index-H.html">H</a></li><li><a href="doc-index-I.html">I</a></li><li><a href="doc-index-J.html">J</a></li><li><a href="doc-index-K.html">K</a></li><li><a href="doc-index-L.html">L</a></li><li><a href="doc-index-M.html">M</a></li><li><a href="doc-index-N.html">N</a></li><li><a href="doc-index-O.html">O</a></li><li><a href="doc-index-P.html">P</a></li><li><a href="doc-index-Q.html">Q</a></li><li><a href="doc-index-R.html">R</a></li><li><a href="doc-index-S.html">S</a></li><li><a href="doc-index-T.html">T</a></li><li><a href="doc-index-U.html">U</a></li><li><a href="doc-index-V.html">V</a></li><li><a href="doc-index-W.html">W</a></li><li><a href="doc-index-X.html">X</a></li><li><a href="doc-index-Z.html">Z</a></li><li><a href="doc-index-All.html">All</a></li></ul></div><div id="index"><p class="caption">Index - F</p><table><tr><td class="src">family</td><td class="module"><a href="Network-SocketServer.html#v:family">Network.SocketServer</a></td></tr><tr><td class="src">Fd</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Data Constructor)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Type/Class)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">fileAccess</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">fileExist</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">fileGroup</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Function)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Function)</td><td class="module"><a href="System-IO-StatCompat.html#v:fileGroup">System.IO.StatCompat</a></td></tr><tr><td class="src">FileID</td><td class="module">System.IO.PlafCompat, <a href="System-IO-HVFS.html#t:FileID">System.IO.HVFS</a></td></tr><tr><td class="src">fileID</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Function)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Function)</td><td class="module"><a href="System-IO-StatCompat.html#v:fileID">System.IO.StatCompat</a></td></tr><tr><td class="src">FileMode</td><td class="module">System.IO.PlafCompat, <a href="System-IO-HVFS.html#t:FileMode">System.IO.HVFS</a></td></tr><tr><td class="src">fileMode</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Function)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Function)</td><td class="module"><a href="System-IO-StatCompat.html#v:fileMode">System.IO.StatCompat</a></td></tr><tr><td class="src">filename</td><td class="module"><a href="System-FileArchive-GZip.html#v:filename">System.FileArchive.GZip</a></td></tr><tr><td class="src">FileNameLimit</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">FileNamesAreNotTruncated</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">filename_part</td><td class="module"><a href="System-Path-NameManip.html#v:filename_part">System.Path.NameManip</a></td></tr><tr><td class="src">FileOffset</td><td class="module">System.IO.PlafCompat, <a href="System-IO-HVFS.html#t:FileOffset">System.IO.HVFS</a></td></tr><tr><td class="src">fileOwner</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Function)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Function)</td><td class="module"><a href="System-IO-StatCompat.html#v:fileOwner">System.IO.StatCompat</a></td></tr><tr><td class="src">FilePath</td><td class="module"><a href="System-IO-HVFS.html#t:FilePath">System.IO.HVFS</a></td></tr><tr><td class="src">fileSize</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Function)</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="alt">2 (Function)</td><td class="module"><a href="System-IO-StatCompat.html#v:fileSize">System.IO.StatCompat</a></td></tr><tr><td class="alt">3 (Function)</td><td class="module"><a href="System-IO-HVFS-InstanceHelpers.html#v:fileSize">System.IO.HVFS.InstanceHelpers</a></td></tr><tr><td class="src">FileSizeBits</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">FileStatus</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">FileStatusCompat</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Type/Class)</td><td class="module"><a href="System-IO-StatCompat.html#t:FileStatusCompat">System.IO.StatCompat</a></td></tr><tr><td class="alt">2 (Data Constructor)</td><td class="module"><a href="System-IO-StatCompat.html#v:FileStatusCompat">SystemLine truncated
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>MissingH-1.3.0.1: Large utility library (Index - G)</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="alphabet"><ul><li><a href="doc-index-A.html">A</a></li><li><a href="doc-index-B.html">B</a></li><li><a href="doc-index-C.html">C</a></li><li><a href="doc-index-D.html">D</a></li><li><a href="doc-index-E.html">E</a></li><li><a href="doc-index-F.html">F</a></li><li><a href="doc-index-G.html">G</a></li><li><a href="doc-index-H.html">H</a></li><li><a href="doc-index-I.html">I</a></li><li><a href="doc-index-J.html">J</a></li><li><a href="doc-index-K.html">K</a></li><li><a href="doc-index-L.html">L</a></li><li><a href="doc-index-M.html">M</a></li><li><a href="doc-index-N.html">N</a></li><li><a href="doc-index-O.html">O</a></li><li><a href="doc-index-P.html">P</a></li><li><a href="doc-index-Q.html">Q</a></li><li><a href="doc-index-R.html">R</a></li><li><a href="doc-index-S.html">S</a></li><li><a href="doc-index-T.html">T</a></li><li><a href="doc-index-U.html">U</a></li><li><a href="doc-index-V.html">V</a></li><li><a href="doc-index-W.html">W</a></li><li><a href="doc-index-X.html">X</a></li><li><a href="doc-index-Z.html">Z</a></li><li><a href="doc-index-All.html">All</a></li></ul></div><div id="index"><p class="caption">Index - G</p><table><tr><td class="src">genCsvFile</td><td class="module"><a href="Data-CSV.html#v:genCsvFile">Data.CSV</a></td></tr><tr><td class="src">GeneralizedToken</td><td class="module"><a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedToken">Text.ParserCombinators.Parsec.Utils</a></td></tr><tr><td class="src">GeneralizedTokenParser</td><td class="module"><a href="Text-ParserCombinators-Parsec-Utils.html#t:GeneralizedTokenParser">Text.ParserCombinators.Parsec.Utils</a></td></tr><tr><td class="src">genericJoin</td><td class="module"><a href="Data-List-Utils.html#v:genericJoin">Data.List.Utils</a></td></tr><tr><td class="src">getAll</td><td class="module"><a href="Network-Email-Mailbox.html#v:getAll">Network.Email.Mailbox</a></td></tr><tr><td class="src">getBlocks</td><td class="module"><a href="System-IO-Binary.html#v:getBlocks">System.IO.Binary</a></td></tr><tr><td class="src">getBufStr</td><td class="module"><a href="System-IO-Binary.html#v:getBufStr">System.IO.Binary</a></td></tr><tr><td class="src">getBytes</td><td class="module"><a href="Data-Bits-Utils.html#v:getBytes">Data.Bits.Utils</a></td></tr><tr><td class="src">getETA</td><td class="module"><a href="Data-Progress-Tracker.html#v:getETA">Data.Progress.Tracker</a></td></tr><tr><td class="src">getETR</td><td class="module"><a href="Data-Progress-Tracker.html#v:getETR">Data.Progress.Tracker</a></td></tr><tr><td class="src">getFdPathVar</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">getFdStatus</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">getFileStatus</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">getFullPath</td><td class="module"><a href="System-IO-HVFS-InstanceHelpers.html#v:getFullPath">System.IO.HVFS.InstanceHelpers</a></td></tr><tr><td class="src">getFullSlice</td><td class="module"><a href="System-IO-HVFS-InstanceHelpers.html#v:getFullSlice">System.IO.HVFS.InstanceHelpers</a></td></tr><tr><td class="src">getMemoryBuffer</td><td class="module"><a href="System-IO-HVIO.html#v:getMemoryBuffer">System.IO.HVIO</a></td></tr><tr><td class="src">getMessages</td><td class="module"><a href="Network-Email-Mailbox.html#v:getMessages">Network.Email.Mailbox</a></td></tr><tr><td class="src">getPathVar</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">getSpeed</td><td class="module"><a href="Data-Progress-Tracker.html#v:getSpeed">Data.Progress.Tracker</a></td></tr><tr><td class="src">getSymbolicLinkStatus</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">get_next</td><td class="module"><a href="Data-Hash-MD5.html#v:get_next">Data.Hash.MD5</a></td></tr><tr><td class="src">glob</td><td class="module"><a href="System-Path-Glob.html#v:glob">System.Path.Glob</a></td></tr><tr><td class="src">grab</td><td class="module"><a href="Data-List-Utils.html#v:grab">Data.List.Utils</a></td></tr><tr><td class="src">groupExecuteMode</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">GroupID</td><td class="module">System.IO.PlafCompat, <a href="System-IO-HVFS.html#t:GroupID">System.IO.HVFS</a></td></tr><tr><td class="src">groupModes</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">groupReadMode</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">groupWriteMode</td><td class="module">System.IO.PlafCompat</td></tr><tr><td class="src">guessAllExtensions</td><td class="module"><a href="Data-MIME-Types.html#v:guessAllExtensions">Data.MIME.Types</a></td></tr><tr><td class="src">guessExtension</td><td class="Line truncated
@@ -0,0 +1,4 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>MissingH-1.3.0.1: Large utility library (Index - H)</title><link href="ocean.css" rel="stylesheet" type="text/css" title="Ocean" /><script src="haddock-util.js" type="text/javascript"></script><script type="text/javascript">//<![CDATA[
window.onload = function () {pageLoad();};
//]]>
</script></head><body><div id="package-header"><ul class="links" id="page-menu"><li><a href="index.html">Contents</a></li><li><a href="doc-index.html">Index</a></li></ul><p class="caption">MissingH-1.3.0.1: Large utility library</p></div><div id="content"><div id="alphabet"><ul><li><a href="doc-index-A.html">A</a></li><li><a href="doc-index-B.html">B</a></li><li><a href="doc-index-C.html">C</a></li><li><a href="doc-index-D.html">D</a></li><li><a href="doc-index-E.html">E</a></li><li><a href="doc-index-F.html">F</a></li><li><a href="doc-index-G.html">G</a></li><li><a href="doc-index-H.html">H</a></li><li><a href="doc-index-I.html">I</a></li><li><a href="doc-index-J.html">J</a></li><li><a href="doc-index-K.html">K</a></li><li><a href="doc-index-L.html">L</a></li><li><a href="doc-index-M.html">M</a></li><li><a href="doc-index-N.html">N</a></li><li><a href="doc-index-O.html">O</a></li><li><a href="doc-index-P.html">P</a></li><li><a href="doc-index-Q.html">Q</a></li><li><a href="doc-index-R.html">R</a></li><li><a href="doc-index-S.html">S</a></li><li><a href="doc-index-T.html">T</a></li><li><a href="doc-index-U.html">U</a></li><li><a href="doc-index-V.html">V</a></li><li><a href="doc-index-W.html">W</a></li><li><a href="doc-index-X.html">X</a></li><li><a href="doc-index-Z.html">Z</a></li><li><a href="doc-index-All.html">All</a></li></ul></div><div id="index"><p class="caption">Index - H</p><table><tr><td class="src">handleHandler</td><td class="module"><a href="Network-SocketServer.html#v:handleHandler">Network.SocketServer</a></td></tr><tr><td class="src">handleOne</td><td class="module"><a href="Network-SocketServer.html#v:handleOne">Network.SocketServer</a></td></tr><tr><td class="src">HandlerT</td><td class="module"><a href="Network-SocketServer.html#t:HandlerT">Network.SocketServer</a></td></tr><tr><td class="src">hasAny</td><td class="module"><a href="Data-List-Utils.html#v:hasAny">Data.List.Utils</a></td></tr><tr><td class="src">hasKeyAL</td><td class="module"><a href="Data-List-Utils.html#v:hasKeyAL">Data.List.Utils</a></td></tr><tr><td class="src">hBlockCopy</td><td class="module"><a href="System-IO-Binary.html#v:hBlockCopy">System.IO.Binary</a></td></tr><tr><td class="src">hBlockInteract</td><td class="module"><a href="System-IO-Binary.html#v:hBlockInteract">System.IO.Binary</a></td></tr><tr><td class="src">hCopy</td><td class="module"><a href="System-IO-Utils.html#v:hCopy">System.IO.Utils</a></td></tr><tr><td class="src">hCopyProgress</td><td class="module"><a href="System-IO-Utils.html#v:hCopyProgress">System.IO.Utils</a></td></tr><tr><td class="src">hDecompress</td><td class="module"><a href="System-FileArchive-GZip.html#v:hDecompress">System.FileArchive.GZip</a></td></tr><tr><td class="src">Header</td><td>&nbsp;</td></tr><tr><td class="alt">1 (Type/Class)</td><td class="module"><a href="System-FileArchive-GZip.html#t:Header">System.FileArchive.GZip</a></td></tr><tr><td class="alt">2 (Data Constructor)</td><td class="module"><a href="System-FileArchive-GZip.html#v:Header">System.FileArchive.GZip</a></td></tr><tr><td class="src">hFullBlockInteract</td><td class="module"><a href="System-IO-Binary.html#v:hFullBlockInteract">System.IO.Binary</a></td></tr><tr><td class="src">hFullGetBlocks</td><td class="module"><a href="System-IO-Binary.html#v:hFullGetBlocks">System.IO.Binary</a></td></tr><tr><td class="src">hFullGetBufStr</td><td class="module"><a href="System-IO-Binary.html#v:hFullGetBufStr">System.IO.Binary</a></td></tr><tr><td class="src">hGetBlocks</td><td class="module"><a href="System-IO-Binary.html#v:hGetBlocks">System.IO.Binary</a></td></tr><tr><td class="src">hGetBufStr</td><td class="module"><a href="System-IO-Binary.html#v:hGetBufStr">System.IO.Binary</a></td></tr><tr><td class="src">hGetLines</td><td class="module"><a href="System-IO-Utils.html#v:hGetLines">System.IO.Utils</a></td></tr><tr><td class="src">hInteract</td><td class="module"><a href="System-IO-Utils.html#v:hInteract">System.IO.Utils</a></td></tr><tr><td class="src">hLineCopy</td><td class="module"><a href="System-IO-Utils.html#v:hLineCopy">System.IO.Utils</a></td></tr><tr><td class="src">hLineInteract</td><td class="module"><a href="System-IO-Utils.html#v:hLineInteract">System.IO.Utils</a></td></tr><tr><td class="src">hPipeBoth</td><td class="module"><a href="System-Cmd-Utils.html#v:hPipeBoth">System.Cmd.Utils</a></td></tr><tr><td class="src">hPipeFrom</td><td class="module"><a href="System-Cmd-Utils.html#v:hPipeFrom">System.Cmd.Utils</a></td></tr><tr><td class="src">hPipeTo</td><td class="module"><a href="System-Cmd-Utils.html#v:hPipeTo">System.Cmd.Utils</a></td></tr><tr><td class="src">hPutBufStr</td><td class="module"><a href="System-IO-Binary.html#v:hPutBufStr">System.IO.Binary</a></td></tr><tr><td class="src">hPutStrLns</td><td class="module"><a href="System-IO-Utils.html#v:hPutStrLns">System.IO.Utils</a></td></tr><tr><td class="src">hReadMIMETypes</td><td class="module"><a href="Data-MIME-Types.html#v:hReadMIMETypes">DatLine truncated
Loaded 100 of 2440 files, more files were not shown because too many files have changed in this diff. Show more