Oracle Coherence for C++ API
Release 3.7.1.0

E22845-01

DelegatingWriteBuffer::DelegatingBufferOutput Class Reference

#include <coherence/io/DelegatingWriteBuffer.hpp>

Inherits AbstractWriteBuffer::AbstractBufferOutput.

List of all members.


Detailed Description

A BufferOutput implementation that delegates to a BufferOutput implementation, except that its offset range is shifted and limited.

Author:
jh 2008.01.10
 

Public Types

typedef spec::Handle Handle
 DelegatingBufferOutput Handle definition.
typedef spec::View View
 DelegatingBufferOutput View definition.
typedef spec::Holder Holder
 DelegatingBufferOutput Holder definition.

Public Member Functions

virtual void write (octet_t b)
 Write the given octet.

Parameters:
 b the octet to write
Exceptions:
 IOException if an I/O error occurs
virtual void write (Array< octet_t >::View vab, size32_t of, size32_t cb)
 Writes cb octets starting at offset of from the array vab.

Parameters:
 vab the octet array to write from
 of the offset into vab to start writing from
 cb the number of octets from vab to write
Exceptions:
 IOException if an I/O error occurs
 NullPointerException if vab is NULL
 IndexOutOfBoundsException if of+cb is greater than vab->length
virtual void writeBuffer (ReadBuffer::View vBuf)
 Write all the octets from the passed ReadBuffer object.

This is functionally equivalent to the following code:

 getBuffer()->write(getOffset(), vBuf);
 

Parameters:
 vBuf a ReadBuffer object
Exceptions:
 IOException if an I/O error occurs
virtual void writeBuffer (ReadBuffer::View vBuf, size32_t of, size32_t cb)
 Write cb octets from the passed ReadBuffer object starting at offset of within the passed ReadBuffer.

This is functionally equivalent to the following code:

 getBuffer()->write(getOffset(), vbuf, of, cb);
 

Parameters:
 vBuf a ReadBuffer object
 of the offset within the ReadBuffer of the first octet to write to this BufferOutput
 cb the number of octets to write
Exceptions:
 IOException if an I/O error occurs
virtual void writeBoolean (bool f)
 Write a boolean value.

Parameters:
 f the bool to be written
Exceptions:
 IOException if an I/O error occurs
virtual void writeChar16 (char16_t ch)
 Write a 16-bit Unicode character value.

Parameters:
 ch the Unicode character as a char16_t value
Exceptions:
 IOException if an I/O error occurs
virtual void writeFloat32 (float32_t fl)
 Write a 32-bit floating-point value.

Parameters:
 fl the float32_t value to be written
Exceptions:
 IOException if an I/O error occurs
virtual void writeFloat64 (float64_t dfl)
 Write a 64-bit floating-point value.

Parameters:
 dfl the float64_t value to be written
Exceptions:
 IOException if an I/O error occurs

Protected Member Functions

 DelegatingBufferOutput (DelegatingWriteBuffer::Handle hBuf)
 Create a new DelegatingBufferOutput instance that delegates to the BufferOutput of the underlying WriteBuffer of the given DelegatingWriteBuffer.
virtual void moveOffset (size32_t cb)
 Move the offset within the stream forward.

Protected Attributes

MemberHandle
< BufferOutput > 
m_hOut
 The BufferOutput to delegate to.

Constructor & Destructor Documentation

DelegatingBufferOutput ( DelegatingWriteBuffer::Handle  hBuf  )  [protected]

Create a new DelegatingBufferOutput instance that delegates to the BufferOutput of the underlying WriteBuffer of the given DelegatingWriteBuffer.

Parameters:
 hBuf the delegate WriteBuffer


Member Function Documentation

virtual void moveOffset ( size32_t  cb  )  [protected, virtual]

Move the offset within the stream forward.

Parameters:
 cb the number of octets to advance the offset


The documentation for this class was generated from the following file:
Copyright © 2000, 2011, Oracle and/or its affiliates. All rights reserved.