BESVersionInfo Class Reference

#include <BESVersionInfo.h>

Inheritance diagram for BESVersionInfo:

Inheritance graph
[legend]
Collaboration diagram for BESVersionInfo:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 BESVersionInfo ()
 constructs a basic text information response object to write version information
virtual ~BESVersionInfo ()
virtual void beginBESVersion ()
virtual void addBESVersion (const string &n, const string &v)
virtual void endBESVersion ()
virtual void beginHandlerVersion ()
virtual void addHandlerVersion (const string &n, const string &v)
virtual void endHandlerVersion ()
virtual void begin_response (const string &response_name)
virtual void end_response ()
virtual void add_tag (const string &tag_name, const string &tag_data, map< string, string > *attrs=0)
virtual void begin_tag (const string &tag_name, map< string, string > *attrs=0)
virtual void end_tag (const string &tag_name)
virtual void add_data (const string &s)
 add data to this informational object. If buffering is not set then the information is output directly to the output stream.
virtual void add_space (unsigned long num_spaces)
virtual void add_break (unsigned long num_breaks)
virtual void add_data_from_file (const string &key, const string &name)
 add data from a file to the informational object.
virtual void add_exception (BESError &e, const string &admin)
 add exception information to this informational object
virtual void transmit (BESTransmitter *transmitter, BESDataHandlerInterface &dhi)
 transmit the informational object
virtual void print (ostream &strm)
 print the information from this informational object to the specified stream
virtual void dump (ostream &strm) const
 dumps information about this object
virtual bool is_buffered ()
 return whether the information is to be buffered or not.

Protected Attributes

ostream * _strm
bool _strm_owned
bool _buffered
bool _response_started
stack< string > _tags
string _response_name


Detailed Description

brief represents simple text information in a response object, such as version and help inforamtion.

Uses the default add_data and print methods, where the print method, if the response is going to a browser, sets the mime type to text.

See also:
BESXMLInfo

BESResponseObject


Constructor & Destructor Documentation

BESVersionInfo::BESVersionInfo (  ) 

constructs a basic text information response object to write version information

See also:
BESXMLInfo

BESResponseObject

References BESInfoList::build_info(), and BESInfoList::TheList().

Here is the call graph for this function:

BESVersionInfo::~BESVersionInfo (  )  [virtual]


Member Function Documentation

void BESVersionInfo::beginBESVersion (  )  [virtual]

References BESInfo::begin_tag().

Referenced by BESVersionResponseHandler::execute().

Here is the call graph for this function:

void BESVersionInfo::addBESVersion ( const string &  n,
const string &  v 
) [virtual]

References BESInfo::add_tag(), BESInfo::begin_tag(), and BESInfo::end_tag().

Referenced by BESVersionResponseHandler::execute().

Here is the call graph for this function:

void BESVersionInfo::endBESVersion (  )  [virtual]

References BESInfo::end_tag().

Referenced by BESVersionResponseHandler::execute().

Here is the call graph for this function:

void BESVersionInfo::beginHandlerVersion (  )  [virtual]

References BESInfo::begin_tag().

Referenced by BESVersionResponseHandler::execute().

Here is the call graph for this function:

void BESVersionInfo::addHandlerVersion ( const string &  n,
const string &  v 
) [virtual]

References BESInfo::add_tag(), BESInfo::begin_tag(), and BESInfo::end_tag().

Here is the call graph for this function:

void BESVersionInfo::endHandlerVersion (  )  [virtual]

References BESInfo::end_tag().

Referenced by BESVersionResponseHandler::execute().

Here is the call graph for this function:

virtual void BESVersionInfo::begin_response ( const string &  response_name  )  [inline, virtual]

Reimplemented from BESInfo.

References BESInfo::begin_response().

Referenced by BESVersionResponseHandler::execute().

Here is the call graph for this function:

virtual void BESVersionInfo::end_response (  )  [inline, virtual]

Reimplemented from BESInfo.

References BESInfo::end_response().

Referenced by BESVersionResponseHandler::execute().

Here is the call graph for this function:

virtual void BESVersionInfo::add_tag ( const string &  tag_name,
const string &  tag_data,
map< string, string > *  attrs = 0 
) [inline, virtual]

Implements BESInfo.

References BESInfo::add_tag().

Referenced by BESDapRequestHandler::dap_build_version().

Here is the call graph for this function:

