summaryrefslogtreecommitdiff
path: root/qpid/cpp/rubygen
diff options
context:
space:
mode:
authorGordon Sim <gsim@apache.org>2008-03-04 20:42:19 +0000
committerGordon Sim <gsim@apache.org>2008-03-04 20:42:19 +0000
commit848448ae4ea238c355fd8f591a7bab58e64c98c8 (patch)
tree2005909168f42e4bda15ab55e80fafa1b304ec49 /qpid/cpp/rubygen
parent47e9a55ae0e729ba7dc10c2800cfb14dc721675f (diff)
downloadqpid-python-848448ae4ea238c355fd8f591a7bab58e64c98c8.tar.gz
Further updates to support final 0-10 spec
git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk@633627 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/cpp/rubygen')
-rw-r--r--qpid/cpp/rubygen/99-0/Session.rb4
-rw-r--r--qpid/cpp/rubygen/99-0/structs.rb11
2 files changed, 8 insertions, 7 deletions
diff --git a/qpid/cpp/rubygen/99-0/Session.rb b/qpid/cpp/rubygen/99-0/Session.rb
index 5a6f061937..1ec78f6167 100644
--- a/qpid/cpp/rubygen/99-0/Session.rb
+++ b/qpid/cpp/rubygen/99-0/Session.rb
@@ -6,9 +6,9 @@ require 'cppgen'
class CppGen
def session_methods
- excludes = ["channel", "connection", "session", "execution", "connection010", "session010"]
+ excludes = ["channel", "connection", "session", "execution"]
gen_methods=@amqp.methods_on(@chassis).reject { |m|
- excludes.include? m.parent.name
+ excludes.include? m.parent.name or m.body_name.include?("010")
}
end
diff --git a/qpid/cpp/rubygen/99-0/structs.rb b/qpid/cpp/rubygen/99-0/structs.rb
index 4052befa2b..398ca660dd 100644
--- a/qpid/cpp/rubygen/99-0/structs.rb
+++ b/qpid/cpp/rubygen/99-0/structs.rb
@@ -39,7 +39,8 @@ class StructGen < CppGen
end
def execution_header?(s)
- false and s.kind_of? AmqpMethod and s.parent.l4?
+ #false and s.kind_of? AmqpMethod and s.parent.l4?
+ s.kind_of? AmqpMethod and s.parent.name.include?("010") and not s.parent.control?
end
def has_bitfields_only(s)
@@ -453,7 +454,7 @@ void #{classname}::encodeStructBody(Buffer& #{buffer}) const
{
EOS
if (execution_header?(s))
- genl "ModelMethod::encode(buffer);"
+ genl "encodeHeader(buffer);"
end
if (is_packed(s))
@@ -473,7 +474,7 @@ EOS
genl "buffer.put#{s.size.caps}(bodySize() + 2/*typecode*/);" if s.size
genl "buffer.putShort(TYPE);"
else
- genl "buffer.put#{s.size.caps}(size());" if s.size
+ genl "buffer.put#{s.size.caps}(bodySize());" if s.size
end
end
genl "encodeStructBody(buffer);"
@@ -485,7 +486,7 @@ void #{classname}::decodeStructBody(Buffer& #{buffer}, uint32_t /*size*/)
{
EOS
if (execution_header?(s))
- genl "ModelMethod::decode(buffer);"
+ genl "decodeHeader(buffer);"
end
if (is_packed(s))
@@ -514,7 +515,7 @@ uint32_t #{classname}::bodySize() const
uint32_t total = 0;
EOS
if (execution_header?(s))
- genl "total += ModelMethod::size();"
+ genl "total += headerSize();"
end
if (is_packed(s))