#include <AbstractOutputStream.h>
Public Member Functions | |
const sk::util::Class | getClass () const |
Returns the object's class. | |
virtual int | write (const char *buffer, int offset, int length)=0 |
Writes length bytes from the specified byte array starting from offset to this stream. Returns the number of bytes written to this stream. | |
int | write (const std::vector< char > &data, int offset) |
Writes length bytes from the specified vector of chars starting from offset to this stream. Returns the number of bytes written to this stream. | |
int | write (const std::vector< char > &data) |
Writes length bytes from the specified vector of chars to this stream. Returns the number of bytes written to this stream. | |
int | write (char byte) |
Writes the specified byte to this output stream. | |
void | flush () |
Flushes this output stream and forces any buffered output bytes to be written out. | |
virtual void | close ()=0 |
Closes this output stream and releases any system resources associated with this stream. | |
virtual Object & | self () |
Returns a reference to itself. | |
virtual const Object & | self () const |
Object * | clone () const |
Instantiates another object of the same class as a copy of itself. | |
virtual uint64_t | getId () const |
Returns a unique object id. | |
virtual const String | toString () const |
Returns a string representation of the object. By default, it returns the object's class and the objects's id. | |
virtual const String | inspect () const |
Returns a string containing human-readable representation of the object. |
Object* sk::util::Object::clone | ( | ) | const [inherited] |
Instantiates another object of the same class as a copy of itself.
Reimplemented in sk::rt::logger::Destination, and sk::util::String.
virtual void sk::io::OutputStream::close | ( | ) | [pure virtual, inherited] |
Closes this output stream and releases any system resources associated with this stream.
Implemented in sk::io::BufferedOutputStream, sk::io::ByteArrayOutputStream, sk::io::DelegatingOutputStream, and sk::io::FileDescriptorOutputStream.
void sk::io::AbstractOutputStream::flush | ( | ) | [virtual] |
Flushes this output stream and forces any buffered output bytes to be written out.
Implements sk::io::OutputStream.
Reimplemented in sk::io::BufferedOutputStream, and sk::io::DelegatingOutputStream.
const sk::util::Class sk::io::AbstractOutputStream::getClass | ( | ) | const [virtual] |
Returns the object's class.
Reimplemented from sk::util::Object.
Reimplemented in sk::io::BufferedOutputStream, sk::io::ByteArrayOutputStream, sk::io::DataOutputStream, sk::io::DelegatingOutputStream, sk::io::FileDescriptorOutputStream, and sk::io::FileOutputStream.
virtual uint64_t sk::util::Object::getId | ( | ) | const [virtual, inherited] |
virtual const String sk::util::Object::inspect | ( | ) | const [virtual, inherited] |
Returns a string containing human-readable representation of the object.
Reimplemented in sk::rt::thread::AbstractLock, sk::rt::Thread, sk::util::Class, sk::util::Container, sk::util::slot::Pointer< T, Mixin >, sk::util::slot::Reference< T, Mixin >, sk::util::String, and sk::util::StringArray.
virtual const Object& sk::util::Object::self | ( | ) | const [virtual, inherited] |
Reimplemented in sk::util::String.
virtual Object& sk::util::Object::self | ( | ) | [virtual, inherited] |
virtual const String sk::util::Object::toString | ( | ) | const [virtual, inherited] |
Returns a string representation of the object. By default, it returns the object's class and the objects's id.
Reimplemented in sk::rt::logger::Level, sk::rt::thread::State, sk::util::Boolean, sk::util::Class, sk::util::Container, sk::util::Pathname, and sk::util::String.
int sk::io::AbstractOutputStream::write | ( | char | byte | ) | [virtual] |
int sk::io::AbstractOutputStream::write | ( | const std::vector< char > & | data | ) | [virtual] |
Writes length bytes from the specified vector of chars to this stream. Returns the number of bytes written to this stream.
Implements sk::io::OutputStream.
int sk::io::AbstractOutputStream::write | ( | const std::vector< char > & | data, | |
int | offset | |||
) | [virtual] |
Writes length bytes from the specified vector of chars starting from offset to this stream. Returns the number of bytes written to this stream.
Implements sk::io::OutputStream.
virtual int sk::io::AbstractOutputStream::write | ( | const char * | buffer, | |
int | offset, | |||
int | length | |||
) | [pure virtual] |
Writes length bytes from the specified byte array starting from offset to this stream. Returns the number of bytes written to this stream.
Implements sk::io::OutputStream.
Implemented in sk::io::BufferedOutputStream, sk::io::ByteArrayOutputStream, sk::io::DelegatingOutputStream, and sk::io::FileDescriptorOutputStream.