Serialize stream in JSON.
Merge pull request #2 from journalistrb/json-serialization

Serialize stream in JSON.