Sophie

Sophie

distrib > Mandriva > 9.1 > ppc > media > contrib > by-pkgid > 263386785cefb9ae5d63b926d214d809 > files > 762

mpqc-2.1.2-4mdk.ppc.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html><head><meta name="robots" content="noindex">
<meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
<title>sc::StateOut class Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
</head><body bgcolor="#ffffff">
<!-- Generated by Doxygen 1.2.5 on Mon Oct 14 14:17:53 2002 -->
<center>
<a class="qindex" href="index.html">Main Page</a> &nbsp; <a class="qindex" href="hierarchy.html">Class Hierarchy</a> &nbsp; <a class="qindex" href="annotated.html">Compound List</a> &nbsp; <a class="qindex" href="files.html">File List</a> &nbsp; <a class="qindex" href="functions.html">Compound Members</a> &nbsp; <a class="qindex" href="pages.html">Related Pages</a> &nbsp; </center>
<hr><h1>sc::StateOut  Class Reference</h1>Serializes objects that derive from <a class="el" href="class_sc__SavableState.html">SavableState</a>. 
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="stateout_h-source.html">stateout.h</a>&gt;</code>
<p>
Inheritance diagram for sc::StateOut<p><center><img src="class_sc__StateOut_inherit_graph.gif" border="0" usemap="#sc::StateOut_inherit_map" alt="Inheritance graph"></center>
<map name="sc::StateOut_inherit_map">
<area href="class_sc__MsgStateSend.html" shape="rect" coords="141,280,250,299">
<area href="class_sc__StateOutFile.html" shape="rect" coords="379,280,478,299">
<area href="class_sc__DescribedClass.html" shape="rect" coords="443,147,558,165">
<area href="class_sc__RefCount.html" shape="rect" coords="459,80,542,99">
<area href="class_sc__Identity.html" shape="rect" coords="465,13,537,32">
<area href="class_sc__BcastStateSend.html" shape="rect" coords="14,347,129,365">
<area href="class_sc__StateSend.html" shape="rect" coords="153,347,238,365">
<area href="class_sc__StateOutBin.html" shape="rect" coords="262,347,358,365">
<area href="class_sc__StateOutText.html" shape="rect" coords="382,347,483,365">
</map>
<center><font size="2">[<a href="graph_legend.html">legend</a>]</font></center>Collaboration diagram for sc::StateOut:<p><center><img src="class_sc__StateOut_coll_graph.gif" border="0" usemap="#sc::StateOut_coll_map" alt="Collaboration graph"></center>
<map name="sc::StateOut_coll_map">
<area href="class_sc__TranslateDataOut.html" shape="rect" coords="193,345,318,363">
<area href="class_sc__DescribedClass.html" shape="rect" coords="14,179,129,198">
<area href="class_sc__RefCount.html" shape="rect" coords="30,97,113,115">
<area href="class_sc__Identity.html" shape="rect" coords="35,14,107,33">
<area href="class_sc__TranslateData.html" shape="rect" coords="89,262,195,281">
</map>
<center><font size="2">[<a href="graph_legend.html">legend</a>]</font></center><a href="class_sc__StateOut-members.html">List of all members.</a><table border=0 cellpadding=0 cellspacing=0>
<tr><td colspan=2><br><h2>Public Methods</h2></td></tr>
<tr><td nowrap align=right valign=top><a name="a0" doxytag="sc::StateOut::StateOut"></a>
&nbsp;</td><td valign=bottom><b>StateOut</b> ()</td></tr>
<tr><td nowrap align=right valign=top><a name="a1" doxytag="sc::StateOut::~StateOut"></a>
virtual&nbsp;</td><td valign=bottom><b>~StateOut</b> ()</td></tr>
<tr><td nowrap align=right valign=top><a name="a2" doxytag="sc::StateOut::put_header"></a>
virtual void&nbsp;</td><td valign=bottom><a class="el" href="class_sc__StateOut.html#a2">put_header</a> ()</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Write out header information.</em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top><a name="a3" doxytag="sc::StateOut::putstring"></a>
virtual int&nbsp;</td><td valign=bottom><a class="el" href="class_sc__StateOut.html#a3">putstring</a> (const char *)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>This is like put except the length of the char array is determined by interpreting the character array as a character string.</em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top><a name="a4" doxytag="sc::StateOut::put"></a>
virtual int&nbsp;</td><td valign=bottom><a class="el" href="class_sc__StateOut.html#a4">put</a> (char r)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Write the given datum.</em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top><a name="a5" doxytag="sc::StateOut::put"></a>
virtual int&nbsp;</td><td valign=bottom><b>put</b> (unsigned int r)</td></tr>
<tr><td nowrap align=right valign=top><a name="a6" doxytag="sc::StateOut::put"></a>
virtual int&nbsp;</td><td valign=bottom><b>put</b> (int r)</td></tr>
<tr><td nowrap align=right valign=top><a name="a7" doxytag="sc::StateOut::put"></a>
virtual int&nbsp;</td><td valign=bottom><b>put</b> (float r)</td></tr>
<tr><td nowrap align=right valign=top><a name="a8" doxytag="sc::StateOut::put"></a>
virtual int&nbsp;</td><td valign=bottom><b>put</b> (double r)</td></tr>
<tr><td nowrap align=right valign=top>virtual int&nbsp;</td><td valign=bottom><a class="el" href="class_sc__StateOut.html#a9">put</a> (const char *,int)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Write the given array data.</em> <a href="#a9">More...</a><em></em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top><a name="a10" doxytag="sc::StateOut::put"></a>
virtual int&nbsp;</td><td valign=bottom><b>put</b> (const unsigned int *,int)</td></tr>
<tr><td nowrap align=right valign=top><a name="a11" doxytag="sc::StateOut::put"></a>
virtual int&nbsp;</td><td valign=bottom><b>put</b> (const int *,int)</td></tr>
<tr><td nowrap align=right valign=top><a name="a12" doxytag="sc::StateOut::put"></a>
virtual int&nbsp;</td><td valign=bottom><b>put</b> (const float *,int)</td></tr>
<tr><td nowrap align=right valign=top><a name="a13" doxytag="sc::StateOut::put"></a>
virtual int&nbsp;</td><td valign=bottom><b>put</b> (const double *,int)</td></tr>
<tr><td nowrap align=right valign=top>virtual int&nbsp;</td><td valign=bottom><a class="el" href="class_sc__StateOut.html#a14">put_array_char</a> (const char *p, int size)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Put arrays of data.</em> <a href="#a14">More...</a><em></em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top><a name="a15" doxytag="sc::StateOut::put_array_uint"></a>
virtual int&nbsp;</td><td valign=bottom><b>put_array_uint</b> (const unsigned int *p, int size)</td></tr>
<tr><td nowrap align=right valign=top><a name="a16" doxytag="sc::StateOut::put_array_int"></a>
virtual int&nbsp;</td><td valign=bottom><b>put_array_int</b> (const int *p, int size)</td></tr>
<tr><td nowrap align=right valign=top><a name="a17" doxytag="sc::StateOut::put_array_float"></a>
virtual int&nbsp;</td><td valign=bottom><b>put_array_float</b> (const float *p, int size)</td></tr>
<tr><td nowrap align=right valign=top><a name="a18" doxytag="sc::StateOut::put_array_double"></a>
virtual int&nbsp;</td><td valign=bottom><b>put_array_double</b> (const double *p, int size)</td></tr>
<tr><td nowrap align=right valign=top>void&nbsp;</td><td valign=bottom><a class="el" href="class_sc__StateOut.html#a19">forget_references</a> ()</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Don't keep track of pointers to objects.</em> <a href="#a19">More...</a><em></em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top>void&nbsp;</td><td valign=bottom><a class="el" href="class_sc__StateOut.html#a20">copy_references</a> ()</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>If a reference to an object that has already been written is encountered, copy it instead of generating a reference to the first object.</em> <a href="#a20">More...</a><em></em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top><a name="a21" doxytag="sc::StateOut::use_directory"></a>
virtual int&nbsp;</td><td valign=bottom><a class="el" href="class_sc__StateOut.html#a21">use_directory</a> ()</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Returns true if this object uses a directory.</em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top><a name="a22" doxytag="sc::StateOut::flush"></a>
virtual void&nbsp;</td><td valign=bottom><a class="el" href="class_sc__StateOut.html#a22">flush</a> ()</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Flush out any remaining data.</em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top>int&nbsp;</td><td valign=bottom><a class="el" href="class_sc__StateOut.html#a23">node_to_node</a> () const</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>True if this is a node to node save/restore.</em> <a href="#a23">More...</a><em></em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top>virtual int&nbsp;</td><td valign=bottom><a class="el" href="class_sc__StateOut.html#a24">tell</a> ()</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Returns the current position in the file.</em> <a href="#a24">More...</a><em></em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top>virtual void&nbsp;</td><td valign=bottom><a class="el" href="class_sc__StateOut.html#a25">seek</a> (int loc)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Set the current position in the file.</em> <a href="#a25">More...</a><em></em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top>virtual int&nbsp;</td><td valign=bottom><a class="el" href="class_sc__StateOut.html#a26">seekable</a> ()</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Return non-zero if tell and seek do anything sensible.</em> <a href="#a26">More...</a><em></em></font><br><br></td></tr>
<tr><td colspan=2><br><h2>Protected Methods</h2></td></tr>
<tr><td nowrap align=right valign=top><a name="b0" doxytag="sc::StateOut::put_array_void"></a>
virtual int&nbsp;</td><td valign=bottom><b>put_array_void</b> (const void *,int)</td></tr>
<tr><td nowrap align=right valign=top><a name="b1" doxytag="sc::StateOut::putparents"></a>
virtual int&nbsp;</td><td valign=bottom><b>putparents</b> (const <a class="el" href="class_sc__ClassDesc.html">ClassDesc</a> *)</td></tr>
<tr><td nowrap align=right valign=top><a name="b2" doxytag="sc::StateOut::put_directory"></a>
void&nbsp;</td><td valign=bottom><b>put_directory</b> ()</td></tr>
<tr><td nowrap align=right valign=top><a name="b3" doxytag="sc::StateOut::have_classdesc"></a>
void&nbsp;</td><td valign=bottom><b>have_classdesc</b> ()</td></tr>
<tr><td nowrap align=right valign=top><a name="b4" doxytag="sc::StateOut::need_classdesc"></a>
int&nbsp;</td><td valign=bottom><b>need_classdesc</b> ()</td></tr>
<tr><td nowrap align=right valign=top>virtual int&nbsp;</td><td valign=bottom><a class="el" href="class_sc__StateOut.html#b5">putobject</a> (const <a class="el" href="class_sc__Ref.html">Ref</a>&lt; <a class="el" href="class_sc__SavableState.html">SavableState</a> &gt; &amp;)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>This will prepare <a class="el" href="class_sc__StateOut.html">StateOut</a> to output a pointer to data.</em> <a href="#b5">More...</a><em></em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top><a name="b6" doxytag="sc::StateOut::put"></a>
virtual int&nbsp;</td><td valign=bottom><a class="el" href="class_sc__StateOut.html#b6">put</a> (const <a class="el" href="class_sc__ClassDesc.html">ClassDesc</a> *)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Write out information about the given <a class="el" href="class_sc__ClassDesc.html">ClassDesc</a>.</em></font><br><br></td></tr>
<tr><td colspan=2><br><h2>Protected Attributes</h2></td></tr>
<tr><td nowrap align=right valign=top><a name="n0" doxytag="sc::StateOut::dir_loc_loc_"></a>
int&nbsp;</td><td valign=bottom><b>dir_loc_loc_</b></td></tr>
<tr><td nowrap align=right valign=top><a name="n1" doxytag="sc::StateOut::translate_"></a>
<a class="el" href="class_sc__TranslateDataOut.html">TranslateDataOut</a>*&nbsp;</td><td valign=bottom><b>translate_</b></td></tr>
<tr><td nowrap align=right valign=top><a name="n2" doxytag="sc::StateOut::copy_references_"></a>
int&nbsp;</td><td valign=bottom><b>copy_references_</b></td></tr>
<tr><td nowrap align=right valign=top><a name="n3" doxytag="sc::StateOut::next_object_number_"></a>
int&nbsp;</td><td valign=bottom><b>next_object_number_</b></td></tr>
<tr><td nowrap align=right valign=top><a name="n4" doxytag="sc::StateOut::ps_"></a>
AVLMap&lt;<a class="el" href="class_sc__Ref.html">Ref</a>&lt;<a class="el" href="class_sc__SavableState.html">SavableState</a>&gt;,StateOutData&gt;&nbsp;</td><td valign=bottom><b>ps_</b></td></tr>
<tr><td nowrap align=right valign=top><a name="n5" doxytag="sc::StateOut::classidmap_"></a>
AVLMap&lt;ClassDescP,int&gt;&nbsp;</td><td valign=bottom><b>classidmap_</b></td></tr>
<tr><td nowrap align=right valign=top><a name="n6" doxytag="sc::StateOut::nextclassid_"></a>
int&nbsp;</td><td valign=bottom><b>nextclassid_</b></td></tr>
<tr><td nowrap align=right valign=top><a name="n7" doxytag="sc::StateOut::node_to_node_"></a>
int&nbsp;</td><td valign=bottom><b>node_to_node_</b></td></tr>
<tr><td colspan=2><br><h2>Friends</h2></td></tr>
<tr><td nowrap align=right valign=top>class &nbsp;</td><td valign=bottom><b>SavableState</b></td></tr>
<tr><td nowrap align=right valign=top>class &nbsp;</td><td valign=bottom><b>TranslateDataOut</b></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
Serializes objects that derive from <a class="el" href="class_sc__SavableState.html">SavableState</a>.
<p>
<a class="el" href="class_sc__StateOut.html">StateOut</a> keeps track of pointers to data so that two references to the same piece of data do not result in that data being sent to the output device two times. 
<p>
<hr><h2>Member Function Documentation</h2>
<a name="a20" doxytag="sc::StateOut::copy_references"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
  <tr>
    <td class="md">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td nowrap valign="top"><b> 