virtual void BESVersionInfo::begin_tag ( const string &  tag_name,
map< string, string > *  attrs = 0 
) [inline, virtual]

Reimplemented from BESInfo.

References BESInfo::begin_tag().

Referenced by BESDapRequestHandler::dap_build_version().

Here is the call graph for this function:

virtual void BESVersionInfo::end_tag ( const string &  tag_name  )  [inline, virtual]

Reimplemented from BESInfo.

References BESInfo::end_tag().

Referenced by BESDapRequestHandler::dap_build_version().

Here is the call graph for this function:

virtual void BESVersionInfo::add_data ( const string &  s  )  [inline, virtual]

add data to this informational object. If buffering is not set then the information is output directly to the output stream.

Parameters:
s information to be added to this informational response object

Reimplemented from BESInfo.

References BESInfo::add_data().

Here is the call graph for this function:

virtual void BESVersionInfo::add_space ( unsigned long  num_spaces  )  [inline, virtual]

Implements BESInfo.

References BESInfo::add_space().

Here is the call graph for this function:

virtual void BESVersionInfo::add_break ( unsigned long  num_breaks  )  [inline, virtual]

Implements BESInfo.

References BESInfo::add_break().

Here is the call graph for this function:

virtual void BESVersionInfo::add_data_from_file ( const string &  key,
const string &  name 
) [inline, virtual]

add data from a file to the informational object.

Adds data from a file to the informational object using the file specified by the passed key string. The key is found from the bes configuration file.

If the key does not exist in the initialization file then this information is added to the informational object, no excetion is thrown.

If the file does not exist then this information is added to the informational object, no exception is thrown.

Parameters:
key Key from the initialization file specifying the file to be
name A description of what is the information being loaded

Reimplemented from BESInfo.

References BESInfo::add_data_from_file().

Here is the call graph for this function:

virtual void BESVersionInfo::add_exception ( BESError e,
const string &  administrator 
) [inline, virtual]

add exception information to this informational object

Exception information is added differently to different informational objects, such as html, xml, plain text. But, using the other methods of this class we can take care of exceptions here.

Parameters:
e The exception to add to the informational response object

Reimplemented from BESInfo.

References BESInfo::add_exception().

Here is the call graph for this function:

virtual void BESVersionInfo::transmit ( BESTransmitter transmitter,
BESDataHandlerInterface dhi 
) [inline, virtual]

transmit the informational object

The derived informational object knows how it needs to be transmitted. Does it need to be sent as html? As text? As something else?

Parameters:
transmitter The type of transmitter to use to transmit the info
dhi information to help with the transmission

Implements BESInfo.

References BESInfo::transmit().

Referenced by BESVersionResponseHandler::transmit().

Here is the call graph for this function:

virtual void BESVersionInfo::print ( ostream &  strm  )  [inline, virtual]

print the information from this informational object to the specified stream

If the information was not buffered then this method does nothing, otherwise the information is output to the specified ostream.

Parameters:
strm output to this file descriptor if information buffered.

Reimplemented from BESInfo.

References BESInfo::print().

Here is the call graph for this function:

void BESVersionInfo::dump ( ostream &  strm  )  const [virtual]

dumps information about this object

Displays the pointer value of this instance along with information about this version information object

Parameters:
strm C++ i/o stream to dump the information to

Reimplemented from BESInfo.

References BESInfo::dump(), BESIndent::Indent(), BESIndent::LMarg(), and BESIndent::UnIndent().

Here is the call graph for this function:

virtual bool BESInfo::is_buffered (  )  [inline, virtual, inherited]

return whether the information is to be buffered or not.

Returns:
true if information is buffered, false if not

References BESInfo::_buffered.

Referenced by BESFilterTransmitter::send_html(), BESBasicHttpTransmitter::send_html(), BESFilterTransmitter::send_text(), and BESBasicHttpTransmitter::send_text().


Member Data Documentation

ostream* BESInfo::_strm [protected, inherited]

bool BESInfo::_strm_owned [protected, inherited]

bool BESInfo::_buffered [protected, inherited]

bool BESInfo::_response_started [protected, inherited]

stack<string> BESInfo::_tags [protected, inherited]

string BESInfo::_response_name [protected, inherited]


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

Generated on Thu Sep 11 07:59:18 2008 for OPeNDAP Back End Server (BES) by  doxygen 1.5.6