<section id="r_fs">
<title/The class <<OZ_FSetValue>>/

<!-- ********************************************************************** -->

<subsection id="r_fs.misc">
<title/Miscellaneous/
<p>

<List proglang=cc>

<Entry class="enumtype"><<OZ_FSetState>>
<Index class=proglang><<OZ_FSetState>></Index>
<Synopsis><<enum OZ_FSetState {fs_empty, fs_full};>> 

<Item> Used when constructing a Finite Set or with the operator
<<==>>.

<p>
<table>
<tr> <th/value/ <th/meaning/
<tr> <td/<<fs_empty>>/ 
     <td/the empty set/
<tr> <td/<<fs_full>>/ 
     <td/the set <math>\{\mbox{\tt OZ\_getFSInf()}, \ldots, \mbox{\tt OZ\_getFSSup()}\}</math>/
</table>
 
</List>

<!-- ********************************************************************** -->

<subsection id="r_fs.constr">
<title/Constructor Member Functions/
<p>

<List proglang=cc>

<Entry class="default constructor"><<OZ_FSetValue>>
<Index class=proglang><<OZ_FSetValue>></Index>
<Synopsis><<OZ_FSetValue(void);>> 

<Item> This constructor creates an <em/uninitialised/ Finite Set Value.


<Entry class="overloaded constructor"><<OZ_FSetValue>>
<Index class=proglang><<OZ_FSetValue>></Index>
<Synopsis><<OZ_FSetValue(const OZ_FSetConstraint &amp;fsc);>>

<Item> <<fsc>> must have a determined value (&ie <<fsc.isValue()>>
must be true). A Finite Set is constructed from this value.


<Entry class="overloaded constructor"><<OZ_FSetValue>>
<Index class=proglang><<OZ_FSetValue>></Index>
<Synopsis><<OZ_FSetValue(const OZ_Term t);>>

<Item>  Constructor using a <em/level4/ list description like for
Finite Domains (see <ptr to="expect.checkconstr">) to create a Finite
Set Value.


<Entry class="overloaded constructor"><<OZ_FSetValue>>
<Index class=proglang><<OZ_FSetValue>></Index>
<Synopsis><<OZ_FSetValue(const OZ_FSetState state);>>

<Item> Creates a Finite Set Value according to <<state>> (<<fs_empty>>
or <<fs_full>>).


<Entry class="overloaded constructor"><<OZ_FSetValue>>
<Index class=proglang><<OZ_FSetValue>></Index>
<Synopsis><<OZ_FSetValue(int min_elem, int max_elem);>>

<Item> Creates a Finite Set Value <math/\{min\_elem, \ldots, max\_elem\}/. 


<!--
<<
OZ_FSetValue(const OZ_FiniteDomain &amp;fd);
>>
<p>
Creates a Finite Set containing the possible values for <<fd>>.
<p>
-->

</List>

<!-- ********************************************************************** -->

<subsection id="r_fs.refl">
<title/Reflection Member Functions/
<p>

<List proglang=cc>

<Entry class="constant member function"><<getMinElem>>
<Index class=proglang><<OZ_FSetValue>><And><<getMinElem>></Index>
<Synopsis><<int getMinElem(void) const;>>

<Item> Returns the smallest element of the set.

<Entry class="constant member function"><<getMaxElem>>
<Index class=proglang><<OZ_FSetValue>><And><<getMaxElem>></Index>
<Synopsis><<int getMaxElem(void) const;>>

<Item> Returns the largest element of the set.


<Entry class="constant member function"><<getNextLargerElem>>
<Index class=proglang><<OZ_FSetValue>><And><<getNextLargerElem>></Index>
<Synopsis><<int getNextLargerElem(int i) const;>>

<Item> Returns the next larger Element after i in the set, or
<math/-1/ if there is none.


<Entry class="constant member function"><<getNextSmallerElem>>
<Index class=proglang><<OZ_FSetValue>><And><<getNextSmallerElem>></Index>
<Synopsis><<int getNextSmallerElem(int i) const;>>

<Item> Returns the next smaller Element before i in the set, or
<math/-1/ if there is none.


<Entry class="constant member function"><<getKnownInList>>
<Index class=proglang><<OZ_FSetValue>><And><<getKnownInList>></Index>
<Synopsis><<OZ_Term getKnownInList(void) const;>>

<Item> Returns a <em/level4/-List (see <ptr to="expect.checkconstr">)
containing the elements in the set.


<Entry class="constant member function"><<getKnownNotInList>>
<Index class=proglang><<OZ_FSetValue>><And><<getKnownNotInList>></Index>
<Synopsis><<OZ_Term getKnownNotInList(void) const;>>

<Item> Returns a <em/level4/-List (see <ptr to="expect.checkconstr">)
containing the elements in the complementary set.

</List>

<!-- ********************************************************************** -->

<subsection id="r_fs.op">
<title/Operator Member Functions/
<p>

<List proglang=cc>

<Entry class="constant operator member function"><<operator ==>>
<Index class=proglang><<OZ_FSetValue>><And><<operator ==>></Index>
<Synopsis><<OZ_Boolean operator == (const OZ_FSetValue &amp;fs) const;>>

<Item> Tests equality on sets.


<Entry class="constant operator member function"><<operator &lt;=>>
<Index class=proglang><<OZ_FSetValue>><And><<operator &lt;=>></Index>
<Synopsis><<OZ_Boolean operator &lt;= (const OZ_FSetValue &amp;fs) const;>>

