Sophie

Sophie

distrib > Mandriva > 2010.0 > i586 > media > contrib-release > by-pkgid > 14f9d1392cdb31b82b42df8a6fcda1e4 > files > 41

ocaml-res-devel-3.2.0-1mdv2010.0.i586.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<link rel="stylesheet" href="style.css" type="text/css">
<meta content="text/html; charset=iso-8859-1" http-equiv="Content-Type">
<link rel="Start" href="index.html">
<link rel="previous" href="Res.Floats.html">
<link rel="next" href="Res.Weak.html">
<link rel="Up" href="Res.html">
<link title="Index of types" rel=Appendix href="index_types.html">
<link title="Index of values" rel=Appendix href="index_values.html">
<link title="Index of modules" rel=Appendix href="index_modules.html">
<link title="Index of module types" rel=Appendix href="index_module_types.html">
<link title="Strat" rel="Chapter" href="Strat.html">
<link title="Pres_intf" rel="Chapter" href="Pres_intf.html">
<link title="Nopres_intf" rel="Chapter" href="Nopres_intf.html">
<link title="Weak_intf" rel="Chapter" href="Weak_intf.html">
<link title="Res" rel="Chapter" href="Res.html"><link title="Signatures and types" rel="Section" href="#6_Signaturesandtypes">
<link title="Index and length information" rel="Section" href="#6_Indexandlengthinformation">
<link title="Getting and setting" rel="Section" href="#6_Gettingandsetting">
<link title="Creation of resizable arrays" rel="Section" href="#6_Creationofresizablearrays">
<link title="Strategy handling" rel="Section" href="#6_Strategyhandling">
<link title="Copying, blitting and range extraction" rel="Section" href="#6_Copyingblittingandrangeextraction">
<link title="Combining resizable arrays" rel="Section" href="#6_Combiningresizablearrays">
<link title="Adding and removing elements" rel="Section" href="#6_Addingandremovingelements">
<link title="Swapping" rel="Section" href="#6_Swapping">
<link title="Array conversions" rel="Section" href="#6_Arrayconversions">
<link title="List conversions" rel="Section" href="#6_Listconversions">
<link title="Iterators" rel="Section" href="#6_Iterators">
<link title="Scanning of resizable arrays" rel="Section" href="#6_Scanningofresizablearrays">
<link title="Searching of resizable arrays" rel="Section" href="#6_Searchingofresizablearrays">
<link title="UNSAFE STUFF - USE WITH CAUTION!" rel="Section" href="#6_UNSAFESTUFFUSEWITHCAUTION">
<title>Res.Bits</title>
</head>
<body>
<div class="navbar"><a href="Res.Floats.html">Previous</a>
&nbsp;<a href="Res.html">Up</a>
&nbsp;<a href="Res.Weak.html">Next</a>
</div>
<center><h1>Module <a href="type_Res.Bits.html">Res.Bits</a></h1></center>
<br>
<pre><span class="keyword">module</span> Bits: <code class="type"><a href="Nopres_intf.T.html">Nopres_intf.T</a></code><code class="type">  with module Strategy = BitDefStrat and type el = bool</code></pre>Resizable bit vector using the default reallocation strategy.<br>
<hr width="100%">
<br>
<a name="6_Signaturesandtypes"></a>
<h6>Signatures and types</h6><br>
<pre><span class="keyword">module</span> <a href="Nopres_intf.T.Strategy.html">Strategy</a>: <code class="type"><a href="Strat.T.html">Strat.T</a></code><code class="type"> </code></pre><div class="info">
Module implementing the reallocation strategy
</div>
<pre><span class="keyword">type</span> <a name="TYPEstrategy"></a><code class="type"></code>strategy = <code class="type">Strategy.t</code> </pre>
<div class="info">
Type of reallocation strategy<br>
</div>

<pre><span class="keyword">type</span> <a name="TYPEt"></a><code class="type"></code>t </pre>
<div class="info">
Type of resizable arrays<br>
</div>

<pre><span class="keyword">type</span> <a name="TYPEel"></a><code class="type"></code>el </pre>
<div class="info">
Type of the elements in the resizable array<br>
</div>

<br>
<a name="6_Indexandlengthinformation"></a>
<h6>Index and length information</h6><br>
<pre><span class="keyword">val</span> <a name="VALlength"></a>length : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int</code></pre><div class="info">
<code class="code">length ra</code><br>
<b>Returns</b> (virtual) length of resizable array <code class="code">ra</code>
      excluding the reserved space.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALlix"></a>lix : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int</code></pre><div class="info">