void sc::StateOut::copy_references (
          </b></td>
          <td valign="bottom"><b>
)
          </b></td>
        </tr>

      </table>
    </td>
  </tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
If a reference to an object that has already been written is encountered, copy it instead of generating a reference to the first object.
<p>
The directory will not be updated with new objects.     </td>
  </tr>
</table>
<a name="a19" doxytag="sc::StateOut::forget_references"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
  <tr>
    <td class="md">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td nowrap valign="top"><b> 
void sc::StateOut::forget_references (
          </b></td>
          <td valign="bottom"><b>
)
          </b></td>
        </tr>

      </table>
    </td>
  </tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Don't keep track of pointers to objects.
<p>
Calling this causes duplicated references to objects to be copied. The directory will not contain the forgotten objects.     </td>
  </tr>
</table>
<a name="a23" doxytag="sc::StateOut::node_to_node"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
  <tr>
    <td class="md">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td nowrap valign="top"><b> 
int sc::StateOut::node_to_node (
          </b></td>
          <td valign="bottom"><b>
) const<code> [inline]</code>
          </b></td>
        </tr>

      </table>
    </td>
  </tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
True if this is a node to node save/restore.
<p>
This is necessary for classes that try to avoid saving databases to files that can otherwise be read in, but want to avoid reading the database from disk on all nodes.     </td>
  </tr>
