beautypg.com

Specializing virtual streams – HP Integrity NonStop J-Series User Manual

Page 76

background image

Click on the banner to return to the user guide home page.

©Copyright 1996 Rogue Wave Software

Specializing Virtual Streams

The Rogue Wave classes include four types of classes that specialize

RWvistream

and

RWvostream

. The first uses a portable ASCII formatting, the second and third a binary

formatting, and the fourth an XDR formatting (eXternal Data Representation, a Sun
Microsytems standard):

Input class

Output class

Abstract base class

RWvistream

RWvostream

Portable ASCII

RWpistream

RWpostream

Binary

RWbistream

RWbostream

Endian

RWeistream

RWeostream

XDR

RWXDRistream RWXDRostream

The portable ASCII versions store their inserted items in an ASCII format that escapes special
characters (such as tabs, newlines, etc.) in such a manner that they will be restored properly,
even under a different operating system. The binary versions do not reformat inserted items, but
store them instead in their native format. The endian versions allow for the space and time
efficiency of binary format, but can store or retrieve the information in big endian, little endian,
or native format. XDR versions send their items to an XDR stream, to be transmitted remotely
over a network.

None of these versions retain any state: they can be freely interchanged with regular streams,
including XDR. Using them does not lock you into doing all your file I/O with them. For more
information, see the respective entries in the Class Reference.

This manual is related to the following products: