diff options
author | Gordon Sim <gsim@apache.org> | 2009-10-02 13:01:51 +0000 |
---|---|---|
committer | Gordon Sim <gsim@apache.org> | 2009-10-02 13:01:51 +0000 |
commit | ce1711c01904296aca0144da21d9dc1a800584a1 (patch) | |
tree | 3b4a91c52555aee97cf9bfe153071743be6e2539 /cpp/examples/messaging/queue_receiver.cpp | |
parent | 1f0072eb267205b47f04a782845586676edcbe80 (diff) | |
download | qpid-python-ce1711c01904296aca0144da21d9dc1a800584a1.tar.gz |
define content- and view- classes separately from message class
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@821000 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/examples/messaging/queue_receiver.cpp')
-rw-r--r-- | cpp/examples/messaging/queue_receiver.cpp | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/cpp/examples/messaging/queue_receiver.cpp b/cpp/examples/messaging/queue_receiver.cpp index 83a44b2ca9..40f863eb30 100644 --- a/cpp/examples/messaging/queue_receiver.cpp +++ b/cpp/examples/messaging/queue_receiver.cpp @@ -24,16 +24,10 @@ #include <qpid/messaging/Receiver.h> #include <qpid/messaging/Session.h> -#include <cstdlib> #include <iostream> -#include <sstream> - using namespace qpid::messaging; -using std::stringstream; -using std::string; - int main(int argc, char** argv) { const char* url = argc>1 ? argv[1] : "amqp:tcp:127.0.0.1:5672"; @@ -47,7 +41,7 @@ int main(int argc, char** argv) { Message message = receiver.fetch(); std::cout << "Message: " << message.getContent() << std::endl; session.acknowledge(); - if (message.getContent().asString() == "That's all, folks!") { + if (message.getContent() == "That's all, folks!") { std::cout << "Cancelling receiver" << std::endl; receiver.cancel(); break; |