Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

error Class Reference

Provides useful error-handling functions. More...

#include <error.h>

List of all members.

Static Public Methods

void fatal (const char *)
 Always exit after displaying message. More...

void fatal (const string &)
 Always exit after displaying message. More...

void fatal (const char *, const char *)
 Always exit after displaying message. More...

void fatal (const string &, const string &)
 Always exit after displaying message. More...

void warning (const char *)
 Print an error message and exit if error::strict is true. More...

void warning (const string &)
 Print an error message and exit if error::strict is true. More...

void warning (const char *, const char *)
 Print an error message and exit if error::strict is true. More...

void warning (const string &, const string &)
 Print an error message and exit if error::strict is true. More...

void message (const char *)
 Print an informational message if error::messages is nonzero. More...

void message (const string &)
 Print an informational message if error::messages is nonzero. More...

void message (const char *, const char *)
 Print an informational message if error::messages is nonzero. More...

void message (const string &, const string &)
 Print an informational message if error::messages is nonzero. More...

ostream& stream (ostream &s)
 Set the output stream. More...

ostream& stream ()

Static Public Attributes

int strict = 0
 Boolean to cause warnings to abort if true. More...

int messages = 0
 Boolean to display messages if true. More...


Static Private Attributes

ostream* pout = & cerr
 The output stream for errors. More...


Detailed Description

Provides useful error-handling functions.

If two arguments are supplied to an error reporting function, error will output the two arguments separated by a single space.

Output will always be terminated by a newline.

Output is sent to standard error (cerr) unless redirected to another ostream using error::stream.

fatal will always exit gracefully after displaying the message. warning will not exit unless error::strict is nonzero. message will not exit at all.

message will not display unless error::messages is nonzero.

error::strict and error::messages default to 0 (FALSE)

Definition at line 71 of file error.h.


Member Function Documentation

void error::fatal ( const string & e,
const string & f ) [static]
 

Always exit after displaying message.

Definition at line 63 of file error.cc.

void error::fatal ( const char * e,
const char * f ) [static]
 

Always exit after displaying message.

Definition at line 57 of file error.cc.

void error::fatal ( const string & e ) [static]
 

Always exit after displaying message.

Definition at line 54 of file error.cc.

void error::fatal ( const char * e ) [static]
 

Always exit after displaying message.

Definition at line 48 of file error.cc.

Referenced by interpolator::add(), cascade::add(), mixer::add_junction(), circuit::add_port(), mixer::auto_state(), branch::branch(), interpolator::build(), circuit::build_tree(), circuit::calc(), sdata::change_norm(), ivcurve::check(), circuit::connect(), connection::connection(), ivcurve::data(), datafile::datafile(), deembed::deembed(), fatal(), r_waveguide::fc(), mixer::get_term_data(), mixer::harmonics(), integrator::in(), mixer::initialize_operating_state(), inst_circuit::inst_circuit(), sis_basic_device::large_signal(), sis_basic_device::noise(), poly_fit::operator()(), interpolator::operator()(), mixer::balancer::operator()(), sdata::passive_noise(), portVector::pop(), portStack::pop(), interpolator::prime(), radial_stub::recalc(), mixer::recalc(), connection::recalc(), reduced_nport::recalc_S(), connection::recalc_S(), layerList::remove(), sdata::sdata(), sdata_interp::sdata_interp(), mixer::set_balance_terminator(), branch::set_branches(), mixer_currents::set_harmonic(), sis_basic_device::small_signal(), sweeper::sweep(), r_waveguide::update(), cpw::update(), microstrip::update(), interpolator::val_prime(), error_func_parameters::vary(), warning(), ydata::ydata(), and zdata::zdata().

void error::message ( const string & e,
const string & f ) [static]
 

Print an informational message if error::messages is nonzero.

Definition at line 103 of file error.cc.

void error::message ( const char * e,
const char * f ) [static]
 

Print an informational message if error::messages is nonzero.

Definition at line 97 of file error.cc.

void error::message ( const string & e ) [static]
 

Print an informational message if error::messages is nonzero.

Definition at line 94 of file error.cc.

void error::message ( const char * e ) [static]
 

