#include <BufferedInputStream.h>
Inheritance diagram for activemq::io::BufferedInputStream:
Public Member Functions | |
BufferedInputStream (InputStream *stream) | |
BufferedInputStream (InputStream *stream, const int bufferSize) | |
virtual | ~BufferedInputStream () |
virtual void | lock () throw ( exceptions::ActiveMQException ) |
virtual void | unlock () throw ( exceptions::ActiveMQException ) |
virtual void | wait () throw ( exceptions::ActiveMQException ) |
virtual void | wait (unsigned long millisecs) throw ( exceptions::ActiveMQException ) |
virtual void | notify () throw ( exceptions::ActiveMQException ) |
virtual void | notifyAll () throw ( exceptions::ActiveMQException ) |
virtual int | available () const |
virtual unsigned char | read () throw ( IOException ) |
virtual int | read (unsigned char *buffer, const int bufferSize) throw ( IOException ) |
virtual void | close (void) throw ( cms::CMSException ) |
Private Member Functions | |
void | init (InputStream *stream, const int bufferSize) |
void | bufferData (void) throw ( IOException ) |
Private Attributes | |
InputStream * | stream |
unsigned char * | buffer |
int | bufferSize |
int | head |
int | tail |
|
Constructor
|
|
Constructor
|
|
|
|
Indcates the number of bytes avaialable.
Implements activemq::io::InputStream. |
|
Populates the buffer with as much data as possible from the target input stream.
|
|
Closes the target input stream.
|
|
Initializes the internal structures.
|
|
Locks the object. throws ActiveMQException Implements activemq::concurrent::Synchronizable. |
|
Signals a waiter on this object that it can now wake up and continue. Must have this object locked before calling. throws ActiveMQException Implements activemq::concurrent::Synchronizable. |
|
Signals the waiters on this object that it can now wake up and continue. Must have this object locked before calling. throws ActiveMQException Implements activemq::concurrent::Synchronizable. |
|
Reads an array of bytes from the buffer.
Implements activemq::io::InputStream. |
|
Reads a single byte from the buffer.
Implements activemq::io::InputStream. |
|
Unlocks the object. throws ActiveMQException Implements activemq::concurrent::Synchronizable. |
|
Waits on a signal from this object, which is generated by a call to Notify. Must have this object locked before calling. This wait will timeout after the specified time interval.
Implements activemq::concurrent::Synchronizable. |
|
Waits on a signal from this object, which is generated by a call to Notify. Must have this object locked before calling. throws ActiveMQException Implements activemq::concurrent::Synchronizable. |
|
The internal buffer. |
|
The buffer size. |
|
The current head of the buffer. |
|
The target input stream. |
|
The current tail of the buffer. |