Class: TGrowingChunkyStream

Declaration: Memory.h

Taxonomy Categories:

Member Functions:


Interface Category:

API.

Inherits From:

TChunkyStream

Inherited By:

None.

Purpose:

TGrowingChunkyStream is a concrete class (derived from TChunkyStream) that embodies a random access stream backed by chunks of memory, which can dynamically grow.

Instantiation:

Allocate on the heap or the stack.

Deriving Classes:

None.

Concurrency:

Not multithread safe.

Resource Use:

No special requirements.

Other Considerations:

No special requirements.

Member Function: TGrowingChunkyStream::TGrowingChunkyStream

  1. TGrowingChunkyStream ()
  2. TGrowingChunkyStream (TChunkyMemory * adoptChunkyMemory)
  3. TGrowingChunkyStream (const TGrowingChunkyStream & aChunkyStream)

Interface Category:

API.

Purpose:

  1. Default constructor.
  2. Creates a TGrowingChunkyStream that obtains memory chunks from a specific TChunkyMemory object.
  3. Copy constructor.

Calling Context:

  1. Called by the stream-in operators.
  2. Called to create a TGrowingChunkyStream which uses specific TChunkyMemory.
  3. Called to copy an object.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

The copy constructor performs a deep copy of the source object.

Member Function: TGrowingChunkyStream::operator<<=

virtual TStream & operator <<= (TStream & fromWhere)

Interface Category:

API.

Purpose:

Stream-in operator.

Calling Context:

Called to stream in data.

Parameters:

Return Value:

Returns a reference to the stream the object streams itself in from.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TGrowingChunkyStream::operator>>=

virtual TStream & operator >>=(TStream & toWhere) const

Interface Category:

API.

Purpose:

Stream-out operator.

Calling Context:

Called to stream out data.

Parameters:

Return Value:

Returns a reference to the stream the object streams itself out to.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TGrowingChunkyStream::operator=

TGrowingChunkyStream & operator =(const TGrowingChunkyStream & aChunkyStream)

Interface Category:

API.

Purpose:

Assignment operator.

Calling Context:

Called when an object is assigned to another compatible object.

Parameters:

Return Value:

A non-const reference to the left-hand side object.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TGrowingChunkyStream::~TGrowingChunkyStream

virtual ~ TGrowingChunkyStream ()

Interface Category:

API.

Purpose:

Destructor.

Calling Context:

Called to destroy an object.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TGrowingChunkyStream::AllocateForWrite

virtual void AllocateForWrite (StreamPosition desiredByteCount)

Interface Category:

API.

Purpose:

Completes stream-out operations that overflow the current stream buffer.

Calling Context:

Called by primitive streaming operators when there is not enough memory left in the current stream buffer to complete a stream-out operation.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

If needed the stream may grow.
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.