in_out.py 361 Bytes
Newer Older
1 2 3 4 5
#!/usr/bin/env python3

import sn


6 7 8 9 10
class MyBox(sn.SNPipelineBox):
    def setup(self):
        return {
                "foo": "bar",
        }
11

12 13
    def teardown(self):
        print("teardown")
14

15 16
    def process(self, msg_type, payload):
        print(msg_type, payload)
17

18
        return msg_type, payload
19 20 21


if __name__ == "__main__":
22
    MyBox("in_out").run()