Sophie

Sophie

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

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::Debugger 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:16:49 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::Debugger  Class Reference</h1>The <a class="el" href="class_sc__Debugger.html">Debugger</a> class describes what should be done when a catastrophic error causes unexpected program termination. 
<a href="#_details">More...</a>
<p>
<code>#include &lt;<a class="el" href="bug_h-source.html">bug.h</a>&gt;</code>
<p>
Inheritance diagram for sc::Debugger<p><center><img src="class_sc__Debugger_inherit_graph.gif" border="0" usemap="#sc::Debugger_inherit_map" alt="Inheritance graph"></center>
<map name="sc::Debugger_inherit_map">
<area href="class_sc__SavableState.html" shape="rect" coords="21,214,122,233">
<area href="class_sc__DescribedClass.html" shape="rect" coords="14,147,129,166">
<area href="class_sc__RefCount.html" shape="rect" coords="30,81,113,99">
<area href="class_sc__Identity.html" shape="rect" coords="35,14,107,33">
</map>
<center><font size="2">[<a href="graph_legend.html">legend</a>]</font></center>Collaboration diagram for sc::Debugger:<p><center><img src="class_sc__Debugger_coll_graph.gif" border="0" usemap="#sc::Debugger_coll_map" alt="Collaboration graph"></center>
<map name="sc::Debugger_coll_map">
<area href="class_sc__SavableState.html" shape="rect" coords="21,221,122,240">
<area href="class_sc__DescribedClass.html" shape="rect" coords="14,152,129,171">
<area href="class_sc__RefCount.html" shape="rect" coords="30,83,113,101">
<area href="class_sc__Identity.html" shape="rect" coords="35,13,107,32">
</map>
<center><font size="2">[<a href="graph_legend.html">legend</a>]</font></center><a href="class_sc__Debugger-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::Debugger::Debugger"></a>
&nbsp;</td><td valign=bottom><b>Debugger</b> (const char *exec=0)</td></tr>
<tr><td nowrap align=right valign=top>&nbsp;</td><td valign=bottom><a class="el" href="class_sc__Debugger.html#a1">Debugger</a> (const <a class="el" href="class_sc__Ref.html">Ref</a>&lt; <a class="el" href="class_sc__KeyVal.html">KeyVal</a> &gt; &amp;)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>The <a class="el" href="class_sc__KeyVal.html">KeyVal</a> constructor understands the following keywords:.</em> <a href="#a1">More...</a><em></em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top><a name="a2" doxytag="sc::Debugger::Debugger"></a>
&nbsp;</td><td valign=bottom><b>Debugger</b> (<a class="el" href="class_sc__StateIn.html">StateIn</a> &amp;)</td></tr>
<tr><td nowrap align=right valign=top><a name="a3" doxytag="sc::Debugger::~Debugger"></a>
&nbsp;</td><td valign=bottom><b>~Debugger</b> ()</td></tr>
<tr><td nowrap align=right valign=top><a name="a4" doxytag="sc::Debugger::debug"></a>
virtual void&nbsp;</td><td valign=bottom><a class="el" href="class_sc__Debugger.html#a4">debug</a> (const char *reason=0)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>The debug member attempts to start a debugger running on the current process.</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__Debugger.html#a5">traceback</a> (const char *reason=0)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>The traceback member attempts a stack traceback for the current process.</em> <a href="#a5">More...</a><em></em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top><a name="a6" doxytag="sc::Debugger::set_debug_on_signal"></a>
virtual void&nbsp;</td><td valign=bottom><a class="el" href="class_sc__Debugger.html#a6">set_debug_on_signal</a> (int)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Turn on or off debugging on a signel. The default is on.</em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top><a name="a7" doxytag="sc::Debugger::set_traceback_on_signal"></a>
virtual void&nbsp;</td><td valign=bottom><a class="el" href="class_sc__Debugger.html#a7">set_traceback_on_signal</a> (int)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Turn on or off traceback on a signel. The default is on.</em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top><a name="a8" doxytag="sc::Debugger::set_exit_on_signal"></a>
virtual void&nbsp;</td><td valign=bottom><a class="el" href="class_sc__Debugger.html#a8">set_exit_on_signal</a> (int)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Turn on or off exit after a signel. The default is on.</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__Debugger.html#a9">set_wait_for_debugger</a> (int)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Turn on or off running an infinite loop after the debugger is started.</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::Debugger::handle"></a>
virtual void&nbsp;</td><td valign=bottom><a class="el" href="class_sc__Debugger.html#a10">handle</a> (int sig)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>The <a class="el" href="class_sc__Debugger.html">Debugger</a> will be actived when sig is caught.</em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top><a name="a11" doxytag="sc::Debugger::handle_defaults"></a>
virtual void&nbsp;</td><td valign=bottom><a class="el" href="class_sc__Debugger.html#a11">handle_defaults</a> ()</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>This calls <a class="el" href="class_sc__Debugger.html#a10">handle</a>(int) with all of the major signals.</em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top><a name="a12" doxytag="sc::Debugger::set_prefix"></a>
virtual void&nbsp;</td><td valign=bottom><a class="el" href="class_sc__Debugger.html#a12">set_prefix</a> (const char *p)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>This sets a prefix which preceeds all messages printing by <a class="el" href="class_sc__Debugger.html">Debugger</a>.</em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top><a name="a13" doxytag="sc::Debugger::set_prefix"></a>
virtual void&nbsp;</td><td valign=bottom><a class="el" href="class_sc__Debugger.html#a13">set_prefix</a> (int p)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Set the prefix to the decimal represention of p followed by a ": ".</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__Debugger.html#a14">set_cmd</a> (const char *)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Sets the command to be exectuted when debug is called.</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::Debugger::default_cmd"></a>
virtual void&nbsp;</td><td valign=bottom><a class="el" href="class_sc__Debugger.html#a15">default_cmd</a> ()</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Calls set_cmd with a hopefully suitable default.</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__Debugger.html#a16">set_exec</a> (const char *)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Set the name of the exectuble for the current process.</em> <a href="#a16">More...</a><em></em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top><a name="a17" doxytag="sc::Debugger::got_signal"></a>
virtual void&nbsp;</td><td valign=bottom><a class="el" href="class_sc__Debugger.html#a17">got_signal</a> (int sig)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Called with signal sig is received. This is mainly for internal use.</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__Debugger.html#a18">save_data_state</a> (<a class="el" href="class_sc__StateOut.html">StateOut</a> &amp;)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Save the base classes (with save_data_state) and the members in the same order that the <a class="el" href="class_sc__StateIn.html">StateIn</a> CTOR initializes them.</em> <a href="#a18">More...</a><em></em></font><br><br></td></tr>
<tr><td colspan=2><br><h2>Static Public Methods</h2></td></tr>
<tr><td nowrap align=right valign=top><a name="d0" doxytag="sc::Debugger::set_default_debugger"></a>
void&nbsp;</td><td valign=bottom><a class="el" href="class_sc__Debugger.html#d0">set_default_debugger</a> (const <a class="el" href="class_sc__Ref.html">Ref</a>&lt; Debugger &gt; &amp;)</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Set the global default debugger. The initial value is null.</em></font><br><br></td></tr>
<tr><td nowrap align=right valign=top><a name="d1" doxytag="sc::Debugger::default_debugger"></a>
Debugger*&nbsp;</td><td valign=bottom><a class="el" href="class_sc__Debugger.html#d1">default_debugger</a> ()</td></tr>
<tr><td>&nbsp;</td><td><font size=-1><em>Return the global default debugger.</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::Debugger::init"></a>
void&nbsp;</td><td valign=bottom><b>init</b> ()</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::Debugger::prefix_"></a>
char*&nbsp;</td><td valign=bottom><b>prefix_</b></td></tr>
<tr><td nowrap align=right valign=top><a name="n1" doxytag="sc::Debugger::exec_"></a>
char*&nbsp;</td><td valign=bottom><b>exec_</b></td></tr>
<tr><td nowrap align=right valign=top><a name="n2" doxytag="sc::Debugger::cmd_"></a>
char*&nbsp;</td><td valign=bottom><b>cmd_</b></td></tr>
<tr><td nowrap align=right valign=top><a name="n3" doxytag="sc::Debugger::debugger_ready_"></a>
int&nbsp;</td><td valign=bottom><b>debugger_ready_</b></td></tr>
<tr><td nowrap align=right valign=top><a name="n4" doxytag="sc::Debugger::debug_"></a>
int&nbsp;</td><td valign=bottom><b>debug_</b></td></tr>
<tr><td nowrap align=right valign=top><a name="n5" doxytag="sc::Debugger::traceback_"></a>
int&nbsp;</td><td valign=bottom><b>traceback_</b></td></tr>
<tr><td nowrap align=right valign=top><a name="n6" doxytag="sc::Debugger::exit_on_signal_"></a>
int&nbsp;</td><td valign=bottom><b>exit_on_signal_</b></td></tr>
<tr><td nowrap align=right valign=top><a name="n7" doxytag="sc::Debugger::sleep_"></a>
int&nbsp;</td><td valign=bottom><b>sleep_</b></td></tr>
<tr><td nowrap align=right valign=top><a name="n8" doxytag="sc::Debugger::wait_for_debugger_"></a>
int&nbsp;</td><td valign=bottom><b>wait_for_debugger_</b></td></tr>
<tr><td nowrap align=right valign=top><a name="n9" doxytag="sc::Debugger::handle_sigint_"></a>
int&nbsp;</td><td valign=bottom><b>handle_sigint_</b></td></tr>
<tr><td nowrap align=right valign=top><a name="n10" doxytag="sc::Debugger::mysigs_"></a>
int*&nbsp;</td><td valign=bottom><b>mysigs_</b></td></tr>
<tr><td colspan=2><br><h2>Static Protected Attributes</h2></td></tr>
<tr><td nowrap align=right valign=top><a name="q0" doxytag="sc::Debugger::default_debugger_"></a>
Debugger*&nbsp;</td><td valign=bottom><b>default_debugger_</b></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
The <a class="el" href="class_sc__Debugger.html">Debugger</a> class describes what should be done when a catastrophic error causes unexpected program termination.
<p>
It can try things such as start a debugger running where the program died or it can attempt to produce a stack traceback showing roughly where the program died. These attempts will not always succeed. 
<p>
<hr><h2>Constructor &amp; Destructor Documentation</h2>
<a name="a1" doxytag="sc::Debugger::Debugger"></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> 
sc::Debugger::Debugger (
          </b></td>
          <td valign="bottom"><b>
const <a class="el" href="class_sc__Ref.html">Ref</a>&lt; <a class="el" href="class_sc__KeyVal.html">KeyVal</a> &gt; &amp;&nbsp;)
          </b></td>
        </tr>

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

