Code example for FileChannel

Methods: close, force

0
 
  @Override 
  public void close() throws IOException { 
    LOG.info("closing " + _filename);
 
    _writeChannel.force(true);
    _writeChannel.close();
    _file.close();
  } 
 
  public void endEvents() 
  { 
    try { 
      close(); 
    } catch (IOException ioe) {
      LOG.warn("Couldn't endEvents for " + _file, ioe);
    } 
  } 
 
  @Override 
  public void onEvent(DbusEvent event, long offset, int size)