activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tab...@apache.org
Subject svn commit: r816733 [1/2] - in /activemq/activemq-cpp/trunk/activemq-cpp/src: main/activemq/core/ main/decaf/internal/io/ main/decaf/internal/util/concurrent/ main/decaf/io/ main/decaf/net/ main/decaf/util/ main/decaf/util/concurrent/ test/ test/decaf/...
Date Fri, 18 Sep 2009 18:14:05 GMT
Author: tabish
Date: Fri Sep 18 18:14:04 2009
New Revision: 816733

URL: http://svn.apache.org/viewvc?rev=816733&view=rev
Log:
Clearly defined the exception specification of the Synchronizable interface and updated all the implementations to match the spec.  Cleaned up the tests so everything works, new test cases need to be added to test that these exceptions are thrown when expected / possible. 

Modified:
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/core/MessageDispatchChannel.h
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/io/StandardErrorOutputStream.h
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/io/StandardInputStream.h
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/io/StandardOutputStream.h
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/concurrent/SynchronizableImpl.cpp
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/concurrent/SynchronizableImpl.h
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/BlockingByteArrayInputStream.h
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/ByteArrayInputStream.h
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/ByteArrayOutputStream.h
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/FilterInputStream.h
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/FilterOutputStream.h
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/net/SocketInputStream.h
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/net/SocketOutputStream.h
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/AbstractCollection.h
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/StlMap.h
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/StlQueue.h
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/ConcurrentStlMap.h
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/Mutex.cpp
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/Mutex.h
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/Synchronizable.h
    activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/io/BufferedInputStreamTest.cpp
    activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/io/BufferedOutputStreamTest.cpp
    activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/io/FilterInputStreamTest.cpp
    activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/util/StlMapTest.cpp
    activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/util/concurrent/MutexTest.cpp
    activemq/activemq-cpp/trunk/activemq-cpp/src/test/testRegistry.cpp

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/core/MessageDispatchChannel.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/core/MessageDispatchChannel.h?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/core/MessageDispatchChannel.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/core/MessageDispatchChannel.h Fri Sep 18 18:14:04 2009
@@ -143,35 +143,51 @@
 
     public:
 
-        virtual void lock() throw( decaf::lang::Exception ){
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
             channel.lock();
         }
 
-        virtual bool tryLock() throw( decaf::lang::Exception ) {
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
             return channel.tryLock();
         }
 
-        virtual void unlock() throw( decaf::lang::Exception ){
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
             channel.unlock();
         }
 
-        virtual void wait() throw( decaf::lang::Exception ){
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) {
+
             channel.wait();
         }
 
-        virtual void wait( long long millisecs ) throw( decaf::lang::Exception ) {
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             channel.wait( millisecs );
         }
 
-        virtual void wait( long long millisecs, int nanos ) throw( decaf::lang::Exception ) {
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             channel.wait( millisecs, nanos );
         }
 
-        virtual void notify() throw( decaf::lang::Exception ){
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             channel.notify();
         }
 
-        virtual void notifyAll() throw( decaf::lang::Exception ){
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             channel.notifyAll();
         }
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/io/StandardErrorOutputStream.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/io/StandardErrorOutputStream.h?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/io/StandardErrorOutputStream.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/io/StandardErrorOutputStream.h Fri Sep 18 18:14:04 2009
@@ -97,23 +97,51 @@
 
     public:
 
-        virtual void lock() throw( decaf::lang::Exception ){
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.lock();
         }
 
-        virtual void wait() throw( decaf::lang::Exception ){
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
+            return mutex.tryLock();
+        }
+
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
+            mutex.unlock();
+        }
+
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait();
         }
 
-        virtual void wait( long long millisecs ) throw( decaf::lang::Exception ){
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs );
         }
 
-        virtual void notify() throw( decaf::lang::Exception ){
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
+            mutex.wait( millisecs, nanos );
+        }
+
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notify();
         }
 
-        virtual void notifyAll() throw( decaf::lang::Exception ){
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notifyAll();
         }
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/io/StandardInputStream.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/io/StandardInputStream.h?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/io/StandardInputStream.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/io/StandardInputStream.h Fri Sep 18 18:14:04 2009
@@ -145,27 +145,51 @@
 
     protected:
 
-        virtual void lock() throw( lang::Exception ){
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.lock();
         }
 
-        virtual void unlock() throw( lang::Exception ){
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
+            return mutex.tryLock();
+        }
+
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.unlock();
         }
 
-        virtual void wait() throw( lang::Exception ){
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait();
         }
 
-        virtual void wait( long long millisecs ) throw( lang::Exception ){
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs );
         }
 
-        virtual void notify() throw( lang::Exception ){
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
+            mutex.wait( millisecs, nanos );
+        }
+
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notify();
         }
 
-        virtual void notifyAll() throw( lang::Exception ){
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notifyAll();
         }
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/io/StandardOutputStream.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/io/StandardOutputStream.h?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/io/StandardOutputStream.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/io/StandardOutputStream.h Fri Sep 18 18:14:04 2009
@@ -84,27 +84,51 @@
 
     public:
 
-        virtual void lock() throw( decaf::lang::Exception ){
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.lock();
         }
 
-        virtual void unlock() throw( decaf::lang::Exception ){
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
+            return mutex.tryLock();
+        }
+
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.unlock();
         }
 
-        virtual void wait() throw( decaf::lang::Exception ){
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait();
         }
 
