Class PackLock
- java.lang.Object
-
- org.eclipse.jgit.internal.storage.file.PackLock
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
lock(String msg)
Create thepack-*.keep
file, with the given message.void
unlock()
Remove the.keep
file that holds this pack in place.
-
-
-
Method Detail
-
lock
public boolean lock(String msg) throws IOException
Create thepack-*.keep
file, with the given message.- Parameters:
msg
- message to store in the file.- Returns:
- true if the keep file was successfully written; false otherwise.
- Throws:
IOException
- the keep file could not be written.
-
unlock
public void unlock() throws IOException
Remove the.keep
file that holds this pack in place.- Throws:
IOException
- if deletion of .keep file failed
-
-