string buffer input stream example