diff options
| author | Robert Greig <rgreig@apache.org> | 2007-01-10 12:50:37 +0000 |
|---|---|---|
| committer | Robert Greig <rgreig@apache.org> | 2007-01-10 12:50:37 +0000 |
| commit | 6512467ba70eaf3e2f4b09dc31ee9712d534542a (patch) | |
| tree | 47eb51f7a69e3f33424d80dccb170973a57f7605 | |
| parent | 36d6aa83cf155ce9877bf71f7e4c439245267da0 (diff) | |
| download | qpid-python-6512467ba70eaf3e2f4b09dc31ee9712d534542a.tar.gz | |
git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk@494801 13f79535-47bb-0310-9956-ffa450edef68
| -rw-r--r-- | qpid/dotnet/Qpid.Client/Client/AMQConnection.cs | 12 | ||||
| -rw-r--r-- | qpid/dotnet/Qpid.Client/Client/AmqChannel.cs | 8 |
2 files changed, 19 insertions, 1 deletions
diff --git a/qpid/dotnet/Qpid.Client/Client/AMQConnection.cs b/qpid/dotnet/Qpid.Client/Client/AMQConnection.cs index c620412cab..1da46f19fd 100644 --- a/qpid/dotnet/Qpid.Client/Client/AMQConnection.cs +++ b/qpid/dotnet/Qpid.Client/Client/AMQConnection.cs @@ -386,6 +386,7 @@ namespace Qpid.Client public void Start() { CheckNotClosed(); + if (!_started) { foreach (DictionaryEntry lde in _sessions) @@ -400,7 +401,16 @@ namespace Qpid.Client public void Stop() { CheckNotClosed(); - throw new NotImplementedException(); + + if (_started) + { + foreach (DictionaryEntry lde in _sessions) + { + AmqChannel s = (AmqChannel) lde.Value; + s.Stop(); + } + _started = false; + } } public IConnectionListener ConnectionListener diff --git a/qpid/dotnet/Qpid.Client/Client/AmqChannel.cs b/qpid/dotnet/Qpid.Client/Client/AmqChannel.cs index ab598b4b27..528fa96924 100644 --- a/qpid/dotnet/Qpid.Client/Client/AmqChannel.cs +++ b/qpid/dotnet/Qpid.Client/Client/AmqChannel.cs @@ -608,6 +608,14 @@ namespace Qpid.Client dispatcherThread.Start(); } + internal void Stop() + { + if (_dispatcher != null) + { + _dispatcher.StopDispatcher(); + } + } + internal void RegisterConsumer(string consumerTag, IMessageConsumer consumer) { _consumers[consumerTag] = consumer; |
