tubes.itube.IDrain(Interface)
interface documentationtubes.itube
(View In Hierarchy)
Known implementations: tubes._siphon._SiphonDrain, tubes.fan._InDrain, tubes.fan._OutDrain, tubes.listening.Listener, tubes.protocol._TransportDrain
A drain consumes objects from a fount.
Attribute | inputType | Similar to IFount.outputType . |
Attribute | fount | The fount that is delivering data to this IDrain . |
Method | flowingFrom | This drain is now accepting a flow from the given IFount . |
Method | receive | An item was received from the fount. |
Method | flowStopped | No summary |
An item was received from the fount.
Parameters | item | an instance of IDrain.inputType |
Returns | a floating point number between 0.0 and 1.0, indicating the how full any buffers on the way to processing the data are (0-100%). Note that this may be greater than 100%, in which case you should probably stop sending for a while and give it a chance to recover. |
The flow has stopped. The given Failure
object indicates why. After a IFount
invokes this method,
it must stop invoking all other methods on this IDrain
; similarly, this IDrain
must stop invoking
all methods on its IFount
.
Parameters | reason | The reason why the flow has terminated. This may contain any exception
type, depending on the IFount delivering data to
this IDrain . (type: Failure ) |