</table>
<a name="a9" doxytag="sc::StateOut::put"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
  <tr>
    <td class="md">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td nowrap valign="top"><b> 
int sc::StateOut::put (
          </b></td>
          <td valign="bottom"><b>
const char *, 
          </b></td>
        </tr>
        <tr>
          <td></td>
          <td><b>
int&nbsp;)<code> [virtual]</code>
          </b></td>
        </tr>

      </table>
    </td>
  </tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Write the given array data.
<p>
Size information is also saved. The data is allocated and read by the get(T*&amp;) routines. 
<p>
Reimplemented in <a class="el" href="class_sc__MsgStateSend.html#a10">sc::MsgStateSend</a>, and <a class="el" href="class_sc__StateOutText.html#a16">sc::StateOutText</a>.    </td>
  </tr>
</table>
<a name="a14" doxytag="sc::StateOut::put_array_char"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
  <tr>
    <td class="md">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td nowrap valign="top"><b> 
int sc::StateOut::put_array_char (
          </b></td>
          <td valign="bottom"><b>
const char * <em>p</em>, 
          </b></td>
        </tr>
        <tr>
          <td></td>
          <td><b>
int <em>size</em>&nbsp;)<code> [virtual]</code>
          </b></td>
        </tr>

      </table>
    </td>
  </tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Put arrays of data.