<p>
The <a class="el" href="class_sc__KeyVal.html">KeyVal</a> constructor understands the following keywords:.
<p>

<dl compact>
 <dt><code>debug</code><dd> Try to start a debugger when an error occurs. Doesn't work on all machines. The default is true, if possible.
<p>
<dt><code>traceback</code><dd> Try to print out a traceback extracting return addresses from the call stack. Doesn't work on most machines. The default is true, if possible.
<p>
<dt><code>exit</code><dd> Exit on errors. The default is true.
<p>
<dt><code>wait_for_debugger</code><dd> When starting a debugger go into an infinite loop to give the debugger a chance to attach to the process. The default is true.
<p>
<dt><code>sleep</code><dd> When starting a debugger wait this many seconds to give the debugger a chance to attach to the process. The default is 0.
<p>
<dt><code>handle_defaults</code><dd> Handle a standard set of signals such as SIGBUS, SIGSEGV, etc. The default is true.
<p>
<dt><code>prefix</code><dd> Gives a string that is printed before each line that is printed by <a class="el" href="class_sc__Debugger.html">Debugger</a>. The default is nothing.
<p>
<dt><code>cmd</code><dd> Gives a command to be executed to start the debugger. The default varies with machine.
<p>

</dl>
     </td>
  </tr>
