Qore Programming Language Reference Manual
0.8.12
|
This class defines an abstract interface for output streams. More...
Public Member Functions | |
abstract nothing | bulkWrite (binary data, timeout timeout_ms=-1) |
Writes bytes to the input stream. More... | |
abstract nothing | close () |
Closes the output stream and releases any resources. More... | |
constructor () | |
Constructor. More... | |
abstract nothing | write (int value, timeout timeout_ms=-1) |
Writes a single byte to the output stream. More... | |
This class defines an abstract interface for output streams.
Classes inheriting this class can be used to write bytes to files, sockets, memory etc.
|
pure virtual |
Writes bytes to the input stream.
data | the data to write |
timeout_ms | a timeout period with a resolution of milliseconds (a relative date/time value; integer arguments will be assumed to be milliseconds); if not given or negative the call will never time out |
IO-ERROR | if an I/O error occurs |
TIMEOUT-ERROR | if the data could not be written in the specified timeout |
Implemented in Qore::FileOutputStream, and Qore::BinaryOutputStream.
|
pure virtual |
Closes the output stream and releases any resources.
Any methods called on a closed output stream will thrown an IO-ERROR exception.
IO-ERROR | if an I/O error occurs |
Implemented in Qore::FileOutputStream, and Qore::BinaryOutputStream.
Qore::OutputStream::constructor | ( | ) |
Constructor.
Used by subclasses defined in the Qore programming language.
|
pure virtual |
Writes a single byte to the output stream.
value | the byte (0 - 255) to write to the output stream, only the least significant 8 bits are used, the rest is ignored |
timeout_ms | a timeout period with a resolution of milliseconds (a relative date/time value; integer arguments will be assumed to be milliseconds); if not given or negative the call will never time out |
IO-ERROR | if an I/O error occurs |
TIMEOUT-ERROR | if the byte could no be written in the specified timeout |
Implemented in Qore::BinaryOutputStream, and Qore::FileOutputStream.