<p>
No size information is stored. This data is read by the get_array_T routines. 
<p>
Reimplemented in <a class="el" href="class_sc__StateOutText.html#a5">sc::StateOutText</a>.    </td>
  </tr>
</table>
<a name="b5" doxytag="sc::StateOut::putobject"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
  <tr>
    <td class="md">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td nowrap valign="top"><b> 
int sc::StateOut::putobject (
          </b></td>
          <td valign="bottom"><b>
const <a class="el" href="class_sc__Ref.html">Ref</a>&lt; <a class="el" href="class_sc__SavableState.html">SavableState</a> &gt; &amp;&nbsp;)<code> [protected, virtual]</code>
          </b></td>
        </tr>

      </table>
    </td>
  </tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
This will prepare <a class="el" href="class_sc__StateOut.html">StateOut</a> to output a pointer to data.
<p>
It first checks to see if the data has already been saved. If it has, then a reference to this data is saved. Otherwise the object is written out. 
<p>
Reimplemented in <a class="el" href="class_sc__StateOutText.html#b5">sc::StateOutText</a>.    </td>
  </tr>
</table>
<a name="a25" doxytag="sc::StateOut::seek"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
  <tr>
    <td class="md">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td nowrap valign="top"><b> 
void sc::StateOut::seek (
          </b></td>
          <td valign="bottom"><b>
int <em>loc</em>&nbsp;)<code> [virtual]</code>
          </b></td>
        </tr>

      </table>
    </td>
  </tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Set the current position in the file.
