Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: downloads/boost_1_34_1/doc/html/boost/logic/tribool.html @ 29

Last change on this file since 29 was 29, checked in by landauf, 16 years ago

updated boost from 1_33_1 to 1_34_1

File size: 5.9 KB
Line 
1<html>
2<head>
3<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
4<title>Class tribool</title>
5<link rel="stylesheet" href="../../boostbook.css" type="text/css">
6<meta name="generator" content="DocBook XSL Stylesheets V1.68.1">
7<link rel="start" href="../../index.html" title="The Boost C++ Libraries BoostBook Documentation Subset">
8<link rel="up" href="../../tribool/reference.html#header.boost.logic.tribool.hpp" title="Header &lt;boost/logic/tribool.hpp&gt;">
9<link rel="prev" href="../../tribool/reference.html" title="Reference">
10<link rel="next" href="indeterminate.html" title="Function indeterminate">
11</head>
12<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
13<table cellpadding="2" width="100%">
14<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../boost.png"></td>
15<td align="center"><a href="../../../../index.htm">Home</a></td>
16<td align="center"><a href="../../../../libs/libraries.htm">Libraries</a></td>
17<td align="center"><a href="../../../../people/people.htm">People</a></td>
18<td align="center"><a href="../../../../more/faq.htm">FAQ</a></td>
19<td align="center"><a href="../../../../more/index.htm">More</a></td>
20</table>
21<hr>
22<div class="spirit-nav">
23<a accesskey="p" href="../../tribool/reference.html"><img src="../../images/prev.png" alt="Prev"></a><a accesskey="u" href="../../tribool/reference.html#header.boost.logic.tribool.hpp"><img src="../../images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../images/home.png" alt="Home"></a><a accesskey="n" href="indeterminate.html"><img src="../../images/next.png" alt="Next"></a>
24</div>
25<div class="refentry" lang="en">
26<a name="boost.logic.tribool"></a><div class="titlepage"></div>
27<div class="refnamediv">
28<h2><span class="refentrytitle">Class tribool</span></h2>
29<p>boost::logic::tribool &#8212; A 3-state boolean type. </p>
30</div>
31<h2 xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="refsynopsisdiv-title">Synopsis</h2>
32<div xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="refsynopsisdiv"><pre class="synopsis">
33<span class="bold"><strong>class</strong></span> tribool {
34<span class="bold"><strong>public</strong></span>:
35  <span class="emphasis"><em>// <a href="tribool.html#boost.logic.triboolconstruct-copy-destruct">construct/copy/destruct</a></em></span>
36  <a href="tribool.html#id1249568-bb">tribool</a>();
37  <a href="tribool.html#id1249578-bb">tribool</a>(<span class="bold"><strong>bool</strong></span>);
38  <a href="tribool.html#id1249601-bb">tribool</a>(indeterminate_keyword_t);
39
40  <span class="emphasis"><em>// <a href="tribool.html#id1040490-bb">public member functions</a></em></span>
41  <a href="tribool.html#id1249546-bb"><span class="bold"><strong>operator</strong></span> safe_bool</a>() <span class="bold"><strong>const</strong></span>;
42
43  enum boost::logic::tribool::value_t value;
44};</pre></div>
45<div class="refsect1" lang="en">
46<a name="id1835925"></a><h2>Description</h2>
47<p>3-state boolean values are either true, false, or indeterminate. </p>
48<div class="refsect2" lang="en">
49<a name="id1835932"></a><h3>
50<a name="boost.logic.triboolconstruct-copy-destruct"></a><code class="computeroutput">tribool</code> construct/copy/destruct</h3>
51<div class="orderedlist"><ol type="1">
52<li>
53<pre class="literallayout"><a name="id1249568-bb"></a>tribool();</pre>
54<p>Construct a new 3-state boolean value with the value 'false'.</p>
55<p>
56</p>
57<div class="variablelist"><table border="0">
58<col align="left" valign="top">
59<tbody><tr>
60<td>
61<span class="term">Throws:</span></td>
62<td>Will not throw.</td>
63</tr></tbody>
64</table></div>
65</li>
66<li>
67<pre class="literallayout"><a name="id1249578-bb"></a>tribool(<span class="bold"><strong>bool</strong></span> value);</pre>
68<p>Construct a new 3-state boolean value with the given boolean value, which may be <code class="computeroutput">true</code>  or <code class="computeroutput">false</code> .</p>
69<p>
70</p>
71<div class="variablelist"><table border="0">
72<col align="left" valign="top">
73<tbody><tr>
74<td>
75<span class="term">Throws:</span></td>
76<td>Will not throw.</td>
77</tr></tbody>
78</table></div>
79</li>
80<li>
81<pre class="literallayout"><a name="id1249601-bb"></a>tribool(indeterminate_keyword_t);</pre>
82<p>Construct a new 3-state boolean value with an indeterminate value.</p>
83<p>
84</p>
85<div class="variablelist"><table border="0">
86<col align="left" valign="top">
87<tbody><tr>
88<td>
89<span class="term">Throws:</span></td>
90<td>Will not throw.</td>
91</tr></tbody>
92</table></div>
93</li>
94</ol></div>
95</div>
96<div class="refsect2" lang="en">
97<a name="id1836063"></a><h3>
98<a name="id1040490-bb"></a><code class="computeroutput">tribool</code> public member functions</h3>
99<div class="orderedlist"><ol type="1"><li>
100<pre class="literallayout"><a name="id1249546-bb"></a><span class="bold"><strong>operator</strong></span> safe_bool() <span class="bold"><strong>const</strong></span>;</pre>
101<p>Use a 3-state boolean in a boolean context. Will evaluate true in a boolean context only when the 3-state boolean is definitely true.</p>
102<p>
103
104</p>
105<div class="variablelist"><table border="0">
106<col align="left" valign="top">
107<tbody>
108<tr>
109<td>
110<span class="term">Returns:</span></td>
111<td><p>true if the 3-state boolean is true, false otherwise </p></td>
112</tr>
113<tr>
114<td>
115<span class="term">Throws:</span></td>
116<td>Will not throw.</td>
117</tr>
118</tbody>
119</table></div>
120</li></ol></div>
121</div>
122</div>
123</div>
124<table width="100%"><tr>
125<td align="left"></td>
126<td align="right"><small>Copyright © 2002-2004 Douglas Gregor</small></td>
127</tr></table>
128<hr>
129<div class="spirit-nav">
130<a accesskey="p" href="../../tribool/reference.html"><img src="../../images/prev.png" alt="Prev"></a><a accesskey="u" href="../../tribool/reference.html#header.boost.logic.tribool.hpp"><img src="../../images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../images/home.png" alt="Home"></a><a accesskey="n" href="indeterminate.html"><img src="../../images/next.png" alt="Next"></a>
131</div>
132</body>
133</html>
Note: See TracBrowser for help on using the repository browser.