rwlogo
SourcePro C++ 12.0

SourcePro® C++ API Reference Guide



   SourcePro C++
Documentation Home

RWCharArrayOutputStream Class Reference
[Streams]

Handle class for narrow character output streams that allow retrieval of their inserted data as a narrow character array. More...

#include <rw/stream/RWCharArrayOutputStream.h>

Inheritance diagram for RWCharArrayOutputStream:
RWCharOutputStream RWHandleBase

List of all members.

Public Member Functions

 RWCharArrayOutputStream (RWCharArrayOutputStreamImp *body)
 RWCharArrayOutputStream (const RWCharArrayOutputStream &handle)
RWCharArrayOutputStreamoperator= (const RWCharArrayOutputStream &handle)
char * getCharacterArray ()
RWCString getString ()
RWSize getCharacterArraySize () const
void clear ()

Detailed Description

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


Constructor & Destructor Documentation

RWCharArrayOutputStream::RWCharArrayOutputStream ( RWCharArrayOutputStreamImp body  )  [inline, explicit]

Constructor.

Parameters:
body A pointer to an implementation class supporting the abstract interface RWCharArrayOutputStreamImp.
RWCharArrayOutputStream::RWCharArrayOutputStream ( const RWCharArrayOutputStream handle  )  [inline]

Copy constructor.

Parameters:
handle A narrow character array stream handle used to initialize the newly created handle.

Member Function Documentation

void RWCharArrayOutputStream::clear ( void   )  [inline]

Resets the underlying buffer.

char* RWCharArrayOutputStream::getCharacterArray (  )  [inline]

Returns a pointer to an array of narrow characters containing the 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 RWCharArrayOutputStream::getCharacterArraySize (  )  const [inline]

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

RWCString RWCharArrayOutputStream::getString (  )  [inline]

Returns a narrow character string object containing the characters inserted into the stream since its creation.

RWCharArrayOutputStream& RWCharArrayOutputStream::operator= ( const RWCharArrayOutputStream handle  )  [inline]

Assignment operator. Throws no exceptions.

Parameters:
handle A narrow character array stream handle used to initialize this handle.
 All Classes Functions Variables Typedefs Enumerations Enumerator Friends

© Copyright Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave and SourcePro are registered trademarks of Rogue Wave Software, 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.