-        virtual void wait( long long millisecs ) throw( decaf::lang::Exception ){
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs );
         }
 
-        virtual void notify() throw( decaf::lang::Exception ){
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
+            mutex.wait( millisecs, nanos );
+        }
+
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notify();
         }
 
-        virtual void notifyAll() throw( decaf::lang::Exception ){
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notifyAll();
         }
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/concurrent/SynchronizableImpl.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/concurrent/SynchronizableImpl.cpp?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/concurrent/SynchronizableImpl.cpp (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/concurrent/SynchronizableImpl.cpp Fri Sep 18 18:14:04 2009
@@ -29,41 +29,54 @@
 SynchronizableImpl::~SynchronizableImpl() {}
 
 ////////////////////////////////////////////////////////////////////////////////
-void SynchronizableImpl::lock() throw( lang::Exception ) {
+void SynchronizableImpl::lock() throw( decaf::lang::exceptions::RuntimeException ) {
     mutex.lock();
 }
 
 ////////////////////////////////////////////////////////////////////////////////
-bool SynchronizableImpl::tryLock() throw( lang::Exception ) {
+bool SynchronizableImpl::tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
     return mutex.tryLock();
 }
 
 ////////////////////////////////////////////////////////////////////////////////
-void SynchronizableImpl::unlock() throw( lang::Exception ) {
+void SynchronizableImpl::unlock() throw( decaf::lang::exceptions::RuntimeException ) {
     mutex.unlock();
 }
 
 ////////////////////////////////////////////////////////////////////////////////
-void SynchronizableImpl::wait() throw( lang::Exception ) {
+void SynchronizableImpl::wait() throw( decaf::lang::exceptions::RuntimeException,
+                                       decaf::lang::exceptions::IllegalMonitorStateException,
+                                       decaf::lang::exceptions::InterruptedException ) {
     mutex.wait();
 }
 
 ////////////////////////////////////////////////////////////////////////////////
-void SynchronizableImpl::wait( long long millisecs ) throw( lang::Exception ) {
+void SynchronizableImpl::wait( long long millisecs )
+    throw( decaf::lang::exceptions::RuntimeException,
+           decaf::lang::exceptions::IllegalMonitorStateException,
+           decaf::lang::exceptions::InterruptedException ) {
+
     mutex.wait( millisecs );
 }
 
 ////////////////////////////////////////////////////////////////////////////////
-void SynchronizableImpl::wait( long long millisecs, int nanos ) throw( lang::Exception ) {
+void SynchronizableImpl::wait( long long millisecs, int nanos )
+    throw( decaf::lang::exceptions::RuntimeException,
+           decaf::lang::exceptions::IllegalArgumentException,
+           decaf::lang::exceptions::IllegalMonitorStateException,
+           decaf::lang::exceptions::InterruptedException ) {
+
     mutex.wait( millisecs, nanos );
 }
 
 ////////////////////////////////////////////////////////////////////////////////
-void SynchronizableImpl::notify() throw( lang::Exception ) {
+void SynchronizableImpl::notify() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
     mutex.notify();
 }
 
 ////////////////////////////////////////////////////////////////////////////////
-void SynchronizableImpl::notifyAll() throw( lang::Exception ) {
+void SynchronizableImpl::notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                            decaf::lang::exceptions::IllegalMonitorStateException ) {
     mutex.notifyAll();
 }

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/concurrent/SynchronizableImpl.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/concurrent/SynchronizableImpl.h?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/concurrent/SynchronizableImpl.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/util/concurrent/SynchronizableImpl.h Fri Sep 18 18:14:04 2009
@@ -43,21 +43,32 @@
         SynchronizableImpl();
         virtual ~SynchronizableImpl();
 
-        virtual void lock() throw( lang::Exception );
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException );
 
-        virtual bool tryLock() throw( lang::Exception );
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException );
 
-        virtual void unlock() throw( lang::Exception );
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException );
 
-        virtual void wait() throw( lang::Exception );
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException );
 
-        virtual void wait( long long millisecs ) throw( lang::Exception );
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException );
 
-        virtual void wait( long long millisecs, int nanos ) throw( lang::Exception );
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException );
 
-        virtual void notify() throw( lang::Exception );
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException );
 
-        virtual void notifyAll() throw( lang::Exception );
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException );
 
     };
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/BlockingByteArrayInputStream.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/BlockingByteArrayInputStream.h?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/BlockingByteArrayInputStream.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/BlockingByteArrayInputStream.h Fri Sep 18 18:14:04 2009
@@ -195,35 +195,51 @@
 
     public:
 
-        virtual void lock() throw( lang::Exception ){
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.lock();
         }
 
-        virtual bool tryLock() throw( lang::Exception ) {
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
             return mutex.tryLock();
         }
 
-        virtual void unlock() throw( lang::Exception ){
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.unlock();
         }
 
-        virtual void wait() throw( lang::Exception ){
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait();
         }
 
-        virtual void wait( long long millisecs ) throw( lang::Exception ){
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs );
         }
 
-        virtual void wait( long long millisecs, int nanos ) throw( lang::Exception ) {
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs, nanos );
         }
 
-        virtual void notify() throw( lang::Exception ){
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notify();
         }
 
-        virtual void notifyAll() throw( lang::Exception ){
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notifyAll();
         }
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/ByteArrayInputStream.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/ByteArrayInputStream.h?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/ByteArrayInputStream.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/ByteArrayInputStream.h Fri Sep 18 18:14:04 2009
@@ -197,35 +197,51 @@
 
     protected:
 
