Added a way to store inout stream (incomplete)