Beispiel #1
0
 private long getPos() throws IOException {
   if (reader != null) {
     return readBytes + reader.getReadBytes();
   } else {
     return readBytes;
   }
 }
Beispiel #2
0
 private void closeReader() throws IOException {
   if (reader != null) {
     try {
       readBytes += reader.getReadBytes();
       reader.close();
     } catch (Exception e) {
       // not much to do here but skip the task
     } finally {
       reader = null;
     }
   }
 }