oasys::StringShim Class Reference

#include <TypeShims.h>

Inheritance diagram for oasys::StringShim:

oasys::Formatter oasys::SerializableObject List of all members.

Detailed Description

Definition at line 83 of file TypeShims.h.

Public Member Functions

 StringShim (const std::string &str="", const char *name="string")
 StringShim (const Builder &)
virtual ~StringShim ()
int format (char *buf, size_t sz) const
 Virtual callback, called from this vsnprintf implementation whenever it encounters a format string of the form "*%p".
void serialize (SerializeAction *a)
 This should call v->process() on each of the types that are to be serialized in the object.
const std::string & value () const
void assign (const std::string &str)

Private Attributes

std::string name_
std::string str_


Constructor & Destructor Documentation

oasys::StringShim::StringShim ( const std::string &  str = "",
const char *  name = "string" 
) [inline]

Definition at line 85 of file TypeShims.h.

oasys::StringShim::StringShim ( const Builder  )  [inline]

Definition at line 87 of file TypeShims.h.

virtual oasys::StringShim::~StringShim (  )  [inline, virtual]

Definition at line 89 of file TypeShims.h.


Member Function Documentation

int oasys::StringShim::format ( char *  buf,
size_t  sz 
) const [inline, virtual]

Virtual callback, called from this vsnprintf implementation whenever it encounters a format string of the form "*%p".

The output routine must not write more than sz bytes and is not null terminated.

Returns:
The number of bytes written, or the number of bytes that would have been written if the output is truncated.
XXX/bowei -- this contract is fairly annoying to implement.

Implements oasys::Formatter.

Definition at line 92 of file TypeShims.h.

References snprintf(), and str_.

void oasys::StringShim::serialize ( SerializeAction a  )  [inline, virtual]

This should call v->process() on each of the types that are to be serialized in the object.

Implements oasys::SerializableObject.

Definition at line 97 of file TypeShims.h.

References name_, oasys::SerializeAction::process(), and str_.

const std::string& oasys::StringShim::value (  )  const [inline]

Definition at line 101 of file TypeShims.h.

References str_.

void oasys::StringShim::assign ( const std::string &  str  )  [inline]

Definition at line 102 of file TypeShims.h.

References str_.


Member Data Documentation

std::string oasys::StringShim::name_ [private]

Definition at line 105 of file TypeShims.h.

Referenced by serialize().

std::string oasys::StringShim::str_ [private]

Definition at line 106 of file TypeShims.h.

Referenced by assign(), format(), serialize(), and value().


The documentation for this class was generated from the following file:
Generated on Thu Jun 7 16:57:01 2007 for DTN Reference Implementation by  doxygen 1.5.1