</table>
<hr><h2>Member Function Documentation</h2>
<a name="a18" doxytag="sc::Debugger::save_data_state"></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::Debugger::save_data_state (
          </b></td>
          <td valign="bottom"><b>
<a class="el" href="class_sc__StateOut.html">StateOut</a> &amp; <em>so</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>
Save the base classes (with save_data_state) and the members in the same order that the <a class="el" href="class_sc__StateIn.html">StateIn</a> CTOR initializes them.
<p>
This must be implemented by the derived class if the class has data. 
<p>
Reimplemented from <a class="el" href="class_sc__SavableState.html#a5">sc::SavableState</a>.    </td>
  </tr>
</table>
<a name="a14" doxytag="sc::Debugger::set_cmd"></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::Debugger::set_cmd (
          </b></td>
          <td valign="bottom"><b>
const char *&nbsp;)<code> [virtual]</code>
          </b></td>
        </tr>

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

<p>
Sets the command to be exectuted when debug is called.
<p>
The character sequence "" is replaced by the executable name (see set_exec), "" is replaced by the current process id, and "" is replaced by the prefix.     </td>
  </tr>
</table>
<a name="a16" doxytag="sc::Debugger::set_exec"></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::Debugger::set_exec (
          </b></td>
          <td valign="bottom"><b>
const char *&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 name of the exectuble for the current process.
<p>
It is up to the programmer to set this, even if the <a class="el" href="class_sc__Debugger.html">Debugger</a> is initialized with the <a class="el" href="class_sc__KeyVal.html">KeyVal</a> constructor.     </td>
  </tr>
</table>
<a name="a9" doxytag="sc::Debugger::set_wait_for_debugger"></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::Debugger::set_wait_for_debugger (
          </b></td>
          <td valign="bottom"><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>
Turn on or off running an infinite loop after the debugger is started.
<p>
This loop gives the debugger a chance to attack to the process. The default is on.     </td>
  </tr>
</table>
<a name="a5" doxytag="sc::Debugger::traceback"></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::Debugger::traceback (
          </b></td>
          <td valign="bottom"><b>
const char * <em>reason</em> = 0&nbsp;)<code> [virtual]</code>
          </b></td>
        </tr>

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

<p>
The traceback member attempts a stack traceback for the current process.
<p>
A symbol table must be saved for the executable if any sense is to be made of the traceback. Tracebacks are currently available only for a limited number of architectures.     </td>
  </tr>
</table>
<hr>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="bug_h-source.html">bug.h</a></ul>
<hr>
<address>
<small>

Generated at Mon Oct 14 14:16:49 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>