OutputStream: improve 'get' and 'clear' methods