SourcePro® API Reference Guide

Product Documentation:
   SourcePro
Documentation Home
List of all members | Public Member Functions
RWWCharArrayOutputStream Class Reference

Handle class for wide character output streams that support an extended interface, allowing retrieval of inserted data as a wide character array. More...

#include <rw/stream/RWWCharArrayOutputStream.h>

Inheritance diagram for RWWCharArrayOutputStream:
RWWCharOutputStream RWHandleBase

Public Member Functions

 RWWCharArrayOutputStream (RWWCharArrayOutputStreamImp *body)
 
 RWWCharArrayOutputStream (const RWWCharArrayOutputStream &handle)
 
void clear ()
 
wchar_t * getWCharacterArray ()
 
RWSize getWCharacterArraySize () const
 
RWWCharArrayOutputStreamoperator= (const RWWCharArrayOutputStream &handle)
 
- Public Member Functions inherited from RWWCharOutputStream
 RWWCharOutputStream (RWWCharOutputStreamImp *ptr)
 
 RWWCharOutputStream (const RWWCharOutputStream &handle)
 
void close ()
 
void flush ()
 
bool isBad () const
 
bool isFail () const
 
bool isGood () const
 
RWWCharOutputStreamoperator<< (RWWCharOutputStream &(*pf)(RWWCharOutputStream &))
 
RWWCharOutputStream operator<< (RWWCharOutputStream(*pf)(RWWCharOutputStream &))
 
RWWCharOutputStreamoperator<< (wchar_t wcharValue)
 
RWWCharOutputStreamoperator= (const RWWCharOutputStream &handle)
 
void write (wchar_t wcharValue)
 
void write (const wchar_t *wcharArray, RWSize numWChars)
 
- Public Member Functions inherited from RWHandleBase
bool isValid (void) const
 
bool operator!= (const RWHandleBase &second) const
 
bool operator< (const RWHandleBase &second) const
 
bool operator== (const RWHandleBase &second) const
 

Additional Inherited Members

- Protected Member Functions inherited from RWHandleBase
 RWHandleBase (void)
 
 RWHandleBase (RWStaticCtor)
 
 RWHandleBase (RWBodyBase *body)
 
 RWHandleBase (const RWHandleBase &second)
 
 ~RWHandleBase (void)
 
RWBodyBasebody (void) const
 
RWHandleBaseoperator= (const RWHandleBase &second)
 

Detailed Description

Handle class for wide character output streams that support an extended interface that allows retrieval of their inserted data as a wide character array. Implements the handle idiom from the handle-body pattern.

Constructor & Destructor Documentation

RWWCharArrayOutputStream::RWWCharArrayOutputStream ( RWWCharArrayOutputStreamImp body)
inlineexplicit

Constructor.

Parameters
bodyA pointer to an implementation class supporting the abstract interface RWWCharArrayOutputStreamImp.
RWWCharArrayOutputStream::RWWCharArrayOutputStream ( const RWWCharArrayOutputStream handle)
inline

Copy constructor.

Parameters
handleA wide character array stream handle used to initialize the newly created handle.

Member Function Documentation

void RWWCharArrayOutputStream::clear ( void  )
inline

Resets the underlying buffer.

wchar_t* RWWCharArrayOutputStream::getWCharacterArray ( )
inline

Returns a pointer to an array of wide characters containing the wide characters inserted into the stream since its creation. Users are responsible for freeing the memory associated with the array returned by this function using operator delete[].

RWSize RWWCharArrayOutputStream::getWCharacterArraySize ( ) const
inline

Returns the size of the wide character array that would be returned by a call to function getWCharacterArray().

RWWCharArrayOutputStream& RWWCharArrayOutputStream::operator= ( const RWWCharArrayOutputStream handle)
inline

Assignment operator. Throws no exceptions.

Parameters
handleA wide character array stream handle used to initialize this handle.

Copyright © 2021 Rogue Wave Software, Inc., a Perforce company. All Rights Reserved.