added the possibility to stream to a file
version 0.0.2