snsary.streams.stream

Module Contents

class snsary.streams.stream.Stream

Bases: snsary.sources.Source, snsary.outputs.Output

into(*outputs)
tee(output)

Subscribes the specified Output to the stream using into, but unlike into also returns the stream for further use, similar to the Unix tee command.

apply(function)
filter_names(*names)
average(**kwargs)

Returns a new stream that applies a WindowAverage to all Readings over a period, specified as the keyword arguments for a timedelta.

summarize(**kwargs)

Returns a new stream that applies a WindowSummary to all Readings over a period, specified as the keyword arguments for a timedelta.

rename(**kwargs)

Returns a new stream that applies a Rename to all Readings. For example, rename(append="foo") will append “foo” to all reading names.