diff options
| author | Jonathan Robie <jonathan@apache.org> | 2010-09-14 21:19:42 +0000 |
|---|---|---|
| committer | Jonathan Robie <jonathan@apache.org> | 2010-09-14 21:19:42 +0000 |
| commit | 43393128c074be68dab06b6097072e62546689de (patch) | |
| tree | 73d4c38213da9ea063b777afeb96a2c39388039f /cpp/examples/messaging/hello_world.cpp | |
| parent | 0b51c6b430224e3bfc09eede110ad8b1c530c213 (diff) | |
| download | qpid-python-43393128c074be68dab06b6097072e62546689de.tar.gz | |
Adds a parameter to several examples to allow connection options to be specified.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@997099 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/examples/messaging/hello_world.cpp')
| -rw-r--r-- | cpp/examples/messaging/hello_world.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/cpp/examples/messaging/hello_world.cpp b/cpp/examples/messaging/hello_world.cpp index 9c06964a66..8aef57d5d0 100644 --- a/cpp/examples/messaging/hello_world.cpp +++ b/cpp/examples/messaging/hello_world.cpp @@ -11,7 +11,9 @@ using namespace qpid::messaging; int main(int argc, char** argv) { std::string broker = argc > 1 ? argv[1] : "localhost:5672"; std::string address = argc > 2 ? argv[2] : "amq.topic"; - Connection connection(broker); + std::string connectionOptions = argc > 3 ? argv[3] : ""; + + Connection connection(broker, connectionOptions); try { connection.open(); Session session = connection.createSession(); |
