Added implementation and tests for FutureTask.
I also was missing the set operation for AtomicReference, and cleaned a couple things up from LockSupport.
Changes so that we only set the running thread if we actually ARE the running thread
Merge pull request #186 from dicej/getDeclaredMethods

fix Class.getDeclaredMethods
Attempting to prevent interrupting threads after future has completed.
We added a 4th state, so we have "Canceling and Canceled".  We are in canceling state if we previously were running, and will not transition to canceled till after the interrupt has been sent.  So at the end if we are not running, or already canceled, we will sleep, waiting for the interrupt to occur so we can be sure we handle it before we let the thread complete.
This also fixes a condition where we returned true on a cancel after a task has already been canceled
Merge pull request #194 from jentfoo/FutureTask

Added implementation and tests for FutureTask.
Added interface BlockingDeque, and implementation for ExecutorCompletionService and LinkedBlockingQueue.
I had to implement a blocking queue for ExecutorCompletionService.  LinkedBlockingQueue could be very easily extended right now to implement the java 7 LinkedBlockingDeque.  Right now LinkedBlockingQueue just synchronizes and depends on LinkedList implementation.  But I wrote a very complete unit test suite so we if we want to put a more concurrent design here, we have a complete test suite to verify against.# Please enter the commit message for your changes. Lines starting
Added verify function to avoid throwing so many runtime exceptions in the tests
Merge pull request #195 from jentfoo/ExecutorCompletionService_and_LinkedBlockingQueue

Added interface BlockingDeque, and implementation for ExecutorCompletionService and LinkedBlockingQueue
implement ConcurrentHashMap and AtomicReferenceArray

This is the simplest possible ConcurrentHashMap I could come up with
that works and is actually concurrent in the way one would expect.
It's pretty unconventional, being based on a persistent red-black
tree, and not particularly memory-efficient or cache-friendly.  I
think this is a good place to start, though, and it should perform
reasonably for all but the most pathological workloads.  Patches for a
more efficient implementation are welcome!

I also implemented AtomicReferenceArray, since I was using it in my
first, naive attempt to implement ConcurrentHashMap.

I had to do a bit of refactoring, including moving some non-standard
stuff from java.util.Collections to avian.Data so I could make it
available to code outside the java.util package, which is why I had to
modify several unrelated files.
fix Completeion/Completion misspelling