MCPcopy Create free account
hub / github.com/AstroImageJ/astroimagej / lock

Method lock

ij/src/main/java/ij/ImagePlus.java:252–254  ·  view source on GitHub ↗

Locks the image so other threads can test to see if it is in use. One thread can lock an image multiple times, then it has to unlock it as many times until it is unlocked. This allows nested locking within a thread. Returns true if the image was successfully locked. Beeps, displays a message in the

()

Source from the content-addressed store, hash-verified

250 * false if the image is already locked by another thread.
251 */
252 public synchronized boolean lock() {
253 return lock(true);
254 }
255
256 /** Similar to lock, but doesn't beep and display an error
257 * message if the attempt to lock the image fails.

Callers 15

lockSilentlyMethod · 0.95
runMethod · 0.95
runMethod · 0.95
runMethod · 0.95
multiMeasureMethod · 0.95
multiPlotMethod · 0.95
drawOrFillMethod · 0.95
doUpdateMethod · 0.95
runMethod · 0.80
addSliceMethod · 0.80
deleteSliceMethod · 0.80

Calls 7

beepMethod · 0.95
showStatusMethod · 0.95
logMethod · 0.95
macroRunningMethod · 0.95
waitMethod · 0.95
setSlidersEnabledMethod · 0.80
getNameMethod · 0.65

Tested by

no test coverage detected