Class ByteForwarder.

Inherits Connection

The ByteForwarder class forwards all it reads to a sibling forwarder.

In effect, what one ByteForwarder reads, another reads, and what the other reads, the first one writes. Perfect for forwarding data between two sockets.

ByteForwarder is used as a helper for TlsServer.

ByteForwarder::ByteForwarder( int s, Connection * c )

Constructs an empty ByteForwarder on the file descriptor s, tied to c. When this ByteForwarder is closed, it closes c, too.

void ByteForwarder::setSibling( ByteForwarder * sibling )

Notifies this ByteForwarder (and its old and new siblings) that it is to write using sibling, or not write at all if sibling is null.

This web page based on source code belonging to Oryx Mail Systems GmbH. All rights reserved.