-        virtual void lock() throw( lang::Exception ){
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.lock();
         }
 
-        virtual bool tryLock() throw( lang::Exception ) {
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
             return mutex.tryLock();
         }
 
-        virtual void unlock() throw( lang::Exception ){
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.unlock();
         }
 
-        virtual void wait() throw( lang::Exception ){
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait();
         }
 
-        virtual void wait( long long millisecs ) throw( lang::Exception ){
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs );
         }
 
-        virtual void wait( long long millisecs, int nanos ) throw( lang::Exception ) {
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs, nanos );
         }
 
-        virtual void notify() throw( lang::Exception ){
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notify();
         }
 
-        virtual void notifyAll() throw( lang::Exception ){
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notifyAll();
         }
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/ByteArrayOutputStream.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/ByteArrayOutputStream.h?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/ByteArrayOutputStream.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/ByteArrayOutputStream.h Fri Sep 18 18:14:04 2009
@@ -150,35 +150,51 @@
 
     public:
 
-        virtual void lock() throw( lang::Exception ){
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.lock();
         }
 
-        virtual bool tryLock() throw( lang::Exception ) {
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
             return mutex.tryLock();
         }
 
-        virtual void unlock() throw( lang::Exception ){
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.unlock();
         }
 
-        virtual void wait() throw( lang::Exception ){
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait();
         }
 
-        virtual void wait( long long millisecs ) throw( lang::Exception ){
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs );
         }
 
-        virtual void wait( long long millisecs, int nanos ) throw( lang::Exception ) {
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs, nanos );
         }
 
-        virtual void notify() throw( lang::Exception ){
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notify();
         }
 
-        virtual void notifyAll() throw( lang::Exception ){
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notifyAll();
         }
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/FilterInputStream.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/FilterInputStream.h?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/FilterInputStream.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/FilterInputStream.h Fri Sep 18 18:14:04 2009
@@ -281,35 +281,51 @@
 
     public:  // Synchronizable
 
-        virtual void lock() throw( lang::Exception ){
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.lock();
         }
 
-        virtual bool tryLock() throw( lang::Exception ) {
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
             return mutex.tryLock();
         }
 
-        virtual void unlock() throw( lang::Exception ){
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.unlock();
         }
 
-        virtual void wait() throw( lang::Exception ){
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait();
         }
 
-        virtual void wait( long long millisecs ) throw( lang::Exception ){
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs );
         }
 
-        virtual void wait( long long millisecs, int nanos ) throw( lang::Exception ) {
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs, nanos );
         }
 
-        virtual void notify() throw( lang::Exception ){
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notify();
         }
 
-        virtual void notifyAll() throw( lang::Exception ){
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notifyAll();
         }
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/FilterOutputStream.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/FilterOutputStream.h?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/FilterOutputStream.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/io/FilterOutputStream.h Fri Sep 18 18:14:04 2009
@@ -212,35 +212,51 @@
 
     public:  // Synchronizable
 
-        virtual void lock() throw( lang::Exception ){
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.lock();
         }
 
-        virtual bool tryLock() throw( lang::Exception ) {
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
             return mutex.tryLock();
         }
 
-        virtual void unlock() throw( lang::Exception ){
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.unlock();
         }
 
-        virtual void wait() throw( lang::Exception ){
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait();
         }
 
-        virtual void wait( long long millisecs ) throw( lang::Exception ){
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs );
         }
 
-        virtual void wait( long long millisecs, int nanos ) throw( lang::Exception ) {
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs, nanos );
         }
 
-        virtual void notify() throw( lang::Exception ){
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notify();
         }
 
-        virtual void notifyAll() throw( lang::Exception ){
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notifyAll();
         }
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/net/SocketInputStream.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/net/SocketInputStream.h?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/net/SocketInputStream.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/net/SocketInputStream.h Fri Sep 18 18:14:04 2009
@@ -151,35 +151,51 @@
 
     public:
 
-        virtual void lock() throw( lang::Exception ){
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.lock();
         }
 
-        virtual bool tryLock() throw( lang::Exception ) {
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
             return mutex.tryLock();
         }
 
-        virtual void unlock() throw( lang::Exception ){
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.unlock();
         }
 
-        virtual void wait() throw( lang::Exception ){
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait();
         }
 
-        virtual void wait( long long millisecs ) throw( lang::Exception ) {
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs );
         }
 
-        virtual void wait( long long millisecs, int nanos ) throw( lang::Exception ) {
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs, nanos );
         }
 
-        virtual void notify() throw( lang::Exception ){
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notify();
         }
 
-        virtual void notifyAll() throw( lang::Exception ){
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notifyAll();
         }
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/net/SocketOutputStream.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/net/SocketOutputStream.h?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/net/SocketOutputStream.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/net/SocketOutputStream.h Fri Sep 18 18:14:04 2009
@@ -90,37 +90,53 @@
 
     public:
 
-        virtual void lock() throw( lang::Exception ){
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.lock();
         }
 
-        virtual bool tryLock() throw( lang::Exception ) {
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
             return mutex.tryLock();
         }
 
-        virtual void unlock() throw( lang::Exception ){
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.unlock();
         }
 
-        virtual void wait() throw( lang::Exception ){
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait();
         }
 
-        virtual void wait( long long millisecs ) throw( lang::Exception ) {
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs );
         }
 
-        virtual void wait( long long millisecs, int nanos ) throw( lang::Exception ) {
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs, nanos );
         }
 
