From 9ebd8a5bd4dd60e5983cfa998fea1c78fdb87401 Mon Sep 17 00:00:00 2001 From: "Rafael H. Schloming" Date: Mon, 13 Oct 2008 16:07:01 +0000 Subject: QPID-1339: - Removed the Channel class in order to simplify the state management surrounding Sessions and Connections. - Consolidated the ChannelDelegate into the ConnectionDelegate. - Modified MethodDelegate to invoke a generic handle method as the default action for each dispatched method. - Modified the code generator to produce a separate ConnectionInvoker and SessionInvoker. - Modified the invoker template to use package level visibility for all controls rather than public visibility. git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk@704147 13f79535-47bb-0310-9956-ffa450edef68 --- qpid/java/common/codegen | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'qpid/java/common/codegen') diff --git a/qpid/java/common/codegen b/qpid/java/common/codegen index 6cd51565ea..81c308d4c9 100755 --- a/qpid/java/common/codegen +++ b/qpid/java/common/codegen @@ -43,14 +43,20 @@ controls = spec.query["amqp/class/control", excludes] commands = spec.query["amqp/class/command", excludes] composites = structs + controls + commands +actions = controls + commands +connection = [c for c in actions if c.parent["@name"] == "connection"] +session = [c for c in actions if c.parent["@name"] != "connection"] for c in composites: name = cname(c) execute("%s.java" % name, "Composite.tpl", type = c, name = name) -execute("MethodDelegate.java", "MethodDelegate.tpl", composites = composites) +execute("MethodDelegate.java", "MethodDelegate.tpl", composites = actions) execute("Option.java", "Option.tpl", composites = composites) -execute("Invoker.java", "Invoker.tpl", composites = controls + commands) +execute("ConnectionInvoker.java", "Invoker.tpl", invoker = "ConnectionInvoker", + composites = connection) +execute("SessionInvoker.java", "Invoker.tpl", invoker = "SessionInvoker", + composites = session) execute("StructFactory.java", "StructFactory.tpl", composites = composites) def is_enum(nd): -- cgit v1.2.1