<p>
The default implementation does nothing. 
<p>
Reimplemented in <a class="el" href="class_sc__StateOutBin.html#a8">sc::StateOutBin</a>.    </td>
  </tr>
</table>
<a name="a26" doxytag="sc::StateOut::seekable"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
  <tr>
    <td class="md">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td nowrap valign="top"><b> 
int sc::StateOut::seekable (
          </b></td>
          <td valign="bottom"><b>
)<code> [virtual]</code>
          </b></td>
        </tr>

      </table>
    </td>
  </tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Return non-zero if tell and seek do anything sensible.
<p>
The default implementation returns 0. 
<p>
Reimplemented in <a class="el" href="class_sc__StateOutBin.html#a9">sc::StateOutBin</a>.    </td>
  </tr>
</table>
<a name="a24" doxytag="sc::StateOut::tell"></a><p>
<table width="100%" cellpadding="2" cellspacing="0" border="0">
  <tr>
    <td class="md">
      <table cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td nowrap valign="top"><b> 
int sc::StateOut::tell (
          </b></td>
          <td valign="bottom"><b>
)<code> [virtual]</code>
          </b></td>
        </tr>

      </table>
    </td>
  </tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
  <tr>
    <td>
      &nbsp;
    </td>
    <td>

<p>
Returns the current position in the file.
<p>
The default implementation returns 0. 
<p>
Reimplemented in <a class="el" href="class_sc__StateOutBin.html#a7">sc::StateOutBin</a>.    </td>
  </tr>
</table>
<hr>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="stateout_h-source.html">stateout.h</a></ul>
<hr>
<address>
<small>

Generated at Mon Oct 14 14:17:53 2002 for <a
href="http://aros.ca.sandia.gov/~cljanss/mpqc">MPQC</a>
2.1.2 using the documentation package <a
href="http://www.stack.nl/~dimitri/doxygen/index.html">Doxygen</a>
1.2.5.

</small>
</address>
</body>
</html>