Rogue Wave banner
Previous fileTop of DocumentContentsIndex pageNext file
Essential Tools Module Reference Guide


Module:  Essential Tools Module   Group:  Virtual Stream


Local Index




#include <rw/auditbuf.h>
#include <iostream>
RWAuditStreamBuffer buf(arguments)
std::ostream os(&buf); // may be used for ostreams
std::istream is(&buf); // or istreams of any kind


Class RWAuditStreamBuffer is used to construct a stream, after which the RWAuditStreamBuffer instance will count all the bytes that pass through the stream. If constructed with a function pointer, RWAuditStreamBuffer will call that function with each byte that passes through the stream. The counting capacity provides for streams the equivalent of the RWCollectable method recursiveStoreSize() which is only available for RWFile.



Short Example

Related Classes

RWAuditStreamBuffer may be used as the streambuf for any stream, including those derived from RWvostream or RWvistream, strstream, ifstream, ofstream, etc.

Global Typedef

typedef void (*RWauditFunction)(unsigned char, void*);

Public Constructors

RWAuditStreamBuffer(RWauditFunction=0, void*=0);
RWAuditStreamBuffer(std::istream&, RWauditFunction=0, void*=0);
RWAuditStreamBuffer(std::iostream&, RWauditFunction=0, void*=0);
RWAuditStreamBuffer(std::ostream&, RWauditFunction=0, void*=0);
RWAuditStreamBuffer(std::streambuf*, RWauditFunction=0,

Public Destructor

virtual ~RWAuditStreamBuffer();

Public Member Operator

operator unsigned long();

Public Member Function

unsigned long
reset(unsigned long value = 0);

Extended Example

Previous fileTop of DocumentContentsIndex pageNext file

©2004 Copyright Quovadx, Inc. All Rights Reserved.
Rogue Wave and SourcePro are registered trademarks of Quovadx, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.
Contact Rogue Wave about documentation or support issues.