2005/5/9

     
 

class BinaryDataWriter

artefaktur
Modules   Namespace List   Class Hierarchy   Alphabetical List   Compound List   Namespace Members   Compound Members   Related Pages  

acdk::io::BinaryDataWriter Class Reference

#include <BinaryDataWriter.h>

Inheritance diagram for acdk::io::BinaryDataWriter:

acdk::io::AbstractFilterWriter acdk::io::DataWriter acdk::io::AbstractWriter acdk::io::FilterWriter acdk::lang::Object acdk::io::Writer acdk::lang::ObjectBase acdk::lang::dmi::StdDispatch List of all members.

Detailed Description

Filter to writes Data in Binary format.

Overtakes the role of java.io.DataOutputStream. API: ACDK

Author:
Roger Rene Kommer (mailto:kommer@artefaktur.com)
Version:
Revision
1.18
Date:
Date
2005/03/01 10:12:47


Public Member Functions

 BinaryDataWriter (IN(RWriter) out, acdk::lang::Endian en=acdk::lang::BigEndian)
virtual ~BinaryDataWriter ()
overwrite void flush ()
overwrite void write (byte c)
 default implementation: byte cbuf[2]; cbuf[1] = 0; cbuf[0] = c; return write((const byte*)cbuf, 0, 1);

virtual void write (const byte *cstr, int offset, int len)
virtual void write (IN(RbyteArray) ch, int offset=0, int len=-1)
 default implementation: return write(ch->data(), offset, len == -1 ? ch->length() - offset : len);

void setOut (IN(RWriter) writer)
RStorage getStorage ()
 Gets the storage reader.

RWriter getStorageWriter ()
 returns the unfiltered Writer

virtual void writeBoolean (bool b)
virtual void writeChar (char b)
virtual void writeUcChar (uc2char b)
virtual void writeShort (short b)
virtual void writeInt (int b)
virtual void writeLong (jlong b)
virtual void writeFloat (float b)
virtual void writeDouble (double b)
virtual void writeString (IN(RString) str)
virtual void writeOpaque (IN(RbyteArray) array)
 writes the data as opaque data.

acdk::lang::Endian endian ()
void endian (acdk::lang::Endian end)

Private Attributes

acdk::lang::Endian _endian


Constructor & Destructor Documentation

acdk::io::BinaryDataWriter::BinaryDataWriter IN(RWriter out,
acdk::lang::Endian  en = acdk::lang::BigEndian
[inline]
 

virtual acdk::io::BinaryDataWriter::~BinaryDataWriter  )  [inline, virtual]
 


Member Function Documentation

void acdk::io::BinaryDataWriter::endian acdk::lang::Endian  end  )  [inline]
 

acdk::lang::Endian acdk::io::BinaryDataWriter::endian  )  [inline]
 

overwrite void acdk::io::BinaryDataWriter::flush  )  [inline, virtual]
 

Reimplemented from acdk::io::AbstractFilterWriter.

RStorage acdk::io::BinaryDataWriter::getStorage  )  [inline, virtual]
 

Gets the storage reader.

If this contains an FilterReader instead of a Storage, the storage reader of this filter reader will be returned (recursive).

Reimplemented from acdk::io::AbstractFilterWriter.

RWriter acdk::io::BinaryDataWriter::getStorageWriter  )  [inline, virtual]
 

returns the unfiltered Writer

Reimplemented from acdk::io::AbstractFilterWriter.

void acdk::io::BinaryDataWriter::setOut IN(RWriter writer  )  [inline, virtual]
 

Reimplemented from acdk::io::AbstractFilterWriter.

virtual void acdk::io::BinaryDataWriter::write IN(RbyteArray ch,
int  offset = 0,
int  len = -1
[virtual]
 

default implementation: return write(ch->data(), offset, len == -1 ? ch->length() - offset : len);

Reimplemented from acdk::io::AbstractFilterWriter.

virtual void acdk::io::BinaryDataWriter::write const byte cstr,
int  offset,
int  len
[inline, virtual]
 

Reimplemented from acdk::io::AbstractFilterWriter.

overwrite void acdk::io::BinaryDataWriter::write byte  c  )  [inline, virtual]
 

default implementation: byte cbuf[2]; cbuf[1] = 0; cbuf[0] = c; return write((const byte*)cbuf, 0, 1);

Reimplemented from acdk::io::AbstractFilterWriter.

virtual void acdk::io::BinaryDataWriter::writeBoolean bool  b  )  [virtual]
 

Implements acdk::io::DataWriter.

virtual void acdk::io::BinaryDataWriter::writeChar char  b  )  [virtual]
 

Implements acdk::io::DataWriter.

virtual void acdk::io::BinaryDataWriter::writeDouble double  b  )  [virtual]
 

Implements acdk::io::DataWriter.

virtual void acdk::io::BinaryDataWriter::writeFloat float  b  )  [virtual]
 

Implements acdk::io::DataWriter.

virtual void acdk::io::BinaryDataWriter::writeInt int  b  )  [virtual]
 

Implements acdk::io::DataWriter.

virtual void acdk::io::BinaryDataWriter::writeLong jlong  b  )  [virtual]
 

Implements acdk::io::DataWriter.

virtual void acdk::io::BinaryDataWriter::writeOpaque IN(RbyteArray array  )  [virtual]
 

writes the data as opaque data.

DataWriter may apply some encoding

Reimplemented from acdk::io::DataWriter.

virtual void acdk::io::BinaryDataWriter::writeShort short  b  )  [virtual]
 

Implements acdk::io::DataWriter.

virtual void acdk::io::BinaryDataWriter::writeString IN(RString str  )  [virtual]
 

Implements acdk::io::DataWriter.

virtual void acdk::io::BinaryDataWriter::writeUcChar uc2char  b  )  [virtual]
 

Implements acdk::io::DataWriter.


Member Data Documentation

acdk::lang::Endian acdk::io::BinaryDataWriter::_endian [private]