org.eclipse.core.resources
Class WorkspaceLock
java.lang.Object
org.eclipse.core.resources.WorkspaceLock
Deprecated. it is no longer possible to override the workspace lock behavior.
This functionality is now provided in the platform API by implementing the
org.eclipse.core.runtime.jobs.ILockListener interface.
-
public class WorkspaceLock
- extends
Object
A lock used to control write access to the resources in a workspace.
Clients may subclass.
-
See Also:
-
IWorkspace.setWorkspaceLock(WorkspaceLock)
Method Summary
|
boolean
|
acquire
()
Deprecated. Attempts to acquire this lock. |
protected
Thread
|
getCurrentOperationThread
()
Deprecated. Returns the thread that currently owns the workspace lock. |
protected boolean
|
isTreeLocked
()
Deprecated. Returns whether the workspace tree is locked
for resource changes. |
void
|
release
()
Deprecated. Releases this lock allowing others to acquire it. |
Methods inherited from class java.lang.
Object
|
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait
|
WorkspaceLock
public WorkspaceLock(
IWorkspace workspace)
throws
CoreException
-
Deprecated.
- Returns a new workspace lock.
-
Throws:
-
CoreException
- if fails.
acquire
public boolean acquire()
throws
InterruptedException
-
Deprecated.
- Attempts to acquire this lock. Callers will block indefinitely until this lock comes
available to them.
Clients may extend this method but should not otherwise call it.
-
-
Throws:
-
InterruptedException
- if fails while acquiring the lock. -
See Also:
-
release()
getCurrentOperationThread
protected
Thread getCurrentOperationThread()
-
Deprecated.
- Returns the thread that currently owns the workspace lock.
-
release
public void release()
-
Deprecated.
- Releases this lock allowing others to acquire it.
Clients may extend this method but should not otherwise call it.
-
-
See Also:
-
acquire()
isTreeLocked
protected boolean isTreeLocked()
-
Deprecated.
- Returns whether the workspace tree is locked
for resource changes.
-
-
Returns:
-
true
if the tree is locked, otherwise
false
Guidelines for using Eclipse APIs.
Copyright (c) Eclipse contributors and others 2000, 2008. All rights reserved.