-        virtual void notify() throw( lang::Exception ){
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notify();
         }
 
-        virtual void notifyAll() throw( lang::Exception ){
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notifyAll();
-         }
+        }
 
     };
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/AbstractCollection.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/AbstractCollection.h?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/AbstractCollection.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/AbstractCollection.h Fri Sep 18 18:14:04 2009
@@ -419,35 +419,51 @@
 
     public:
 
-        virtual void lock() throw( lang::Exception ) {
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.lock();
         }
 
-        virtual bool tryLock() throw( lang::Exception ) {
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
             return mutex.tryLock();
         }
 
-        virtual void unlock() throw( lang::Exception ) {
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.unlock();
         }
 
-        virtual void wait() throw( lang::Exception ) {
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait();
         }
 
-        virtual void wait( long long millisecs ) throw( lang::Exception ) {
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs );
         }
 
-        virtual void wait( long long millisecs, int nanos ) throw( lang::Exception ) {
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs, nanos );
         }
 
-        virtual void notify() throw( lang::Exception  ) {
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notify();
         }
 
-        virtual void notifyAll() throw( lang::Exception  ) {
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notifyAll();
         }
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/StlMap.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/StlMap.h?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/StlMap.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/StlMap.h Fri Sep 18 18:14:04 2009
@@ -276,35 +276,51 @@
 
     public:
 
-        virtual void lock() throw( lang::Exception ) {
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.lock();
         }
 
-        virtual bool tryLock() throw( lang::Exception ) {
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
             return mutex.tryLock();
         }
 
-        virtual void unlock() throw( lang::Exception ) {
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.unlock();
         }
 
-        virtual void wait() throw( lang::Exception ) {
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait();
         }
 
-        virtual void wait( long long millisecs ) throw( lang::Exception ) {
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs );
         }
 
-        virtual void wait( long long millisecs, int nanos ) throw( lang::Exception ) {
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs, nanos );
         }
 
-        virtual void notify() throw( lang::Exception ) {
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notify();
         }
 
-        virtual void notifyAll() throw( lang::Exception ) {
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notifyAll();
         }
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/StlQueue.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/StlQueue.h?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/StlQueue.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/StlQueue.h Fri Sep 18 18:14:04 2009
@@ -249,35 +249,51 @@
 
     public:  // Synchronizable
 
-        virtual void lock() throw( lang::Exception ){
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.lock();
         }
 
-        virtual bool tryLock() throw( lang::Exception ) {
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
             return mutex.tryLock();
         }
 
-        virtual void unlock() throw( lang::Exception ){
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.unlock();
         }
 
-        virtual void wait() throw( lang::Exception ){
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait();
         }
 
-        virtual void wait( long long millisecs ) throw( lang::Exception ) {
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs );
         }
 
-        virtual void wait( long long millisecs, int nanos ) throw( lang::Exception ) {
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs, nanos );
         }
 
-        virtual void notify() throw( lang::Exception ){
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notify();
         }
 
-        virtual void notifyAll() throw( lang::Exception ){
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notifyAll();
         }
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/ConcurrentStlMap.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/ConcurrentStlMap.h?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/ConcurrentStlMap.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/ConcurrentStlMap.h Fri Sep 18 18:14:04 2009
@@ -458,35 +458,51 @@
 
     public:
 
-        virtual void lock() throw( lang::Exception ) {
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.lock();
         }
 
-        virtual bool tryLock() throw( lang::Exception ) {
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
             return mutex.tryLock();
         }
 
-        virtual void unlock() throw( lang::Exception ) {
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
             mutex.unlock();
         }
 
-        virtual void wait() throw( lang::Exception ) {
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait();
         }
 
-        virtual void wait( long long millisecs ) throw( lang::Exception ) {
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs );
         }
 
-        virtual void wait( long long millisecs, int nanos ) throw( lang::Exception ) {
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
+
             mutex.wait( millisecs, nanos );
         }
 
-        virtual void notify() throw( lang::Exception ) {
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notify();
         }
 
-        virtual void notifyAll() throw( lang::Exception ) {
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
+
             mutex.notifyAll();
         }
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/Mutex.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/Mutex.cpp?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/Mutex.cpp (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/Mutex.cpp Fri Sep 18 18:14:04 2009
@@ -65,43 +65,60 @@
 }
 
 ////////////////////////////////////////////////////////////////////////////////
