diff options
| author | Ted Ross <tross@apache.org> | 2010-06-09 11:59:38 +0000 |
|---|---|---|
| committer | Ted Ross <tross@apache.org> | 2010-06-09 11:59:38 +0000 |
| commit | 077b8b25ab7fac22daf8494feb125cd5c73b95ac (patch) | |
| tree | f0f2d8b17c7ef912d16d3110bc18790006bbd87a /cpp/bindings/qpid/dotnet/examples/csharp.map.sender | |
| parent | b6b344dccb18ed44500232e492573244b8a6bdf3 (diff) | |
| download | qpid-python-077b8b25ab7fac22daf8494feb125cd5c73b95ac.tar.gz | |
QPID-2589 Cleanup pass to address function naming, capitalization rules, change Qpid messaging 'list' representation from List<> to Collection<>,
some exception cleanup.
Patch from Chuck Rolke
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@952968 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/bindings/qpid/dotnet/examples/csharp.map.sender')
| -rw-r--r-- | cpp/bindings/qpid/dotnet/examples/csharp.map.sender/csharp.map.sender.cs | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/cpp/bindings/qpid/dotnet/examples/csharp.map.sender/csharp.map.sender.cs b/cpp/bindings/qpid/dotnet/examples/csharp.map.sender/csharp.map.sender.cs index 2890367599..d1ccc65f2c 100644 --- a/cpp/bindings/qpid/dotnet/examples/csharp.map.sender/csharp.map.sender.cs +++ b/cpp/bindings/qpid/dotnet/examples/csharp.map.sender/csharp.map.sender.cs @@ -21,11 +21,12 @@ using System;
using System.Collections.Generic;
+using System.Collections.ObjectModel;
using System.Linq;
using System.Text;
-using org.apache.qpid.messaging;
+using Org.Apache.Qpid.Messaging;
-namespace org.apache.qpid.messaging.examples
+namespace Org.Apache.Qpid.Messaging.examples
{
class MapSender
{
@@ -39,14 +40,14 @@ namespace org.apache.qpid.messaging.examples // Create and open an AMQP connection to the broker URL
//
Connection connection = new Connection(url);
- connection.open();
+ connection.Open();
//
// Create a session and a sender to the direct exchange using the
// routing key "map_example".
//
- Session session = connection.createSession();
- Sender sender = session.createSender("amq.direct/map_example");
+ Session session = connection.CreateSession();
+ Sender sender = session.CreateSender("amq.direct/map_example");
//
// Create structured content for the message. This example builds a
@@ -54,7 +55,7 @@ namespace org.apache.qpid.messaging.examples //
Dictionary<string, object> content = new Dictionary<string, object>();
Dictionary<string, object> subMap = new Dictionary<string, object>();
- List<object> colors = new List<object>();
+ Collection<object> colors = new Collection<object>();
content["id"] = 987654321;
content["name"] = "Widget";
@@ -76,12 +77,12 @@ namespace org.apache.qpid.messaging.examples // via the sender.
//
Message message = new Message(content);
- sender.send(message, true);
+ sender.Send(message, true);
//
// Close the connection.
//
- connection.close();
+ connection.Close();
}
}
}
|