<code class="code">lix ra</code><br>
<b>Returns</b> (virtual) last index of resizable array <code class="code">ra</code>
      excluding the reserved space.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALreal_length"></a>real_length : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int</code></pre><div class="info">
<code class="code">real_length ra</code><br>
<b>Returns</b> (real) length of resizable array <code class="code">ra</code>
      including the reserved space.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALreal_lix"></a>real_lix : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int</code></pre><div class="info">
<code class="code">real_lix ra</code><br>
<b>Returns</b> (real) last index of resizable array <code class="code">ra</code>
      including the reserved space.<br>
</div>
<br>
<a name="6_Gettingandsetting"></a>
<h6>Getting and setting</h6><br>
<pre><span class="keyword">val</span> <a name="VALget"></a>get : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> <a href="Nopres_intf.T.html#TYPEel">el</a></code></pre><div class="info">
<code class="code">get ra n</code><br>
<b>Raises</b> <code>Invalid_argument</code> if index out of bounds.<br>
<b>Returns</b> the <code class="code">n</code>th element of <code class="code">ra</code>.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALset"></a>set : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> <a href="Nopres_intf.T.html#TYPEel">el</a> -> unit</code></pre><div class="info">
<code class="code">set ra n</code> sets the <code class="code">n</code>th element of <code class="code">ra</code>.<br>
<b>Raises</b> <code>Invalid_argument</code> if index out of bounds.<br>
</div>
<br>
<a name="6_Creationofresizablearrays"></a>
<h6>Creation of resizable arrays</h6><br>
<pre><span class="keyword">val</span> <a name="VALsempty"></a>sempty : <code class="type"><a href="Nopres_intf.T.html#TYPEstrategy">strategy</a> -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">sempty s</code><br>
<b>Returns</b> an empty resizable array using strategy <code class="code">s</code>.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALempty"></a>empty : <code class="type">unit -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">empty ()</code> same as <code class="code">sempty</code> but uses default strategy.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALscreate"></a>screate : <code class="type"><a href="Nopres_intf.T.html#TYPEstrategy">strategy</a> -> int -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">screate s n</code><br>
<b>Returns</b> a resizable array with strategy <code class="code">s</code>
      containing <code class="code">n</code> arbitrary elements.
<p>

      <em>Attention: the contents is <b>not</b> specified!</em><br>
</div>
<pre><span class="keyword">val</span> <a name="VALcreate"></a>create : <code class="type">int -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">create n</code> same as <code class="code">screate</code> but uses default strategy.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALsmake"></a>smake : <code class="type"><a href="Nopres_intf.T.html#TYPEstrategy">strategy</a> -> int -> <a href="Nopres_intf.T.html#TYPEel">el</a> -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">smake s n el</code><br>
<b>Returns</b> a resizable array of length <code class="code">n</code>
      containing element <code class="code">el</code> only using strategy <code class="code">s</code>.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALmake"></a>make : <code class="type">int -> <a href="Nopres_intf.T.html#TYPEel">el</a> -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">make n el</code> same as <code class="code">smake</code> but uses default strategy.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALsinit"></a>sinit : <code class="type"><a href="Nopres_intf.T.html#TYPEstrategy">strategy</a> -> int -> (int -> <a href="Nopres_intf.T.html#TYPEel">el</a>) -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">sinit s n f</code><br>
<b>Returns</b> an array of length <code class="code">n</code> containing
      elements that were created by applying function <code class="code">f</code> to the index,
      using strategy <code class="code">s</code>.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALinit"></a>init : <code class="type">int -> (int -> <a href="Nopres_intf.T.html#TYPEel">el</a>) -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">init n f</code> sames as <code class="code">sinit</code> but uses default strategy.<br>
</div>
<br>
<a name="6_Strategyhandling"></a>
<h6>Strategy handling</h6><br>
<pre><span class="keyword">val</span> <a name="VALget_strategy"></a>get_strategy : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> <a href="Nopres_intf.T.html#TYPEstrategy">strategy</a></code></pre><div class="info">
<code class="code">get_strategy ra</code><br>
<b>Returns</b> the reallocation strategy used by
      resizable array <code class="code">ra</code>.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALset_strategy"></a>set_strategy : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> <a href="Nopres_intf.T.html#TYPEstrategy">strategy</a> -> unit</code></pre><div class="info">