Print an informational message if error::messages is nonzero.

Definition at line 88 of file error.cc.

Referenced by message().

ostream & error::stream ( ) [inline, static]
 

Returns:
the current error stream

Definition at line 138 of file error.h.

Referenced by powell::fmin(), powell::minimize(), montecarlo::minimize(), super_film::table_init(), and touchstone_read::value().

ostream & error::stream ( ostream & s ) [inline, static]
 

Set the output stream.

Default is cerr.

Parameters:
s   the new message output stream
Returns:
the previous value.

Definition at line 133 of file error.h.

void error::warning ( const string & e,
const string & f ) [static]
 

Print an error message and exit if error::strict is true.

Otherwise just warn the user.

Definition at line 85 of file error.cc.

void error::warning ( const char * e,
const char * f ) [static]
 

Print an error message and exit if error::strict is true.

Otherwise just warn the user.

Definition at line 77 of file error.cc.

void error::warning ( const string & e ) [static]
 

Print an error message and exit if error::strict is true.

Otherwise just warn the user.

Definition at line 74 of file error.cc.

void error::warning ( const char * e ) [static]
 

Print an error message and exit if error::strict is true.

Otherwise just warn the user.

Definition at line 66 of file error.cc.

Referenced by nport::B(), nport::C(), ampdata::F_min(), mixer::I_junc(), ampdata::Rn(), nport::S(), mixer::V_junc(), S_interp::add_S(), S_interp::add_SC(), ampdata::ampdata(), interpolator::build(), adaptive::build(), ampdata::center(), sdata::change_norm(), error_term_mode::checkval(), complex_parameter::complex_parameter(), complex_interp::construct(), sdata_interp::copy(), datafile::datafile(), ampdata::delta(), real_interp::file(), complex_interp::file(), ampdata::gamma_opt(), L_via::get(), scaled_real_parameter::get(), real_parameter::get(), real_interp::get(), portArray::get(), function_real_parameter::get(), input_tn::get(), s_mag::get(), gain_dB::get(), complex_parameter::get(), complex_interp::get(), portVector::get(), touchstone_read::get_noise(), nport::get_port(), connection::get_port(), mixer::initialize_operating_state(), ampdata::k(), powell::minimize(), minimize1(), ampdata::noise_measure(), touchstone_read::open(), poly_fit::operator()(), interpolator::operator()(), CauchyPV::operator()(), sweeper::operator++(), real_parameter::operator=(), complex_parameter::operator=(), data_parser::parse(), ydata::passive_noise(), zdata::passive_noise(), sdata::passive_noise(), passive_noise_temp(), touchstone_read::ports(), interpolator::prime(), portStack::push(), ampdata::radius(), real_parameter::real_parameter(), transformer::recalc(), sdata_interp::recalc_S(), deembed::recalc_S(), refine_minimum(), sdata::resize(), integrator::romberg_closed(), integrator::romberg_open(), super_film::sanity_check(), sdata::sdata(), portArray::set(), twin_slot_antenna::set(), mixer::set_balance_terminator(), real_parameter::set_max(), real_parameter::set_min(), error_func_parameters::set_parms(), sdata::set_znorm(), real_parameter::shadow(), complex_parameter::shadow(), super_film::sigma(), newton::solve(), sweeper::sweep_parameter::sweep_parameter(), ampdata::t_min(), super_film::table_init(), surfimp::thickness(), complex_interp::touchstone(), interpolator::val_prime(), touchstone_read::value(), warning(), ydata::ydata(), and zdata::zdata().


Member Data Documentation

int error::messages = 0 [static]
 

Boolean to display messages if true.

Defaults to false.

Definition at line 45 of file error.cc.

ostream * error::pout = & cerr [static, private]
 

The output stream for errors.

Defaults to standard error (cerr).

Definition at line 46 of file error.cc.

int error::strict = 0 [static]
 

Boolean to cause warnings to abort if true.

Defaults to false.

Definition at line 44 of file error.cc.


The documentation for this class was generated from the following files:

Please direct comments and corrections to supermix@submm.caltech.edu
Go to the supermix home page
Generated by doxygen1.2.7