Author: jgomes
Date: Tue Dec  9 10:53:33 2008
New Revision: 724821

URL: http://svn.apache.org/viewvc?rev=724821&view=rev
Log:
Add support in ISession to delete destinations, both temporary and standard.  
This allows for deterministic deletion of destinations without having to close 
a connection to get temporary destinations to be deleted.
Fixes [AMQNET-129] and AMQNET-129].
(See https://issues.apache.org/activemq/browse/AMQNET-129)
(See https://issues.apache.org/activemq/browse/AMQNET-123)

Modified:
    activemq/activemq-dotnet/Apache.NMS.MSMQ/trunk/src/main/csharp/Session.cs

Modified: 
activemq/activemq-dotnet/Apache.NMS.MSMQ/trunk/src/main/csharp/Session.cs
URL: 
http://svn.apache.org/viewvc/activemq/activemq-dotnet/Apache.NMS.MSMQ/trunk/src/main/csharp/Session.cs?rev=724821&r1=724820&r2=724821&view=diff
==============================================================================
--- activemq/activemq-dotnet/Apache.NMS.MSMQ/trunk/src/main/csharp/Session.cs 
(original)
+++ activemq/activemq-dotnet/Apache.NMS.MSMQ/trunk/src/main/csharp/Session.cs 
Tue Dec  9 10:53:33 2008
@@ -73,7 +73,7 @@
                {
                        if(selector != null)
                        {
-                               throw new NotImplementedException("Selectors 
are not supported by MSMQ");
+                               throw new NotSupportedException("Selectors are 
not supported by MSMQ");
                        }
                        MessageQueue queue = 
MessageConverter.ToMsmqDestination(destination);
                        return new MessageConsumer(this, acknowledgementMode, 
queue);
@@ -81,12 +81,12 @@
 
                public IMessageConsumer CreateDurableConsumer(ITopic 
destination, string name, string selector, bool noLocal)
                {
-                       throw new NotImplementedException("Durable Topic 
subscribers are not supported by MSMQ");
+                       throw new NotSupportedException("Durable Topic 
subscribers are not supported by MSMQ");
                }
 
                public void DeleteDurableConsumer(string name)
                {
-                       throw new NotImplementedException("Durable Topic 
subscribers are not supported by MSMQ");
+                       throw new NotSupportedException("Durable Topic 
subscribers are not supported by MSMQ");
                }
 
                public IQueue GetQueue(string name)
@@ -96,19 +96,28 @@
                
                public ITopic GetTopic(string name)
                {
-                       throw new NotImplementedException("Topics are not 
supported by MSMQ");
+                       throw new NotSupportedException("Topics are not 
supported by MSMQ");
                }
                
                public ITemporaryQueue CreateTemporaryQueue()
                {
-                       throw new NotImplementedException("Tempoary Queues are 
not supported by MSMQ");
+                       throw new NotSupportedException("Tempoary Queues are 
not supported by MSMQ");
                }
                
                public ITemporaryTopic CreateTemporaryTopic()
                {
-                       throw new NotImplementedException("Tempoary Topics are 
not supported by MSMQ");
+                       throw new NotSupportedException("Tempoary Topics are 
not supported by MSMQ");
                }
-               
+
+               /// <summary>
+               /// Delete a destination (Queue, Topic, Temp Queue, Temp Topic).
+               /// </summary>
+               public void DeleteDestination(IDestination destination)
+               {
+                       // TODO: Implement if possible.  If not possible, then 
change exception to NotSupportedException().
+                       throw new NotImplementedException();
+               }
+
                public IMessage CreateMessage()
                {
                        BaseMessage answer = new BaseMessage();


Reply via email to