<code class="code">set_strategy ra s</code> sets the reallocation strategy of
      resizable array <code class="code">ra</code> to <code class="code">s</code>, possibly causing an immediate
      reallocation.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALput_strategy"></a>put_strategy : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> <a href="Nopres_intf.T.html#TYPEstrategy">strategy</a> -> unit</code></pre><div class="info">
<code class="code">put_strategy ra s</code> sets the reallocation strategy of
      resizable array <code class="code">ra</code> to <code class="code">s</code>. Reallocation is only done at later
      changes in size.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALenforce_strategy"></a>enforce_strategy : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> unit</code></pre><div class="info">
<code class="code">enforce_strategy ra</code> forces a reallocation if necessary
      (e.g. after a <code class="code">put_strategy</code>.<br>
</div>
<br>
<a name="6_Copyingblittingandrangeextraction"></a>
<h6>Copying, blitting and range extraction</h6><br>
<pre><span class="keyword">val</span> <a name="VALcopy"></a>copy : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">copy ra</code><br>
<b>Returns</b> a copy of resizable array <code class="code">ra</code>. The two
      arrays share the same strategy!<br>
</div>
<pre><span class="keyword">val</span> <a name="VALsub"></a>sub : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> int -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">sub ra ofs len</code><br>
<b>Raises</b> <code>Invalid_argument</code> if parameters do not denote a correct
      subarray.<br>
<b>Returns</b> a resizable subarray of length <code class="code">len</code>
      from resizable array <code class="code">ra</code> starting at offset <code class="code">ofs</code> using the
      default strategy.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALfill"></a>fill : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> int -> <a href="Nopres_intf.T.html#TYPEel">el</a> -> unit</code></pre><div class="info">
<code class="code">fill ra ofs len el</code> fills resizable array <code class="code">ra</code> from offset
      <code class="code">ofs</code> with <code class="code">len</code> elements <code class="code">el</code>, possibly adding elements at the
      end. Raises <code class="code">Invalid_argument</code> if offset <code class="code">ofs</code> is larger than the
      length of the array.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALblit"></a>blit : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> int -> unit</code></pre><div class="info">
<code class="code">blit ra1 ofs1 ra2 ofs2 len</code> blits resizable array <code class="code">ra1</code> onto
      <code class="code">ra2</code> reading <code class="code">len</code> elements from offset <code class="code">ofs1</code> and writing them
      to <code class="code">ofs2</code>, possibly adding elements at the end of ra2. Raises
      <code class="code">Invalid_argument</code> if <code class="code">ofs1</code> and <code class="code">len</code> do not designate a valid
      subarray of <code class="code">ra1</code> or if <code class="code">ofs2</code> is larger than the length of
      <code class="code">ra2</code>.<br>
</div>
<br>
<a name="6_Combiningresizablearrays"></a>
<h6>Combining resizable arrays</h6><br>
<pre><span class="keyword">val</span> <a name="VALappend"></a>append : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">append ra1 ra2</code><br>
<b>Returns</b> a new resizable array using the
      default strategy and copying <code class="code">ra1</code> and <code class="code">ra2</code> in this order onto
      it.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALconcat"></a>concat : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> list -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">concat l</code><br>
<b>Returns</b> a new resizable array using the default
      strategy and copying all resizable arrays in <code class="code">l</code> in their respective
      order onto it.<br>
</div>
<br>
<a name="6_Addingandremovingelements"></a>
<h6>Adding and removing elements</h6><br>
<pre><span class="keyword">val</span> <a name="VALadd_one"></a>add_one : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> <a href="Nopres_intf.T.html#TYPEel">el</a> -> unit</code></pre><div class="info">
<code class="code">add_one ra el</code> adds element <code class="code">el</code> to resizable array <code class="code">ra</code>,
      possibly causing a reallocation.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALremove_one"></a>remove_one : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> unit</code></pre><div class="info">
<code class="code">remove_one ra</code> removes the last element of resizable array
      <code class="code">ra</code>, possibly causing a reallocation.<br>
<b>Raises</b> <code>Failure</code> if the array is empty.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALremove_n"></a>remove_n : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> unit</code></pre><div class="info">
<code class="code">remove_n ra n</code> removes the last n elements of resizable
      array <code class="code">ra</code>, possibly causing a reallocation.<br>
<b>Raises</b> <code>Invalid_arg</code> if there are not enough elements or <code class="code">n &lt; 0</code>.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALremove_range"></a>remove_range : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> int -> unit</code></pre><div class="info">
<code class="code">remove_range ra ofs len</code> removes <code class="code">len</code> elements from resizable
      array <code class="code">ra</code> starting at <code class="code">ofs</code> and possibly causing a
      reallocation.<br>
<b>Raises</b> <code>Invalid_argument</code> if range is invalid.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALclear"></a>clear : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> unit</code></pre><div class="info">
<code class="code">clear ra</code> removes all elements from resizable array <code class="code">ra</code>,
      possibly causing a reallocation.<br>
</div>
<br>
<a name="6_Swapping"></a>
<h6>Swapping</h6><br>
<pre><span class="keyword">val</span> <a name="VALswap"></a>swap : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> int -> unit</code></pre><div class="info">
<code class="code">swap ra n m</code> swaps elements at indices <code class="code">n</code> and <code class="code">m</code>.<br>
<b>Raises</b> <code>Invalid_argument</code> if any index is out of range.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALswap_in_last"></a>swap_in_last : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> unit</code></pre><div class="info">
<code class="code">swap_in_last ra n</code> swaps the last element with the one at
      position <code class="code">n</code>.<br>
<b>Raises</b> <code>Invalid_argument</code> if index <code class="code">n</code> is out of range.<br>
</div>
<br>
<a name="6_Arrayconversions"></a>
<h6>Array conversions</h6><br>
<pre><span class="keyword">val</span> <a name="VALto_array"></a>to_array : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> <a href="Nopres_intf.T.html#TYPEel">el</a> array</code></pre><div class="info">
<code class="code">to_array ra</code> converts a resizable array to a standard one.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALsof_array"></a>sof_array : <code class="type"><a href="Nopres_intf.T.html#TYPEstrategy">strategy</a> -> <a href="Nopres_intf.T.html#TYPEel">el</a> array -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">sof_array s ar</code> converts a standard array to a resizable one,
      using strategy <code class="code">s</code>.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALof_array"></a>of_array : <code class="type"><a href="Nopres_intf.T.html#TYPEel">el</a> array -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">of_array ar</code> converts a standard array to a resizable one
      using the default strategy.<br>
</div>
<br>
<a name="6_Listconversions"></a>
<h6>List conversions</h6><br>
<pre><span class="keyword">val</span> <a name="VALto_list"></a>to_list : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> <a href="Nopres_intf.T.html#TYPEel">el</a> list</code></pre><div class="info">
<code class="code">to_list ra</code> converts resizable array <code class="code">ra</code> to a list.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALsof_list"></a>sof_list : <code class="type"><a href="Nopres_intf.T.html#TYPEstrategy">strategy</a> -> <a href="Nopres_intf.T.html#TYPEel">el</a> list -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">sof_list s l</code> creates a resizable array using strategy <code class="code">s</code> and
      the elements in list <code class="code">l</code>.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALof_list"></a>of_list : <code class="type"><a href="Nopres_intf.T.html#TYPEel">el</a> list -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">of_list l</code> creates a resizable array using the default
      strategy and the elements in list <code class="code">l</code>.<br>
</div>
<br>
<a name="6_Iterators"></a>
<h6>Iterators</h6><br>
<pre><span class="keyword">val</span> <a name="VALiter"></a>iter : <code class="type">(<a href="Nopres_intf.T.html#TYPEel">el</a> -> unit) -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> unit</code></pre><div class="info">
<code class="code">iter f ra</code> applies the unit-function <code class="code">f</code> to each element in
      resizable array <code class="code">ra</code>.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALmap"></a>map : <code class="type">(<a href="Nopres_intf.T.html#TYPEel">el</a> -> <a href="Nopres_intf.T.html#TYPEel">el</a>) -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">map f ra</code><br>
<b>Returns</b> a resizable array using the strategy of
      <code class="code">ra</code> and mapping each element in <code class="code">ra</code> to its corresponding position
      in the new array using function <code class="code">f</code>.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALiteri"></a>iteri : <code class="type">(int -> <a href="Nopres_intf.T.html#TYPEel">el</a> -> unit) -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> unit</code></pre><div class="info">
<code class="code">iteri f ra</code> applies the unit-function <code class="code">f</code> to each index and
      element in resizable array <code class="code">ra</code>.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALmapi"></a>mapi : <code class="type">(int -> <a href="Nopres_intf.T.html#TYPEel">el</a> -> <a href="Nopres_intf.T.html#TYPEel">el</a>) -><br>       <a href="Nopres_intf.T.html#TYPEt">t</a> -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">mapi f ra</code><br>
<b>Returns</b> a resizable array using the strategy of
      <code class="code">ra</code> and mapping each element in <code class="code">ra</code> to its corresponding
      position in the new array using function <code class="code">f</code> and the index
      position.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALfold_left"></a>fold_left : <code class="type">('a -> <a href="Nopres_intf.T.html#TYPEel">el</a> -> 'a) -> 'a -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> 'a</code></pre><div class="info">
<code class="code">fold_left f a ra</code> left-folds values in resizable array <code class="code">ra</code>
      using function <code class="code">f</code> and start accumulator <code class="code">a</code>.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALfold_right"></a>fold_right : <code class="type">(<a href="Nopres_intf.T.html#TYPEel">el</a> -> 'a -> 'a) -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> 'a -> 'a</code></pre><div class="info">
<code class="code">fold_right f a ra</code> right-folds values in resizable array <code class="code">ra</code>
      using function <code class="code">f</code> and start accumulator <code class="code">a</code>.<br>
</div>
<br>
<a name="6_Scanningofresizablearrays"></a>
<h6>Scanning of resizable arrays</h6><br>
<pre><span class="keyword">val</span> <a name="VALfor_all"></a>for_all : <code class="type">(<a href="Nopres_intf.T.html#TYPEel">el</a> -> bool) -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> bool</code></pre><div class="info">
<code class="code">for_all p ra</code><br>
<b>Returns</b> <code class="code">true</code> if all elements in resizable
      array <code class="code">ra</code> satisfy the predicate <code class="code">p</code>, <code class="code">false</code> otherwise.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALexists"></a>exists : <code class="type">(<a href="Nopres_intf.T.html#TYPEel">el</a> -> bool) -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> bool</code></pre><div class="info">
<code class="code">exists p ra</code><br>
<b>Returns</b> <code class="code">true</code> if at least one element in
      resizable array <code class="code">ra</code> satisfies the predicate <code class="code">p</code>, <code class="code">false</code>
      otherwise.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALmem"></a>mem : <code class="type"><a href="Nopres_intf.T.html#TYPEel">el</a> -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> bool</code></pre><div class="info">
<code class="code">mem el ra</code><br>
<b>Returns</b> <code class="code">true</code> if element <code class="code">el</code> is logically equal
      to any element in resizable array <code class="code">ra</code>, <code class="code">false</code> otherwise.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALmemq"></a>memq : <code class="type"><a href="Nopres_intf.T.html#TYPEel">el</a> -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> bool</code></pre><div class="info">
<code class="code">memq el ra</code><br>
<b>Returns</b> <code class="code">true</code> if element <code class="code">el</code> is physically equal
      to any element in resizable array <code class="code">ra</code>, <code class="code">false</code> otherwise.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALpos"></a>pos : <code class="type"><a href="Nopres_intf.T.html#TYPEel">el</a> -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> int option</code></pre><div class="info">
<code class="code">pos el ra</code><br>
<b>Returns</b> <code class="code">Some index</code> if <code class="code">el</code> is logically
      equal to the element at <code class="code">index</code> in <code class="code">ra</code>, <code class="code">None</code> otherwise.  <code class="code">index</code>
      is the index of the first element that matches.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALposq"></a>posq : <code class="type"><a href="Nopres_intf.T.html#TYPEel">el</a> -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> int option</code></pre><div class="info">
<code class="code">posq el ra</code><br>
<b>Returns</b> <code class="code">Some index</code> if <code class="code">el</code> is physically
      equal to the element at <code class="code">index</code> in <code class="code">ra</code>, <code class="code">None</code> otherwise.  <code class="code">index</code>
      is the index of the first element that matches.<br>
</div>
<br>
<a name="6_Searchingofresizablearrays"></a>
<h6>Searching of resizable arrays</h6><br>
<pre><span class="keyword">val</span> <a name="VALfind"></a>find : <code class="type">(<a href="Nopres_intf.T.html#TYPEel">el</a> -> bool) -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> <a href="Nopres_intf.T.html#TYPEel">el</a></code></pre><div class="info">
<code class="code">find p ra</code><br>
<b>Raises</b> <code>Not_found</code> if there is no such element.<br>
<b>Returns</b> the first element in resizable array <code class="code">ra</code>
      that satisfies predicate <code class="code">p</code>.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALfind_index"></a>find_index : <code class="type">(<a href="Nopres_intf.T.html#TYPEel">el</a> -> bool) -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> int</code></pre><div class="info">
<code class="code">find_index p ra pos</code><br>
<b>Raises</b><ul><li><code>Not_found</code> if there is no such element or if <code class="code">pos</code> is larger
      than the highest index.</li>
<li><code>Invalid_argument</code> if <code class="code">pos</code> is negative.</li>
</ul>
<b>Returns</b> the index of the first element
      that satisfies predicate <code class="code">p</code> in resizable array <code class="code">ra</code>, starting
      search at index <code class="code">pos</code>.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALfilter"></a>filter : <code class="type">(<a href="Nopres_intf.T.html#TYPEel">el</a> -> bool) -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">filter p ra</code><br>
<b>Returns</b> a new resizable array by filtering
      out all elements in <code class="code">ra</code> that satisfy predicate <code class="code">p</code> using the same
      strategy as <code class="code">ra</code>.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALfind_all"></a>find_all : <code class="type">(<a href="Nopres_intf.T.html#TYPEel">el</a> -> bool) -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">find_all p ra</code> is the same as <code class="code">filter</code><br>
</div>
<pre><span class="keyword">val</span> <a name="VALfilter_in_place"></a>filter_in_place : <code class="type">(<a href="Nopres_intf.T.html#TYPEel">el</a> -> bool) -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> unit</code></pre><div class="info">
<code class="code">filter_in_place p ra</code> as <code class="code">filter</code>, but filters in place.<br>
</div>
<pre><span class="keyword">val</span> <a name="VALpartition"></a>partition : <code class="type">(<a href="Nopres_intf.T.html#TYPEel">el</a> -> bool) -><br>       <a href="Nopres_intf.T.html#TYPEt">t</a> -> <a href="Nopres_intf.T.html#TYPEt">t</a> * <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><div class="info">
<code class="code">partition p ra</code><br>
<b>Returns</b> a pair of resizable arrays, the
      left part containing only elements of <code class="code">ra</code> that satisfy predicate
      <code class="code">p</code>, the right one only those that do not satisfy it. Both returned
      arrays are created using the strategy of <code class="code">ra</code>.<br>
</div>
<br>
<a name="6_UNSAFESTUFFUSEWITHCAUTION"></a>
<h6><b>UNSAFE STUFF - USE WITH CAUTION!</b></h6><br>
<pre><span class="keyword">val</span> <a name="VALunsafe_get"></a>unsafe_get : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> <a href="Nopres_intf.T.html#TYPEel">el</a></code></pre><pre><span class="keyword">val</span> <a name="VALunsafe_set"></a>unsafe_set : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> <a href="Nopres_intf.T.html#TYPEel">el</a> -> unit</code></pre><pre><span class="keyword">val</span> <a name="VALunsafe_sub"></a>unsafe_sub : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> int -> <a href="Nopres_intf.T.html#TYPEt">t</a></code></pre><pre><span class="keyword">val</span> <a name="VALunsafe_fill"></a>unsafe_fill : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> int -> <a href="Nopres_intf.T.html#TYPEel">el</a> -> unit</code></pre><pre><span class="keyword">val</span> <a name="VALunsafe_blit"></a>unsafe_blit : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> <a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> int -> unit</code></pre><pre><span class="keyword">val</span> <a name="VALunsafe_remove_one"></a>unsafe_remove_one : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> unit</code></pre><pre><span class="keyword">val</span> <a name="VALunsafe_remove_n"></a>unsafe_remove_n : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> unit</code></pre><pre><span class="keyword">val</span> <a name="VALunsafe_swap"></a>unsafe_swap : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> int -> unit</code></pre><pre><span class="keyword">val</span> <a name="VALunsafe_swap_in_last"></a>unsafe_swap_in_last : <code class="type"><a href="Nopres_intf.T.html#TYPEt">t</a> -> int -> unit</code></pre></body></html>