Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

more::io::syncstream Class Reference

A stream which provides both input and output using the same calls. More...

#include <more/io/syncstream.h>

Inheritance diagram for more::io::syncstream:

Inheritance graph
[legend]
List of all members.

Public Types

Public Methods

Protected Methods


Detailed Description

A stream which provides both input and output using the same calls.

The data is binary encoded, but architecture independent.


Member Enumeration Documentation

enum more::io::syncstream::openmode
 

Enumeration values:
in 
out 
test 


Constructor & Destructor Documentation

more::io::syncstream::syncstream (  std::streambuf *    buf )  [protected]
 

more::io::syncstream::syncstream (  std::streambuf *    buf,
std::ios_base::openmode    mode_
)  [protected]
 


Member Function Documentation

int more::io::syncstream::_version (    )  const [inline]
 

bool more::io::syncstream::bad (    )  [inline]
 

Return true if a file read error has occured.

void more::io::syncstream::clear (    )  [inline]
 

Clear the fail state of the stream.

int more::io::syncstream::digits (    )  [inline]
 

Return the mantissa bits precision as set by set_digits.

int more::io::syncstream::digits10 (    ) 
 

Return digits() converted to decimal digits.

bool more::io::syncstream::fail (    )  [inline]
 

Return true if an error has occured.

bool more::io::syncstream::good (    )  [inline]
 

Return true if no errors has occured.

bool more::io::syncstream::is_input (    )  [inline]
 

Return true if this is an input stream.

bool more::io::syncstream::is_output (    )  [inline]
 

Return true if this is an output stream.

syncstream& more::io::syncstream::operator| (  void(*    f)(syncstream &) )  [inline]
 

template<typename T, typename U>
syncstream& more::io::syncstream::operator| (  std::pair< T, U > &    x )  [inline]
 

syncstream& more::io::syncstream::operator| (  std::string &    x )  [inline]
 

syncstream& more::io::syncstream::operator| (  std::complex< long double > &    x )  [inline]
 

syncstream& more::io::syncstream::operator| (  std::complex< double > &    x )  [inline]
 

syncstream& more::io::syncstream::operator| (  std::complex< float > &    x )  [inline]
 

syncstream& more::io::syncstream::operator| (  long double &    x )  [inline]
 

syncstream& more::io::syncstream::operator| (  double &    x )  [inline]
 

syncstream& more::io::syncstream::operator| (  float &    x )  [inline]
 

syncstream& more::io::syncstream::operator| (  bool &    x )  [inline]
 

syncstream& more::io::syncstream::operator| (  unsigned long &    x )  [inline]
 

syncstream& more::io::syncstream::operator| (  long &    x )  [inline]
 

syncstream& more::io::syncstream::operator| (  unsigned int &    x )  [inline]
 

syncstream& more::io::syncstream::operator| (  int &    x )  [inline]
 

syncstream& more::io::syncstream::operator| (  unsigned short &    x )  [inline]
 

syncstream& more::io::syncstream::operator| (  short &    x )  [inline]
 

syncstream& more::io::syncstream::operator| (  unsigned char &    x )  [inline]
 

syncstream& more::io::syncstream::operator| (  signed char &    x )  [inline]
 

syncstream& more::io::syncstream::operator| (  char &    x )  [inline]
 

Sync x into or out of the stream and return *this.

template<typename T>
syncstream& more::io::syncstream::operator| (  T &    x )  [inline]
 

Call x.sync(*this) and return *this.

void more::io::syncstream::prolog (  std::ios_base::openmode    mode_ )  [protected]
 

void more::io::syncstream::set_digits (  int    dig )  [inline]
 

Use dig mantissa bits precision for writing floats.

This defaults to std::numeric_limits<double>::digits. This is an upper limit. When writing a floating point number of type T, the smaller of std::numeric_limits<T>::digits and dig is used.

void more::io::syncstream::set_digits10 (  int    dig10 ) 
 

Use dig10 decimal digits precision for writing floats.

void more::io::syncstream::setstate (  std::ios_base::iostate    st )  [inline]
 

Set the fail state of the stream.

void more::io::syncstream::sync_raw_data (  void *    p,
size_t    n
) 
 

Sync known size raw data.

This breaks the binary dump utility. Be careful if architecture independence is needed.


The documentation for this class was generated from the following file:
Generated on Sat Sep 7 19:12:46 2002 for more with Doxygen 1.2.13.1. Doxygen 1.2.13.1 is written and copyright 1997-2002 by Dimitri van Heesch.