<Item> Return <<OZ_True>> if <<*this>> is a subset of <<fs>>.

<Entry class="constant operator member function"><<operator &amp;>>
<Index class=proglang><<OZ_FSetValue>><And><<operator &amp;>></Index>
<Synopsis><<OZ_FSetValue operator &amp; (const OZ_FSetValue &amp;fs) const;>>

<Item> Returns the intersection of <<*this>> with <<fs>>.


<Entry class="constant operator member function"><<operator |>>
<Index class=proglang><<OZ_FSetValue>><And><<operator |>></Index>
<Synopsis><<OZ_FSetValue operator | (const OZ_FSetValue &amp;fs) const;>>

<Item> Returns the union of <<*this>> with <<fs>>.

<Entry class="constant operator member function"><<operator ->>
<Index class=proglang><<OZ_FSetValue>><And><<operator ->></Index>
<Synopsis><<OZ_FSetValue operator - (const OZ_FSetValue &amp;fs) const;>>

<Item> Returns the elements in <<*this>> not in <<fs>>.


<Entry class="operator member function"><<operator &amp;=>>
<Index class=proglang><<OZ_FSetValue>><And><<operator &amp;=>></Index>
<Synopsis><<OZ_FSetValue operator &amp;= (const OZ_FSetValue &amp;fs);>>

<Item> <<*this>> is assigned its intersection with <<fs>>.


<Entry class="operator member function"><<operator |=>>
<Index class=proglang><<OZ_FSetValue>><And><<operator |=>></Index>
<Synopsis><<OZ_FSetValue operator |= (const OZ_FSetValue &amp;);>>

<Item> <<*this>> is assigned its union with <<fs>>.


<Entry class="operator member function"><<operator &amp;=>>
<Index class=proglang><<OZ_FSetValue>><And><<operator &amp;=>></Index>
<Synopsis><<OZ_FSetValue operator &amp;= (const int i);>>

<Item> If <<i>> is in <<*this>>, this function returns <math/\{i\}/;
otherwise the empty set.


<Entry class="operator member function"><<operator +=>>
<Index class=proglang><<OZ_FSetValue>><And><<operator +=>></Index>
<Synopsis><<OZ_FSetValue operator += (const int i);>>

<Item><<i>> is put into <<*this>>.


<Entry class="operator member function"><<operator -=>>
<Index class=proglang><<OZ_FSetValue>><And><<operator -=>></Index>
<Synopsis><<OZ_FSetValue operator-=(const int);>>

<Item> <<i>> is removed from <<*this>>, if in.


<Entry class="constant operator member function"><<operator ->>
<Index class=proglang><<OZ_FSetValue>><And><<operator ->></Index>
<Synopsis><<OZ_FSetValue operator-(void) const;>>

<Item> Returns the complement of <<*this>>.

</List>

<!-- ********************************************************************** -->

<subsection id="r_fs.aux">
<title/Auxiliary Member Functions/
<p>

<List proglang=cc>

<Entry class="member function"><<init>>
<Index class=proglang><<OZ_FSetValue>>and<<init>></Index>
<Synopsis><<void init(const OZ_FSetState state);>>

<Item> Initializes a Finite Set Value according to <<state>> (<<fs_empty>>
or <<fs_full>>).


<Entry class="constant member function"><<isIn>>
<Index class=proglang><<OZ_FSetValue>><And><<isIn>></Index>
<Synopsis><<OZ_Boolean isIn(int i) const;>>

<Item> Returns <<OZ_True>> if <<i>> is in <<*this>>.


<Entry class="constant member function"><<isNotIn>>
<Index class=proglang><<OZ_FSetValue>><And><<isNotIn>></Index>
<Synopsis><<OZ_Boolean isNotIn(int) const;>>

<Item> Returns <<OZ_True>> if <<i>> is not in <<*this>>.


<Entry class="constant member function"><<getCard>>
<Index class=proglang><<OZ_FSetValue>><And><<getCard>></Index>
<Synopsis><<int getCard(void) const;>>

<Item> Returns the cardinality of <<*this>>.


<Entry class="constant member function"><<getKnownNotIn>>
<Index class=proglang><<OZ_FSetValue>><And><<getKnownNotIn>></Index>
<Synopsis><<int getKnownNotIn(void) const;>>

<Item> Returns the cardinality of <<*this>>' complement.

<Entry class="member function"><<copyExtension>>
<Index class=proglang><<OZ_FSetValue>><And><<copyExtension>></Index>
<Synopsis> <<void copyExtension(void);>>

<Item> This member function replaces the current extension of the
set value representation by a copy of it.


<Entry class="member function"><<disposeExtension>>
<Index class=proglang><<OZ_FSetValue>><And><<disposeExtension>></Index>
<Synopsis> <<void disposeExtension(void);>>

<Item> This member function frees the heap memory occupied by the
extension of the set value.

<Entry class="constant member function"><<toString>>
<Index class=proglang><<OZ_FSetValue>><And><<toString>></Index>
<Synopsis><<char * toString(void) const;>>

<Item> Returns a textual representation of the finite set value pointing
to a static array of <<char>>s.

</List>

<!--
<para class=apropos><title/<<new>>/
<em/member function/
<p>
<<
static void * operator new(size_t);
>>
<p>

<p>

<para class=apropos><title/<<delete>>/
<em/member function/
<p>
<<
static void operator delete(void *, size_t);
>>
<p>

<p>


-->
