Added io stream abstraction.