Implements interfaces: tubes.itube.IDrain

A _TransportDrain is an IDrain that wraps around an object that provides ITransport and IConsumer, and delivers data to that transport, and flow-control notifications from the consumer.

Method __init__ Undocumented
Method flowingFrom Data is flowing to this transport from the given fount. Register that fount as the transport's producer.
Method receive Receive an item of data, some bytes, from the fount. Pass it along to the transport.
Method flowStopped The flow of data that should be written to the underlying transport has ceased. Perform a half-close on the transport if possible so that it knows no further data is forthcoming.
Instance Variable _transport The transport. (type: IConsumer / ITransport provider.)
_transport =
The transport. (type: IConsumer / ITransport provider.)
def __init__(self, transport):
Undocumented
def flowingFrom(self, fount):

Data is flowing to this transport from the given fount. Register that fount as the transport's producer.

Parametersfountthe fount producing data - ISegments - for this transport.
def receive(self, item):

Receive an item of data, some bytes, from the fount. Pass it along to the transport.

Parametersitema fragment of a stream of bytes. (type: bytes)
def flowStopped(self, reason):

The flow of data that should be written to the underlying transport has ceased. Perform a half-close on the transport if possible so that it knows no further data is forthcoming.

Parametersreasonthe reason that the flow stopped; ignored.
API Documentation for tubes, generated by pydoctor at 2016-01-18 07:46:47.