Code example for FileLock

Methods: release

0
 
    public void unlock(File fileToUnlock) {
        FileLock fileLock = lockCache.get(fileToUnlock);
        try { 
            if (fileLock != null) {
                fileLock.release();
            } 
            FileChannelCache.closeChannelFor(fileToUnlock);
        } catch (IOException e) {
            throw new MessagingException("Failed to unlock file: " 
                    + fileToUnlock, e);
        } 
	} 
}