don't use the setter methods from attr_accessor anymore to initialize the object, set instance vars and use attr_reader
don't initialize stream objects on every call, add some caching