-void Mutex::lock() throw( lang::Exception ) {
+void Mutex::lock() throw( decaf::lang::exceptions::RuntimeException ) {
 
     MutexImpl::lock( this->properties->mutex.get() );
 }
 
 ////////////////////////////////////////////////////////////////////////////////
-bool Mutex::tryLock() throw( lang::Exception ) {
+bool Mutex::tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
+
     return MutexImpl::trylock( this->properties->mutex.get() );
 }
 
 ////////////////////////////////////////////////////////////////////////////////
-void Mutex::unlock() throw( lang::Exception ) {
+void Mutex::unlock() throw( decaf::lang::exceptions::RuntimeException ) {
+
     MutexImpl::unlock( this->properties->mutex.get() );
 }
 
 ////////////////////////////////////////////////////////////////////////////////
-void Mutex::wait() throw( lang::Exception ) {
+void Mutex::wait() throw( decaf::lang::exceptions::RuntimeException,
+                          decaf::lang::exceptions::IllegalMonitorStateException,
+                          decaf::lang::exceptions::InterruptedException ) {
+
     ConditionImpl::wait( this->properties->condition.get() );
 }
 
 ////////////////////////////////////////////////////////////////////////////////
-void Mutex::wait( long long millisecs ) throw( lang::Exception ) {
+void Mutex::wait( long long millisecs )
+    throw( decaf::lang::exceptions::RuntimeException,
+           decaf::lang::exceptions::IllegalMonitorStateException,
+           decaf::lang::exceptions::InterruptedException ) {
+
     wait( millisecs, 0 );
 }
 
 ////////////////////////////////////////////////////////////////////////////////
-void Mutex::wait( long long millisecs, int nanos DECAF_UNUSED ) throw( lang::Exception ) {
+void Mutex::wait( long long millisecs, int nanos )
+    throw( decaf::lang::exceptions::RuntimeException,
+           decaf::lang::exceptions::IllegalArgumentException,
+           decaf::lang::exceptions::IllegalMonitorStateException,
+           decaf::lang::exceptions::InterruptedException ) {
 
     ConditionImpl::wait( this->properties->condition.get(), millisecs, nanos );
 }
 
 ////////////////////////////////////////////////////////////////////////////////
-void Mutex::notify() throw( lang::Exception ) {
+void Mutex::notify() throw( decaf::lang::exceptions::RuntimeException,
+                            decaf::lang::exceptions::IllegalMonitorStateException ) {
+
     ConditionImpl::notify( this->properties->condition.get() );
 }
 
 ////////////////////////////////////////////////////////////////////////////////
-void Mutex::notifyAll() throw( lang::Exception ) {
+void Mutex::notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                               decaf::lang::exceptions::IllegalMonitorStateException ) {
+
     ConditionImpl::notifyAll( this->properties->condition.get() );
 }

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/Mutex.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/Mutex.h?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/Mutex.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/Mutex.h Fri Sep 18 18:14:04 2009
@@ -54,21 +54,32 @@
 
         virtual ~Mutex();
 
-        virtual void lock() throw( lang::Exception );
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException );
 
-        virtual bool tryLock() throw( lang::Exception );
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException );
 
-        virtual void unlock() throw( lang::Exception );
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException );
 
-        virtual void wait() throw( lang::Exception );
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException );
 
-        virtual void wait( long long millisecs ) throw( lang::Exception );
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException );
 
-        virtual void wait( long long millisecs, int nanos ) throw( lang::Exception );
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException );
 
-        virtual void notify() throw( lang::Exception );
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException );
 
-        virtual void notifyAll() throw( lang::Exception );
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException );
 
     };
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/Synchronizable.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/Synchronizable.h?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/Synchronizable.h (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/util/concurrent/Synchronizable.h Fri Sep 18 18:14:04 2009
@@ -18,7 +18,10 @@
 #ifndef _DECAF_UTIL_CONCURRENT_SYNCHRONIZABLE_H_
 #define _DECAF_UTIL_CONCURRENT_SYNCHRONIZABLE_H_
 
-#include <decaf/lang/Exception.h>
+#include <decaf/lang/exceptions/RuntimeException.h>
+#include <decaf/lang/exceptions/InterruptedException.h>
+#include <decaf/lang/exceptions/IllegalArgumentException.h>
+#include <decaf/lang/exceptions/IllegalMonitorStateException.h>
 #include <decaf/util/Config.h>
 
 namespace decaf{
@@ -38,33 +41,41 @@
 
         /**
          * Locks the object.
-         * @throws Exception
+         *
+         * @throws RuntimeException if an error occurs while locking the object.
          */
-        virtual void lock() throw( lang::Exception ) = 0;
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) = 0;
 
         /**
          * Attempts to Lock the object, if the lock is already held by another
          * thread than this method returns false.
          *
-         * @return true if the lock was acquired, false if it is already held by another thread.
-         * @throws Exception
+         * @return true if the lock was acquired, false if it is already held by
+         *         another thread.
+         *
+         * @throws RuntimeException if an error occurs while locking the object.
          */
-        virtual bool tryLock() throw( lang::Exception ) = 0;
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) = 0;
 
         /**
          * Unlocks the object.
-         * @throws Exception
+         * @throws RuntimeException if an error occurs while unlocking the object.
          */
-        virtual void unlock() throw( lang::Exception ) = 0;
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) = 0;
 
         /**
          * Waits on a signal from this object, which is generated
          * by a call to Notify.  Must have this object locked before
          * calling.
          *
-         * @throws Exception
-         */
-        virtual void wait() throw( lang::Exception ) = 0;
+         * @throws RuntimeException if an error occurs while waiting on the object.
+         * @throws InterruptedException if the wait is interrupted before it completes.
+         * @throws IllegalMonitorStateException - if the current thread is not the owner of the
+         *         the Synchronizable Object.
+         */
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) = 0;
 
         /**
          * Waits on a signal from this object, which is generated
@@ -75,9 +86,15 @@
          * @param millisecs
          *      the time in milliseconds to wait, or WAIT_INIFINITE
          *
-         * @throws Exception
-         */
-        virtual void wait( long long millisecs ) throw( lang::Exception ) = 0;
+         * @throws RuntimeException if an error occurs while waiting on the object.
+         * @throws InterruptedException if the wait is interrupted before it completes.
+         * @throws IllegalMonitorStateException - if the current thread is not the owner of the
+         *         the Synchronizable Object.
+         */
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) = 0;
 
         /**
          * Waits on a signal from this object, which is generated by a call to Notify.
@@ -95,28 +112,42 @@
          * @param nanos
          *      additional time in nanoseconds with a range of 0-999999
          *
-         * @throws Exception if an error occurs or the nanos argument is not in the range of
-         *         0-999999
-         */
-        virtual void wait( long long millisecs, int nanos ) throw( lang::Exception ) = 0;
+         * @throws IllegalArgumentException if an error occurs or the nanos argument is not in
+         *         the range of [0-999999]
+         * @throws RuntimeException if an error occurs while waiting on the object.
+         * @throws InterruptedException if the wait is interrupted before it completes.
+         * @throws IllegalMonitorStateException - if the current thread is not the owner of the
+         *         the Synchronizable Object.
+         */
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) = 0;
 
         /**
          * Signals a waiter on this object that it can now wake
          * up and continue.  Must have this object locked before
          * calling.
          *
-         * @throws Exception
+         * @throws IllegalMonitorStateException - if the current thread is not the owner of the
+         *         the Synchronizable Object.
+         * @throws RuntimeException if an error occurs while notifying one of the waiting threads.
          */
