public String readString(int length) throws IOException {
  byte[] array=new byte[length];
  readFully(array);
  String s=new String(array);
  return s.trim();
}

public String readString ( int length ) throws IOException { byte [ ] array = new byte [ length ] ; readFully ( array ) ; String s = new String ( array ) ; return s . trim ( ) ; }
constructs a string from the underlying input stream
