Mercurial > projects > dwt2
diff org.eclipse.core.jobs/src/org/eclipse/core/internal/jobs/LockManager.d @ 19:52184e4b815c
no more direct tango.core.Thread. Rename JThread to java.lang.Thread.
author | Frank Benoit <benoit@tionex.de> |
---|---|
date | Wed, 18 Mar 2009 10:55:25 +0100 |
parents | bc29606a740c |
children |
line wrap: on
line diff
--- a/org.eclipse.core.jobs/src/org/eclipse/core/internal/jobs/LockManager.d Wed Mar 18 09:57:53 2009 +0100 +++ b/org.eclipse.core.jobs/src/org/eclipse/core/internal/jobs/LockManager.d Wed Mar 18 10:55:25 2009 +0100 @@ -12,7 +12,7 @@ *******************************************************************************/ module org.eclipse.core.internal.jobs.LockManager; -import java.lang.JThread; +import java.lang.Thread; import java.lang.all; import java.util.Stack; import java.util.HashMap; @@ -117,7 +117,7 @@ /* (non-Javadoc) * Method declared on LockListener */ - public bool aboutToWait(JThread lockOwner) { + public bool aboutToWait(Thread lockOwner) { if (lockListener is null) return false; try { @@ -133,7 +133,7 @@ /** * This thread has just acquired a lock. Update graph. */ - void addLockThread(JThread thread, ISchedulingRule lock) { + void addLockThread(Thread thread, ISchedulingRule lock) { if (locks is null) return; try { @@ -148,7 +148,7 @@ /** * This thread has just been refused a lock. Update graph and check for deadlock. */ - void addLockWaitThread(JThread thread, ISchedulingRule lock) { + void addLockWaitThread(Thread thread, ISchedulingRule lock) { if (locks is null) return; try { @@ -222,13 +222,13 @@ public bool isLockOwner() { //all job threads have to be treated as lock owners because UI thread //may try to join a job - JThread current = JThread.currentThread(); + Thread current = Thread.currentThread(); if (cast(Worker)current ) return true; if (locks is null) return false; synchronized (locks) { - return locks.contains(JThread.currentThread()); + return locks.contains(Thread.currentThread()); } } @@ -242,7 +242,7 @@ /** * Releases all the acquires that were called on the given rule. Needs to be called only once. */ - void removeLockCompletely(JThread thread, ISchedulingRule rule) { + void removeLockCompletely(Thread thread, ISchedulingRule rule) { if (locks is null) return; try { @@ -257,7 +257,7 @@ /** * This thread has just released a lock. Update graph. */ - void removeLockThread(JThread thread, ISchedulingRule lock) { + void removeLockThread(Thread thread, ISchedulingRule lock) { try { synchronized (locks) { locks.lockReleased(thread, lock); @@ -270,7 +270,7 @@ /** * This thread has just stopped waiting for a lock. Update graph. */ - void removeLockWaitThread(JThread thread, ISchedulingRule lock) { + void removeLockWaitThread(Thread thread, ISchedulingRule lock) { try { synchronized (locks) { locks.lockWaitStop(thread, lock); @@ -283,7 +283,7 @@ /** * Resumes all the locks that were suspended while this thread was waiting to acquire another lock. */ - void resumeSuspendedLocks(JThread owner) { + void resumeSuspendedLocks(Thread owner) { LockState[] toResume; synchronized (suspendedLocks) { Stack prevLocks = cast(Stack) suspendedLocks.get(owner);