-        virtual void notify() throw( lang::Exception ) = 0;
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) = 0;
 
         /**
          * Signals the waiters on this object that it can now wake
          * up and continue.  Must have this object locked before
          * calling.
          *
-         * @throws Exception
+         * @throws IllegalMonitorStateException - if the current thread is not the owner of the
+         *         the Synchronizable Object.
+         * @throws RuntimeException if an error occurs while notifying the waiting threads.
          */
-        virtual void notifyAll() throw( lang::Exception ) = 0;
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) = 0;
 
     };
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/io/BufferedInputStreamTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/io/BufferedInputStreamTest.cpp?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/io/BufferedInputStreamTest.cpp (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/io/BufferedInputStreamTest.cpp Fri Sep 18 18:14:04 2009
@@ -137,22 +137,39 @@
 
         virtual bool markSupported() const{ return false; }
 
-        virtual void lock() throw( lang::Exception ) {
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
         }
-        virtual bool tryLock() throw( lang::Exception ) {
-            return false;
+
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
         }
-        virtual void unlock() throw( lang::Exception ) {
+
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
         }
-        virtual void wait() throw( lang::Exception ) {
+
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) {
         }
-        virtual void wait( long long millisecs DECAF_UNUSED ) throw( lang::Exception ) {
+
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
         }
-        virtual void wait( long long millisecs DECAF_UNUSED, int nanos DECAF_UNUSED ) throw( lang::Exception ) {
+
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
         }
-        virtual void notify() throw( lang::Exception ) {
+
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) {
         }
-        virtual void notifyAll() throw( lang::Exception ) {
+
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
         }
 
     };

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/io/BufferedOutputStreamTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/io/BufferedOutputStreamTest.cpp?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/io/BufferedOutputStreamTest.cpp (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/io/BufferedOutputStreamTest.cpp Fri Sep 18 18:14:04 2009
@@ -81,22 +81,39 @@
             // do nothing.
         }
 
-        virtual void lock() throw( lang::Exception ) {
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
         }
-        virtual bool tryLock() throw( lang::Exception ) {
-            return false;
+
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
         }
-        virtual void unlock() throw( lang::Exception ) {
+
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
         }
-        virtual void wait() throw( lang::Exception ) {
+
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) {
         }
-        virtual void wait( long long millisecs DECAF_UNUSED ) throw( lang::Exception ) {
+
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
         }
-        virtual void wait( long long millisecs DECAF_UNUSED, int nanos DECAF_UNUSED ) throw( lang::Exception ) {
+
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
         }
-        virtual void notify() throw( lang::Exception ) {
+
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) {
         }
