summaryrefslogtreecommitdiff
path: root/qpid/cpp/common/framing/src/AMQFrame.cpp
diff options
context:
space:
mode:
authorAlan Conway <aconway@apache.org>2006-09-27 19:50:23 +0000
committerAlan Conway <aconway@apache.org>2006-09-27 19:50:23 +0000
commit3d9cd9a1f350c8970c6cd0da20d918b831342636 (patch)
tree18178234a4807121b06f35a78c23dc2a33076da5 /qpid/cpp/common/framing/src/AMQFrame.cpp
parentcb3fe168a5c4c0c91b5d32ff28b176d57c8eb870 (diff)
downloadqpid-python-3d9cd9a1f350c8970c6cd0da20d918b831342636.tar.gz
git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk@450556 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/cpp/common/framing/src/AMQFrame.cpp')
-rw-r--r--qpid/cpp/common/framing/src/AMQFrame.cpp18
1 files changed, 3 insertions, 15 deletions
diff --git a/qpid/cpp/common/framing/src/AMQFrame.cpp b/qpid/cpp/common/framing/src/AMQFrame.cpp
index 70f71010ff..5686c9ac81 100644
--- a/qpid/cpp/common/framing/src/AMQFrame.cpp
+++ b/qpid/cpp/common/framing/src/AMQFrame.cpp
@@ -1,3 +1,4 @@
+
/*
*
* Copyright (c) 2006 The Apache Software Foundation
@@ -126,21 +127,8 @@ void AMQFrame::decodeBody(Buffer& buffer, uint32_t size)
std::ostream& qpid::framing::operator<<(std::ostream& out, const AMQFrame& t){
out << "Frame[channel=" << t.channel << "; ";
- if(t.body.get() == 0){
- out << "empty";
- }else if(t.body->type() == METHOD_BODY){
- (dynamic_cast<AMQMethodBody*>(t.body.get()))->print(out);
- }else if(t.body->type() == HEADER_BODY){
- out << "header, content_size=" <<
- (dynamic_cast<AMQHeaderBody*>(t.body.get()))->getContentSize()
- << " (" << t.body->size() << " bytes)";
- }else if(t.body->type() == CONTENT_BODY){
- out << "content (" << t.body->size() << " bytes)";
- }else if(t.body->type() == HEARTBEAT_BODY){
- out << "heartbeat";
- }else{
- out << "unknown type, " << t.body->type();
- }
+ if (t.body.get() == 0) out << "empty";
+ else out << *t.body;
out << "]";
return out;
}