Fast SAT Solver (C++, GAlib)
Detail souboru
Zdrojový kód
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>Fast SAT Solver: SatItemVector Class Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.5.4 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main Page</span></a></li>
<li><a href="modules.html"><span>Modules</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Classes</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="annotated.html"><span>Class List</span></a></li>
<li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li>
<li><a href="functions.html"><span>Class Members</span></a></li>
</ul>
</div>
<div class="nav">
<a class="el" href="namespaceFastSatSolver.html">FastSatSolver</a>::<a class="el" href="classFastSatSolver_1_1SatItemVector.html">SatItemVector</a></div>
<h1>SatItemVector Class Reference<br>
<small>
[<a class="el" href="group__SatSolver.html">SAT Solver</a>]</small>
</h1><!-- doxytag: class="FastSatSolver::SatItemVector" --><code>#include <<a class="el" href="SatSolver_8h-source.html">SatSolver.h</a>></code>
<p>
<div class="dynheader">
Collaboration diagram for SatItemVector:</div>
<div class="dynsection">
<p><center><img src="classFastSatSolver_1_1SatItemVector__coll__graph.png" border="0" usemap="#SatItemVector__coll__map" alt="Collaboration graph"></center>
<map name="SatItemVector__coll__map">
<area shape="rect" href="structFastSatSolver_1_1SatItemVector_1_1Private.html" title="Private" alt="" coords="29,5,99,32"></map>
<center><font size="2">[<a href="graph_legend.html">legend</a>]</font></center></div>
<p>
<a href="classFastSatSolver_1_1SatItemVector-members.html">List of all members.</a><hr><a name="_details"></a><h2>Detailed Description</h2>
Linear storage container for <a class="el" href="classFastSatSolver_1_1ISatItem.html" title="Abstraction of solution candidate.">ISatItem</a> objects.
<p>
<dl class="attention" compact><dt><b>Attention:</b></dt><dd>On heap allocated objects are expected. They will be deleted by container's destructor. </dd></dl>
<p>Definition at line <a class="el" href="SatSolver_8h-source.html#l00240">240</a> of file <a class="el" href="SatSolver_8h-source.html">SatSolver.h</a>.</p>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classFastSatSolver_1_1SatItemVector.html#fab085d58e8b05bfcf4065c4d6af9c67">SatItemVector</a> ()</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classFastSatSolver_1_1SatItemVector.html#f93ae0bf30899a0e011bc2f373938de7">SatItemVector</a> (const <a class="el" href="classFastSatSolver_1_1SatItemVector.html">SatItemVector</a> &)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Deep copy. <a href="#f93ae0bf30899a0e011bc2f373938de7"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classFastSatSolver_1_1SatItemVector.html#6f497951e23c4434580791ec5096a271">~SatItemVector</a> ()</td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="classFastSatSolver_1_1SatItemVector.html#f59b115e86eaeac1f15673766852e428">getLength</a> () const </td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight"><dl class="return" compact><dt><b>Returns:</b></dt><dd>Returns count of item managed by container. </dd></dl>
<a href="#f59b115e86eaeac1f15673766852e428"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="classFastSatSolver_1_1ISatItem.html">ISatItem</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classFastSatSolver_1_1SatItemVector.html#e9908ff1674579e6a5ed8729dace445d">getItem</a> (int index) const </td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Direct access container item. <a href="#e9908ff1674579e6a5ed8729dace445d"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classFastSatSolver_1_1SatItemVector.html#e50e61bb65bb3328f6afbd8e005cb96f">addItem</a> (<a class="el" href="classFastSatSolver_1_1ISatItem.html">ISatItem</a> *item)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Add item to container. <a href="#e50e61bb65bb3328f6afbd8e005cb96f"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classFastSatSolver_1_1SatItemVector.html#c8bb3912a3ce86b15842e79d0b421204">clear</a> ()</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Remove all item from container and free from memory. <a href="#c8bb3912a3ce86b15842e79d0b421204"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="classFastSatSolver_1_1SatItemVector.html#3c0c3fdc04f467c4dcb62eabb407acc2">writeOut</a> (<a class="el" href="classFastSatSolver_1_1SatProblem.html">SatProblem</a> *, std::ostream &streamTo) const </td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Human readable container dump. <a href="#3c0c3fdc04f467c4dcb62eabb407acc2"></a><br></td></tr>
<tr><td colspan="2"><br><h2>Classes</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">struct </td><td class="memItemRight" valign="bottom"><a class="el" href="structFastSatSolver_1_1SatItemVector_1_1Private.html">Private</a></td></tr>
</table>
<hr><h2>Constructor & Destructor Documentation</h2>
<a class="anchor" name="fab085d58e8b05bfcf4065c4d6af9c67"></a><!-- doxytag: member="FastSatSolver::SatItemVector::SatItemVector" ref="fab085d58e8b05bfcf4065c4d6af9c67" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classFastSatSolver_1_1SatItemVector.html">SatItemVector</a> </td>
<td>(</td>
<td class="paramname"> </td>
<td> ) </td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
<p>Definition at line <a class="el" href="SatSolver_8cpp-source.html#l00158">158</a> of file <a class="el" href="SatSolver_8cpp-source.html">SatSolver.cpp</a>.</p>
</div>
</div><p>
<a class="anchor" name="f93ae0bf30899a0e011bc2f373938de7"></a><!-- doxytag: member="FastSatSolver::SatItemVector::SatItemVector" ref="f93ae0bf30899a0e011bc2f373938de7" args="(const SatItemVector &)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classFastSatSolver_1_1SatItemVector.html">SatItemVector</a> </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classFastSatSolver_1_1SatItemVector.html">SatItemVector</a> & </td>
<td class="paramname"> <em>other</em> </td>
<td> ) </td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Deep copy.
<p>
<p>Definition at line <a class="el" href="SatSolver_8cpp-source.html#l00162">162</a> of file <a class="el" href="SatSolver_8cpp-source.html">SatSolver.cpp</a>.</p>
<p>References <a class="el" href="classFastSatSolver_1_1ISatItem.html#ce35793be43d099862210ca953c725df">ISatItem::clone()</a>, <a class="el" href="SatSolver_8cpp-source.html#l00176">SatItemVector::getItem()</a>, <a class="el" href="SatSolver_8cpp-source.html#l00173">SatItemVector::getLength()</a>, and <a class="el" href="SatSolver_8cpp-source.html#l00154">SatItemVector::Private::vect</a>.</p>
</div>
</div><p>
<a class="anchor" name="6f497951e23c4434580791ec5096a271"></a><!-- doxytag: member="FastSatSolver::SatItemVector::~SatItemVector" ref="6f497951e23c4434580791ec5096a271" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">~<a class="el" href="classFastSatSolver_1_1SatItemVector.html">SatItemVector</a> </td>
<td>(</td>
<td class="paramname"> </td>
<td> ) </td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
<p>Definition at line <a class="el" href="SatSolver_8cpp-source.html#l00169">169</a> of file <a class="el" href="SatSolver_8cpp-source.html">SatSolver.cpp</a>.</p>
<p>References <a class="el" href="SatSolver_8cpp-source.html#l00197">SatItemVector::clear()</a>.</p>
</div>
</div><p>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="f59b115e86eaeac1f15673766852e428"></a><!-- doxytag: member="FastSatSolver::SatItemVector::getLength" ref="f59b115e86eaeac1f15673766852e428" args="() const " -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">int getLength </td>
<td>(</td>
<td class="paramname"> </td>
<td> ) </td>
<td width="100%"> const</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>Returns count of item managed by container. </dd></dl>
<p>
<p>Definition at line <a class="el" href="SatSolver_8cpp-source.html#l00173">173</a> of file <a class="el" href="SatSolver_8cpp-source.html">SatSolver.cpp</a>.</p>
<p>References <a class="el" href="SatSolver_8cpp-source.html#l00154">SatItemVector::Private::vect</a>.</p>
<p>Referenced by <a class="el" href="BlindSatSolver_8cpp-source.html#l00087">BlindSatSolver::getSolutionsCount()</a>, <a class="el" href="fss_8cpp-source.html#l00046">main()</a>, <a class="el" href="SatSolver_8cpp-source.html#l00226">SatItemSet::Private::SatItemHashDecorator::operator<()</a>, <a class="el" href="SatSolver_8cpp-source.html#l00162">SatItemVector::SatItemVector()</a>, and <a class="el" href="SatSolver_8cpp-source.html#l00182">SatItemVector::writeOut()</a>.</p>
</div>
</div><p>
<a class="anchor" name="e9908ff1674579e6a5ed8729dace445d"></a><!-- doxytag: member="FastSatSolver::SatItemVector::getItem" ref="e9908ff1674579e6a5ed8729dace445d" args="(int index) const " -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classFastSatSolver_1_1ISatItem.html">ISatItem</a> * getItem </td>
<td>(</td>
<td class="paramtype">int </td>
<td class="paramname"> <em>index</em> </td>
<td> ) </td>
<td width="100%"> const</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Direct access container item.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>index</em> </td><td>Index should be in range <0, <a class="el" href="classFastSatSolver_1_1SatItemVector.html#f59b115e86eaeac1f15673766852e428" title="Returns count of item managed by container.">getLength()</a>-1>. </td></tr>
</table>
</dl>
<dl class="return" compact><dt><b>Returns:</b></dt><dd>Returns pointer to desired item. </dd></dl>
<p>Definition at line <a class="el" href="SatSolver_8cpp-source.html#l00176">176</a> of file <a class="el" href="SatSolver_8cpp-source.html">SatSolver.cpp</a>.</p>
<p>References <a class="el" href="SatSolver_8cpp-source.html#l00154">SatItemVector::Private::vect</a>.</p>
<p>Referenced by <a class="el" href="SatSolver_8cpp-source.html#l00162">SatItemVector::SatItemVector()</a>, and <a class="el" href="SatSolver_8cpp-source.html#l00182">SatItemVector::writeOut()</a>.</p>
</div>
</div><p>
<a class="anchor" name="e50e61bb65bb3328f6afbd8e005cb96f"></a><!-- doxytag: member="FastSatSolver::SatItemVector::addItem" ref="e50e61bb65bb3328f6afbd8e005cb96f" args="(ISatItem *item)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void addItem </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classFastSatSolver_1_1ISatItem.html">ISatItem</a> * </td>
<td class="paramname"> <em>item</em> </td>
<td> ) </td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Add item to container.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>item</em> </td><td>Item to add to container. </td></tr>
</table>
</dl>
<dl class="attention" compact><dt><b>Attention:</b></dt><dd>On heap allocated objects is expected. It will be deleted by container's destructor. </dd></dl>
<p>Definition at line <a class="el" href="SatSolver_8cpp-source.html#l00179">179</a> of file <a class="el" href="SatSolver_8cpp-source.html">SatSolver.cpp</a>.</p>
<p>References <a class="el" href="SatSolver_8cpp-source.html#l00154">SatItemVector::Private::vect</a>.</p>
<p>Referenced by <a class="el" href="SatSolver_8cpp-source.html#l00263">SatItemSet::createVector()</a>, and <a class="el" href="BlindSatSolver_8cpp-source.html#l00108">BlindSatSolver::doStep()</a>.</p>
</div>
</div><p>
<a class="anchor" name="c8bb3912a3ce86b15842e79d0b421204"></a><!-- doxytag: member="FastSatSolver::SatItemVector::clear" ref="c8bb3912a3ce86b15842e79d0b421204" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void clear </td>
<td>(</td>
<td class="paramname"> </td>
<td> ) </td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Remove all item from container and free from memory.
<p>
<p>Definition at line <a class="el" href="SatSolver_8cpp-source.html#l00197">197</a> of file <a class="el" href="SatSolver_8cpp-source.html">SatSolver.cpp</a>.</p>
<p>References <a class="el" href="SatSolver_8cpp-source.html#l00154">SatItemVector::Private::vect</a>.</p>
<p>Referenced by <a class="el" href="BlindSatSolver_8cpp-source.html#l00103">BlindSatSolver::initialize()</a>, and <a class="el" href="SatSolver_8cpp-source.html#l00169">SatItemVector::~SatItemVector()</a>.</p>
</div>
</div><p>
<a class="anchor" name="3c0c3fdc04f467c4dcb62eabb407acc2"></a><!-- doxytag: member="FastSatSolver::SatItemVector::writeOut" ref="3c0c3fdc04f467c4dcb62eabb407acc2" args="(SatProblem *, std::ostream &streamTo) const " -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void writeOut </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classFastSatSolver_1_1SatProblem.html">SatProblem</a> * </td>
<td class="paramname"> <em>problem</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">std::ostream & </td>
<td class="paramname"> <em>streamTo</em></td><td> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"> const</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Human readable container dump.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>problem</em> </td><td>Pointer to <a class="el" href="classFastSatSolver_1_1SatProblem.html" title="SAT Problem module's facade.">SatProblem</a> instance, which knows variable names. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>streamTo</em> </td><td>Standard output stream, which is used for output. </td></tr>
</table>
</dl>
<p>Definition at line <a class="el" href="SatSolver_8cpp-source.html#l00182">182</a> of file <a class="el" href="SatSolver_8cpp-source.html">SatSolver.cpp</a>.</p>
<p>References <a class="el" href="classFastSatSolver_1_1ISatItem.html#ef9eadbc8fd10e01f1b37f85c6e08a67">ISatItem::getBit()</a>, <a class="el" href="SatSolver_8cpp-source.html#l00176">SatItemVector::getItem()</a>, <a class="el" href="SatSolver_8cpp-source.html#l00173">SatItemVector::getLength()</a>, <a class="el" href="SatProblem_8cpp-source.html#l00174">SatProblem::getVarName()</a>, and <a class="el" href="SatProblem_8cpp-source.html#l00165">SatProblem::getVarsCount()</a>.</p>
<p>Referenced by <a class="el" href="fss_8cpp-source.html#l00046">main()</a>.</p>
</div>
</div><p>
<hr>The documentation for this class was generated from the following files:<ul>
<li><a class="el" href="SatSolver_8h-source.html">SatSolver.h</a><li><a class="el" href="SatSolver_8cpp-source.html">SatSolver.cpp</a></ul>
<hr size="1"><address style="text-align: right;"><small>Generated on Wed Nov 5 22:30:22 2008 for Fast SAT Solver by
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.4 </small></address>
</body>
</html>