-        virtual void notifyAll() throw( lang::Exception ) {
+
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
         }
     };
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/io/FilterInputStreamTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/io/FilterInputStreamTest.cpp?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/io/FilterInputStreamTest.cpp (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/io/FilterInputStreamTest.cpp Fri Sep 18 18:14:04 2009
@@ -127,22 +127,39 @@
 
         virtual bool markSupported() const{ return false; }
 
-        virtual void lock() throw( lang::Exception ) {
+        virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
         }
-        virtual bool tryLock() throw( lang::Exception ) {
-            return false;
+
+        virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
         }
-        virtual void unlock() throw( lang::Exception ) {
+
+        virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
         }
-        virtual void wait() throw( lang::Exception ) {
+
+        virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                                   decaf::lang::exceptions::IllegalMonitorStateException,
+                                   decaf::lang::exceptions::InterruptedException ) {
         }
-        virtual void wait( long long millisecs DECAF_UNUSED ) throw( lang::Exception ) {
+
+        virtual void wait( long long millisecs )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
         }
-        virtual void wait( long long millisecs DECAF_UNUSED, int nanos DECAF_UNUSED ) throw( lang::Exception ) {
+
+        virtual void wait( long long millisecs, int nanos )
+            throw( decaf::lang::exceptions::RuntimeException,
+                   decaf::lang::exceptions::IllegalArgumentException,
+                   decaf::lang::exceptions::IllegalMonitorStateException,
+                   decaf::lang::exceptions::InterruptedException ) {
         }
-        virtual void notify() throw( lang::Exception ) {
+
+        virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                     decaf::lang::exceptions::IllegalMonitorStateException ) {
         }
-        virtual void notifyAll() throw( lang::Exception ) {
+
+        virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                        decaf::lang::exceptions::IllegalMonitorStateException ) {
         }
     };
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/util/StlMapTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/util/StlMapTest.cpp?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/util/StlMapTest.cpp (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/util/StlMapTest.cpp Fri Sep 18 18:14:04 2009
@@ -251,35 +251,51 @@
 
 public:
 
-    virtual void lock() throw( lang::Exception ) {
+    virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
         mutex.lock();
     }
 
-    virtual bool tryLock() throw( lang::Exception ) {
+    virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
         return mutex.tryLock();
     }
 
-    virtual void unlock() throw( lang::Exception ) {
+    virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
         mutex.unlock();
     }
 
-    virtual void wait() throw( lang::Exception ) {
+    virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                               decaf::lang::exceptions::IllegalMonitorStateException,
+                               decaf::lang::exceptions::InterruptedException ) {
+
         mutex.wait();
     }
 
-    virtual void wait( long long millisecs ) throw( lang::Exception ) {
+    virtual void wait( long long millisecs )
+        throw( decaf::lang::exceptions::RuntimeException,
+               decaf::lang::exceptions::IllegalMonitorStateException,
+               decaf::lang::exceptions::InterruptedException ) {
+
         mutex.wait( millisecs );
     }
 
-    virtual void wait( long long millisecs, int nanos ) throw( lang::Exception ) {
+    virtual void wait( long long millisecs, int nanos )
+        throw( decaf::lang::exceptions::RuntimeException,
+               decaf::lang::exceptions::IllegalArgumentException,
+               decaf::lang::exceptions::IllegalMonitorStateException,
+               decaf::lang::exceptions::InterruptedException ) {
+
         mutex.wait( millisecs, nanos );
     }
 
-    virtual void notify() throw( lang::Exception ) {
+    virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                 decaf::lang::exceptions::IllegalMonitorStateException ) {
+
         mutex.notify();
     }
 
-    virtual void notifyAll() throw( lang::Exception ) {
+    virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                    decaf::lang::exceptions::IllegalMonitorStateException ) {
+
         mutex.notifyAll();
     }
 

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/util/concurrent/MutexTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/util/concurrent/MutexTest.cpp?rev=816733&r1=816732&r2=816733&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/util/concurrent/MutexTest.cpp (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/util/concurrent/MutexTest.cpp Fri Sep 18 18:14:04 2009
@@ -23,6 +23,8 @@
 #include <decaf/util/concurrent/Mutex.h>
 #include <decaf/util/Random.h>
 
+#include <decaf/internal/util/concurrent/SynchronizableImpl.h>
+
 #include <time.h>
 
 using namespace std;
@@ -30,6 +32,7 @@
 using namespace decaf::lang;
 using namespace decaf::util;
 using namespace decaf::util::concurrent;
+using namespace decaf::internal::util::concurrent;
 
 ///////////////////////////////////////////////////////////////////////////////
 void MutexTest::testConstructor() {
@@ -45,42 +48,13 @@
 }
 
 ///////////////////////////////////////////////////////////////////////////////
-class MyThread : public lang::Thread, public Synchronizable{
-private:
-
-    Mutex mutex;
-
+class MyThread : public lang::Thread, public SynchronizableImpl{
 public:
 
     volatile int value;
     MyThread(){ value = 0;}
     virtual ~MyThread(){}
 
-    virtual void lock() throw(lang::Exception){
-        mutex.lock();
-    }
-    virtual bool tryLock() throw( lang::Exception ) {
-        return mutex.tryLock();
-    }
-    virtual void unlock() throw(lang::Exception){
-        mutex.unlock();
-    }
-    virtual void wait() throw(lang::Exception){
-        mutex.wait();
-    }
-    virtual void wait( long long millisecs ) throw(lang::Exception){
-        mutex.wait( millisecs );
-    }
-    virtual void wait( long long millisecs, int nanos ) throw(lang::Exception){
-        mutex.wait( millisecs, nanos );
-    }
-    virtual void notify() throw(lang::Exception){
-        mutex.notify();
-    }
-    virtual void notifyAll() throw(lang::Exception){
-        mutex.notifyAll();
-    }
-
     virtual void run(){
         {
             Lock lock (this);
@@ -110,41 +84,13 @@
 }
 
 ///////////////////////////////////////////////////////////////////////////////
-class MyWaitingThread : public lang::Thread, public Synchronizable{
-private:
-
-    Mutex mutex;
-
+class MyWaitingThread : public lang::Thread, public SynchronizableImpl{
 public:
 
     volatile int value;
     volatile bool started;
     MyWaitingThread(){ value = 0; started = false; }
     virtual ~MyWaitingThread(){}
-    virtual void lock() throw(lang::Exception){
-        mutex.lock();
-    }
-    virtual void unlock() throw(lang::Exception){
-        mutex.unlock();
-    }
-    virtual bool tryLock() throw( lang::Exception ) {
-        return mutex.tryLock();
-    }
-    virtual void wait() throw(lang::Exception){
-        mutex.wait();
-    }
-    virtual void wait(long long millisecs) throw(lang::Exception){
-        mutex.wait( millisecs );
-    }
-    virtual void wait( long long millisecs, int nanos ) throw(lang::Exception){
-        mutex.wait( millisecs, nanos );
-    }
-    virtual void notify() throw(lang::Exception){
-        mutex.notify();
-    }
-    virtual void notifyAll() throw(lang::Exception){
-        mutex.notifyAll();
-    }
 
     virtual void run(){
 
@@ -194,11 +140,7 @@
 }
 
 ///////////////////////////////////////////////////////////////////////////////
-class MyTimedWaitingThread : public lang::Thread, public Synchronizable{
-private:
-
-    Mutex mutex;
-
+class MyTimedWaitingThread : public lang::Thread, public SynchronizableImpl{
 public:
 
     volatile int value;
@@ -206,30 +148,6 @@
 
     MyTimedWaitingThread(){ value = 0; started = false; }
     virtual ~MyTimedWaitingThread(){}
-    virtual void lock() throw(lang::Exception){
-        mutex.lock();
-    }
-    virtual bool tryLock() throw( lang::Exception ) {
-        return mutex.tryLock();
-    }
-    virtual void unlock() throw(lang::Exception){
-        mutex.unlock();
-    }
-    virtual void wait() throw(lang::Exception){
-        mutex.wait();
-    }
-    virtual void wait(long long millisecs) throw(lang::Exception){
-        mutex.wait( millisecs );
-    }
-    virtual void wait( long long millisecs, int nanos ) throw(lang::Exception){
-        mutex.wait( millisecs, nanos );
-    }
-    virtual void notify() throw(lang::Exception){
-        mutex.notify();
-    }
-    virtual void notifyAll() throw(lang::Exception){
-        mutex.notifyAll();
-    }
 
     virtual void run(){
 
@@ -286,28 +204,52 @@
         this->done = false;
     }
     virtual ~MyNotifiedThread(){}
-    virtual void lock() throw(lang::Exception){
+
+    virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
         mutex->lock();
     }
-    virtual bool tryLock() throw( lang::Exception ) {
+
+    virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
         return mutex->tryLock();
     }
-    virtual void unlock() throw(lang::Exception){
+
+    virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
         mutex->unlock();
     }
-    virtual void wait() throw(lang::Exception){
+
+    virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                               decaf::lang::exceptions::IllegalMonitorStateException,
+                               decaf::lang::exceptions::InterruptedException ) {
+
         mutex->wait();
     }
-    virtual void wait(long long millisecs) throw(lang::Exception){
+
+    virtual void wait( long long millisecs )
+        throw( decaf::lang::exceptions::RuntimeException,
+               decaf::lang::exceptions::IllegalMonitorStateException,
+               decaf::lang::exceptions::InterruptedException ) {
+
         mutex->wait( millisecs );
     }
-    virtual void wait( long long millisecs, int nanos ) throw(lang::Exception){
+
+    virtual void wait( long long millisecs, int nanos )
+        throw( decaf::lang::exceptions::RuntimeException,
+               decaf::lang::exceptions::IllegalArgumentException,
+               decaf::lang::exceptions::IllegalMonitorStateException,
+               decaf::lang::exceptions::InterruptedException ) {
+
         mutex->wait( millisecs, nanos );
     }
-    virtual void notify() throw(lang::Exception){
+
+    virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                 decaf::lang::exceptions::IllegalMonitorStateException ) {
+
         mutex->notify();
     }
-    virtual void notifyAll() throw(lang::Exception){
+
+    virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                    decaf::lang::exceptions::IllegalMonitorStateException ) {
+
         mutex->notifyAll();
     }
 
@@ -510,28 +452,52 @@
         this->index = index;
     }
     virtual ~MyRecursiveLockThread(){}
-    virtual void lock() throw(lang::Exception){
+
+    virtual void lock() throw( decaf::lang::exceptions::RuntimeException ) {
         mutex->lock();
     }
-    virtual bool tryLock() throw( lang::Exception ) {
+
+    virtual bool tryLock() throw( decaf::lang::exceptions::RuntimeException ) {
         return mutex->tryLock();
     }
-    virtual void unlock() throw(lang::Exception){
+
+    virtual void unlock() throw( decaf::lang::exceptions::RuntimeException ) {
         mutex->unlock();
     }
-    virtual void wait() throw(lang::Exception){
+
+    virtual void wait() throw( decaf::lang::exceptions::RuntimeException,
+                               decaf::lang::exceptions::IllegalMonitorStateException,
+                               decaf::lang::exceptions::InterruptedException ) {
+
         mutex->wait();
     }
-    virtual void wait(long long millisecs) throw(lang::Exception){
+
+    virtual void wait( long long millisecs )
+        throw( decaf::lang::exceptions::RuntimeException,
+               decaf::lang::exceptions::IllegalMonitorStateException,
+               decaf::lang::exceptions::InterruptedException ) {
+
         mutex->wait( millisecs );
     }
-    virtual void wait( long long millisecs, int nanos ) throw(lang::Exception){
+
+    virtual void wait( long long millisecs, int nanos )
+        throw( decaf::lang::exceptions::RuntimeException,
+               decaf::lang::exceptions::IllegalArgumentException,
+               decaf::lang::exceptions::IllegalMonitorStateException,
+               decaf::lang::exceptions::InterruptedException ) {
+
         mutex->wait( millisecs, nanos );
     }
-    virtual void notify() throw(lang::Exception){
+
+    virtual void notify() throw( decaf::lang::exceptions::RuntimeException,
+                                 decaf::lang::exceptions::IllegalMonitorStateException ) {
+
         mutex->notify();
     }
-    virtual void notifyAll() throw(lang::Exception){
+
+    virtual void notifyAll() throw( decaf::lang::exceptions::RuntimeException,
+                                    decaf::lang::exceptions::IllegalMonitorStateException ) {
+
         mutex->notifyAll();
     }
 



Mime
View raw message