public void resetToMark() throws IOException {
  if (stream != null) {
    stream.reset();
  }
 else {
    reader.reset();
  }
}

public void resetToMark ( ) throws IOException { if ( stream != null ) { stream . reset ( ) ; } else { reader . reset ( ) ; } }
reset to the last mark position .
