class TransInput

Message input stream with translation capability

Public Methods

TransInput(const Buffer& b)
data constructor.
TransInput(void)
Default input stream constructor
size_t read(char* x, size_t N=1) throw(std::runtime_error)
read a character array.
size_t read(std::string* x, size_t N=1) throw(std::runtime_error)
Read character strings.
size_t read(short* x, size_t N=1) throw(std::runtime_error)
Read a short integer array.
size_t read(int* x, size_t N=1) throw(std::runtime_error)
Read an integer array.
size_t read(long* x, size_t N=1) throw(std::runtime_error)
Read a long integer array.
size_t read(float* x, size_t N=1) throw(std::runtime_error)
read a character array.
size_t read(double* x, size_t N=1) throw(std::runtime_error)
Read a double array.
size_t read(Time* x, size_t N=1) throw(std::runtime_error)
Read an array of Times.
template <class T> TransInput& operator>>(T& x) throw(std::runtime_error)
Stream input operator template;

Documentation

Message input stream with translation capability. The TransInput class is effectively an input stream that is intelligent enough to translate between the big-endian external format and an internal format appropriate to the execution time machine.

TransInput(const Buffer& b)
Construct an input stream and attach a full message buffer to it.
Parameters:
b - Message buffer to be read by the input stream.

TransInput(void)
Default input stream constructor

size_t read(char* x, size_t N=1) throw(std::runtime_error)
Read and translate a character array.
Returns:
number of characters read.
Parameters:
x - Pointer to a character array to receive the data.
N - Number of characters to be read.

size_t read(std::string* x, size_t N=1) throw(std::runtime_error)
Read and translate a array of strings.
Returns:
number of strings read.
Parameters:
x - Pointer to array of strings to receive the data.
N - Number of strings to be read.

size_t read(short* x, size_t N=1) throw(std::runtime_error)
Read and translate a short integer array.
Returns:
Number of short integers read.
Parameters:
x - Pointer to a character array to receive the data.
N - Number of characters to be read.

size_t read(int* x, size_t N=1) throw(std::runtime_error)
Read and translate an integer array.
Returns:
Number of integers read.
Parameters:
x - Pointer to an integer array to receive the data.
N - Number of integers to be read.

size_t read(long* x, size_t N=1) throw(std::runtime_error)
Read and translate a long integer array.
Returns:
number of characters read.
Parameters:
x - Pointer to a long integer array to receive the data.
N - Number of long integers to be read.

size_t read(float* x, size_t N=1) throw(std::runtime_error)
Read and translate a float array.
Returns:
Number of floats read.
Parameters:
x - Pointer to a float array to receive the data.
N - Number of floats to be read.

size_t read(double* x, size_t N=1) throw(std::runtime_error)
Read and translate a double array.
Returns:
Number of doubles read.
Parameters:
x - Pointer to a double array to receive the data.
N - Number of doubles to be read.

size_t read(Time* x, size_t N=1) throw(std::runtime_error)
Read and translate an array of Time objects.
Returns:
number of Times read.
Parameters:
x - Pointer to a Time array to receive the data.
N - Number of Times to be read.

template <class T> TransInput& operator>>(T& x) throw(std::runtime_error)
Stream input operator template;


This class has no child classes.
Author:
John Zweizig
Version:
1.1; Modified August 20, 2001

alphabetic index hierarchy of classes


generated by doc++