|
|
|
|
|
|
Modules Namespace List Class Hierarchy Alphabetical List Compound List Namespace Members Compound Members Related Pages
acdk::io::Reader Class Reference#include <Reader.h>
Inheritance diagram for acdk::io::Reader:
List of all members.
Detailed Description
General byte base reader.
- Note:
- To implement a reader a function has either to overload read() or read(byte* buffer, int offset, int len);
- Author:
- Roger Rene Kommer (mailto:kommer@artefaktur.com)
- Version:
- Revision
- 1.23
- Date:
- Date
- 2005/04/09 19:26:45
Member Function Documentation
virtual int acdk::io::Reader::available |
( |
|
) |
[inline, virtual] |
|
|
returns the number of bytes available in this stream before blocking Some Reader always return 0
Reimplemented in acdk::io::AbstractFilterReader, acdk::io::BufferedReader, acdk::io::ByteBufferReader, acdk::io::BytePtrReader, acdk::io::LittleBytesReader, acdk::io::CharToByteReader, acdk::io::FileReader, acdk::io::JoinedReader, acdk::io::MemReader, acdk::io::SubReader, acdk::lang::Process_PipeReader, acdk::net::srfsys::FilterObjectReader, acdk::net::TCPSocket, acdk::vfile::InflaterReader, and acdk::vfile::zip::ZipFileReader. |
virtual void acdk::io::Reader::close |
( |
|
) |
[inline, virtual] |
|
|
closes this Reader.
Note: Some Reader must be closed explicitaly Note: Reader implementation must be avare from closing a reader more than one
Reimplemented in acdk::io::AbstractFilterReader, acdk::io::BufferedReader, acdk::io::ByteBufferReader, acdk::io::BytePtrReader, acdk::io::FileReader, acdk::io::JoinedReader, acdk::io::MemReader, acdk::io::PipedReader, acdk::io::RandomAccessFile, acdk::net::srfsys::FilterObjectReader, acdk::net::TCPSocket, acdk::vfile::InflaterReader, and acdk::vfile::zip::ZipFileReader. |
void acdk::io::Reader::closeReader |
( |
|
) |
[inline] |
|
|
returns a character reader using standard encoding
- Parameters:
-
decoder | use decoder to read from bytes. if Nil uses the system encoding |
|
virtual RStorage acdk::io::Reader::getReaderStorage |
( |
|
) |
[virtual] |
|
virtual void acdk::io::Reader::mark |
( |
int |
readAheadLimit |
) |
[inline, virtual] |
|
virtual bool acdk::io::Reader::markSupported |
( |
|
) |
[inline, virtual] |
|
virtual int acdk::io::Reader::read |
( |
byte * |
buffer, |
|
|
int |
offset, |
|
|
int |
len |
|
) |
[virtual] |
|
|
- See also:
- other read(RbyteArray, int, int)
Reimplemented in acdk::io::AbstractFilterReader, acdk::io::AbstractReader, acdk::io::BinaryObjectReader, acdk::io::BufferedReader, acdk::io::ByteBufferReader, acdk::io::BytePtrReader, acdk::io::LittleBytesReader, acdk::io::CharToByteReader, acdk::io::ConsoleReader, acdk::io::FileReader, acdk::io::JoinedReader, acdk::io::LineNumberReader, acdk::io::MemReader, acdk::io::PipedReader, acdk::io::PushbackReader, acdk::io::RandomAccessFile, acdk::io::SubReader, acdk::io::TeeReader, acdk::lang::Process_PipeReader, acdk::net::srfsys::FilterObjectReader, acdk::net::TCPSocket, acdk::net::TransRateReader, acdk::vfile::InflaterReader, acdk::vfile::zip::ZipFileReader, and acdkx::orb::CDRObjectReader. |
virtual int acdk::io::Reader::read |
( |
IN(RbyteArray) |
buffer, |
|
|
int |
offset = 0, |
|
|
int |
len = -1 |
|
) |
[inline, virtual] |
|
|
read the len bytes into buffer at offset of the buffer
- Parameters:
-
buffer | where to write the bytes |
offset | offset to write into buffer |
len | how many bytes to read. if == -1 read into many bytes, that fits into buffer (buffer->length() - offset) `` |
- Returns:
- number of bytes readed. may less than input if EOS is reached
- Exceptions:
-
EOF | exception, if trying to read behind EOS |
Reimplemented in acdk::io::AbstractFilterReader, acdk::io::AbstractReader, acdk::io::BinaryObjectReader, acdk::io::BufferedReader, acdk::io::ByteBufferReader, acdk::io::BytePtrReader, acdk::io::LittleBytesReader, acdk::io::CharToByteReader, acdk::io::ConsoleReader, acdk::io::FileReader, acdk::io::JoinedReader, acdk::io::LineNumberReader, acdk::io::MemReader, acdk::io::PipedReader, acdk::io::PushbackReader, acdk::io::RandomAccessFile, acdk::io::SubReader, acdk::io::TeeReader, acdk::lang::Process_PipeReader, acdk::net::srfsys::FilterObjectReader, acdk::net::TCPSocket, acdk::net::TransRateReader, acdk::vfile::InflaterReader, acdk::vfile::zip::ZipFileReader, and acdkx::orb::CDRObjectReader. |
virtual int acdk::io::Reader::read |
( |
|
) |
[inline, virtual] |
|
|
read a single byte from stream
- Returns:
- the byte readed or -1 if EOS.
- Exceptions:
-
EOF | exception, if trying to read behind EOS |
Reimplemented in acdk::io::AbstractFilterReader, acdk::io::AbstractReader, acdk::io::BinaryObjectReader, acdk::io::BufferedReader, acdk::io::ByteBufferReader, acdk::io::BytePtrReader, acdk::io::LittleBytesReader, acdk::io::CharToByteReader, acdk::io::ConsoleReader, acdk::io::FileReader, acdk::io::JoinedReader, acdk::io::LineNumberReader, acdk::io::MemReader, acdk::io::PipedReader, acdk::io::PushbackReader, acdk::io::RandomAccessFile, acdk::io::SubReader, acdk::io::TeeReader, acdk::lang::Process_PipeReader, acdk::net::srfsys::FilterObjectReader, acdk::net::TCPSocket, acdk::net::TransRateReader, acdk::vfile::InflaterReader, acdk::vfile::zip::ZipFileReader, and acdkx::orb::CDRObjectReader. |
|
reads until EOF into returned byteArray
|
RString acdk::io::Reader::readAllAsString |
( |
|
) |
|
|
|
reads the content as String using standard encoding
|
virtual bool acdk::io::Reader::ready |
( |
|
) |
[inline, virtual] |
|
|
- Returns:
- true, if at least 1 byte can be readed from stream
Reimplemented in acdk::io::AbstractFilterReader, acdk::io::BufferedReader, acdk::io::ConsoleReader, acdk::io::FileReader, acdk::io::JoinedReader, acdk::io::MemReader, acdk::io::PipedReader, acdk::io::PushbackReader, acdk::io::RandomAccessFile, acdk::lang::Process_PipeReader, acdk::net::TCPSocket, acdk::vfile::InflaterReader, and acdk::vfile::zip::ZipFileReader. |
virtual void acdk::io::Reader::reset |
( |
|
) |
[pure virtual] |
|
|
if mark is set, set stream to mark point otherwise to begin of this stream.
Implemented in acdk::io::AbstractFilterReader, acdk::io::AbstractObjectReader, acdk::io::AbstractReader, acdk::io::ASCIIDataReader, acdk::io::BinaryDataReader, acdk::io::BufferedReader, acdk::io::ByteBufferReader, acdk::io::BytePtrReader, acdk::io::LittleBytesReader, acdk::io::CharToByteReader, acdk::io::ConsoleReader, acdk::io::DataReader, acdk::io::FileReader, acdk::io::FilterReader, acdk::io::JoinedReader, acdk::io::LineNumberReader, acdk::io::MemReader, acdk::io::ObjectReader, acdk::io::PipedReader, acdk::io::RandomAccessFile, acdk::net::srfsys::FilterObjectReader, acdk::net::TCPSocket, acdk::vfile::InflaterReader, acdk::vfile::zip::ZipFileReader, and acdkx::orb::CDRObjectReader. |
virtual jlong acdk::io::Reader::seek |
( |
SeekPos |
seekrel, |
|
|
jlong |
seekpos |
|
) |
[pure virtual] |
|
|
Set stream position in this Reader to given position.
- Returns:
- the absolute position in this stream
Implemented in acdk::io::AbstractFilterReader, acdk::io::AbstractObjectReader, acdk::io::AbstractReader, acdk::io::ASCIIDataReader, acdk::io::BinaryDataReader, acdk::io::BufferedReader, acdk::io::ByteBufferReader, acdk::io::BytePtrReader, acdk::io::LittleBytesReader, acdk::io::CharToByteReader, acdk::io::ConsoleReader, acdk::io::DataReader, acdk::io::FileReader, acdk::io::FilterReader, acdk::io::JoinedReader, acdk::io::MemReader, acdk::io::ObjectReader, acdk::io::RandomAccessFile, acdk::net::srfsys::FilterObjectReader, acdk::vfile::InflaterReader, acdk::vfile::zip::ZipFileReader, and acdkx::orb::CDRObjectReader. |
virtual jlong acdk::io::Reader::skip |
( |
jlong |
n |
) |
[pure virtual] |
|
|
Move forwart into the stream.
- Returns:
- how many bytes skipped. May less then input, in case EOS is reached
Implemented in acdk::io::AbstractFilterReader, acdk::io::AbstractObjectReader, acdk::io::AbstractReader, acdk::io::ASCIIDataReader, acdk::io::BinaryDataReader, acdk::io::BufferedReader, acdk::io::ByteBufferReader, acdk::io::BytePtrReader, acdk::io::LittleBytesReader, acdk::io::CharToByteReader, acdk::io::DataReader, acdk::io::FileReader, acdk::io::FilterReader, acdk::io::JoinedReader, acdk::io::MemReader, acdk::io::ObjectReader, acdk::io::PushbackReader, acdk::io::RandomAccessFile, acdk::io::SubReader, acdk::net::srfsys::FilterObjectReader, acdk::net::TCPSocket, acdk::vfile::InflaterReader, acdk::vfile::zip::ZipFileReader, and acdkx::orb::CDRObjectReader. |
void acdk::io::Reader::trans |
( |
IN(RWriter) |
out |
) |
|
|
|
writes reader until EOF into given Writer.
API: Extended |
|
|