TBaseTransport

Provides basic fall-back implementations of the TTransport interface.

Constructors

this
this()
Undocumented in source.

Members

Functions

borrow
const(ubyte)[] borrow(ubyte* buf, size_t len)
Undocumented in source. Be warned that the author may not have intended to support it.
close
void close()
Undocumented in source. Be warned that the author may not have intended to support it.
consume
void consume(size_t len)
Undocumented in source. Be warned that the author may not have intended to support it.
flush
void flush()
Undocumented in source. Be warned that the author may not have intended to support it.
isOpen
bool isOpen()
Undocumented in source. Be warned that the author may not have intended to support it.
open
void open()
Undocumented in source. Be warned that the author may not have intended to support it.
peek
bool peek()
Undocumented in source. Be warned that the author may not have intended to support it.
read
size_t read(ubyte[] buf)
Undocumented in source. Be warned that the author may not have intended to support it.
readAll
void readAll(ubyte[] buf)
Undocumented in source. Be warned that the author may not have intended to support it.
readEnd
size_t readEnd()
Undocumented in source. Be warned that the author may not have intended to support it.
write
void write(ubyte[] buf)
Undocumented in source. Be warned that the author may not have intended to support it.
writeEnd
size_t writeEnd()
Undocumented in source. Be warned that the author may not have intended to support it.

Inherited Members

From TTransport

isOpen
bool isOpen()

Whether this transport is open.

peek
bool peek()

Tests whether there is more data to read or if the remote side is still open.

open
void open()

Opens the transport for communications.

close
void close()

Closes the transport.

read
size_t read(ubyte[] buf)

Attempts to fill the given buffer by reading data.

readAll
void readAll(ubyte[] buf)

Fills the given buffer by reading data into it, failing if not enough data is available.

readEnd
size_t readEnd()

Must be called by clients when read is completed.

write
void write(ubyte[] buf)

Writes the passed slice of data.

writeEnd
size_t writeEnd()

Must be called by clients when write is completed.

flush
void flush()

Flushes any pending data to be written.

borrow
const(ubyte)[] borrow(ubyte* buf, size_t len)

Attempts to return a slice of <code>len</code> bytes of incoming data, possibly copied into buf, not consuming them (i.e.: a later read will return the same data).

consume
void consume(size_t len)

Remove len bytes from the transport. This must always follow a borrow of at least len bytes, and should always succeed.

Meta