You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by ch...@apache.org on 2006/10/10 18:32:47 UTC

svn commit: r454812 - in /incubator/activemq/sandbox/qpid: build.xml stylesheets/command-java.xsl stylesheets/command.xsl stylesheets/framing.xsl stylesheets/java.xsl stylesheets/marshaller-java.xsl stylesheets/marshaller.xsl

Author: chirino
Date: Tue Oct 10 09:32:45 2006
New Revision: 454812

URL: http://svn.apache.org/viewvc?view=rev&rev=454812
Log:
split the xslt so that we generate a command package and then a version specific marshalling package.

Added:
    incubator/activemq/sandbox/qpid/stylesheets/command-java.xsl
      - copied, changed from r454797, incubator/activemq/sandbox/qpid/stylesheets/java.xsl
    incubator/activemq/sandbox/qpid/stylesheets/command.xsl
      - copied, changed from r454797, incubator/activemq/sandbox/qpid/stylesheets/framing.xsl
    incubator/activemq/sandbox/qpid/stylesheets/marshaller-java.xsl
      - copied, changed from r454797, incubator/activemq/sandbox/qpid/stylesheets/java.xsl
    incubator/activemq/sandbox/qpid/stylesheets/marshaller.xsl
      - copied, changed from r454797, incubator/activemq/sandbox/qpid/stylesheets/framing.xsl
Removed:
    incubator/activemq/sandbox/qpid/stylesheets/framing.xsl
    incubator/activemq/sandbox/qpid/stylesheets/java.xsl
Modified:
    incubator/activemq/sandbox/qpid/build.xml

Modified: incubator/activemq/sandbox/qpid/build.xml
URL: http://svn.apache.org/viewvc/incubator/activemq/sandbox/qpid/build.xml?view=diff&rev=454812&r1=454811&r2=454812
==============================================================================
--- incubator/activemq/sandbox/qpid/build.xml (original)
+++ incubator/activemq/sandbox/qpid/build.xml Tue Oct 10 09:32:45 2006
@@ -17,9 +17,8 @@
  -->
 <project name="AMQ Common" default="build">
 
-  <property name="stylesheet" value="stylesheets/framing.xsl"/>
-  <property name="generated.dir" value="${basedir}/src/main"/>
-  
+  <property name="target.src.dir" value="${basedir}/src/main"/>
+
   <macrodef name="saxon">
     <attribute name="out"/>
     <attribute name="src"/>
@@ -51,26 +50,36 @@
       <echo>Found AMQP specification file "${basedir}/specs/amqp-@{ver}.xml"; major=${@{ver}.amqp(major)} minor=${@{ver}.amqp(minor)}</echo>
 
       <!-- Create directory; generate from specification file -->
-      <mkdir dir="${generated.dir}/org/apache/activemq/qpid/command/v${@{ver}.amqp(major)}_${@{ver}.amqp(minor)}"/>
-      <saxon out="${generated.dir}/org/apache/activemq/qpid/command/v${@{ver}.amqp(major)}_${@{ver}.amqp(minor)}/results.out"
+      <mkdir dir="${target.src.dir}/org/apache/activemq/qpid/command"/>
+      <saxon out="${target.src.dir}/org/apache/activemq/qpid/command/results.out"
+             src="${basedir}/specs/amqp-@{ver}.xml" 
+             xsl="stylesheets/command.xsl">
+        <arg value="major=${@{ver}.amqp(major)}"/>
+        <arg value="minor=${@{ver}.amqp(minor)}"/>
+        <arg value="registry_name=MainRegistry"/>
+      </saxon>
+
+      <mkdir dir="${target.src.dir}/org/apache/activemq/qpid/marshaller/v${@{ver}.amqp(major)}_${@{ver}.amqp(minor)}"/>
+      <saxon out="${target.src.dir}/org/apache/activemq/qpid/marshaller/v${@{ver}.amqp(major)}_${@{ver}.amqp(minor)}/results.out"
              src="${basedir}/specs/amqp-@{ver}.xml" 
-             xsl="${stylesheet}">
+             xsl="stylesheets/marshaller.xsl">
         <arg value="major=${@{ver}.amqp(major)}"/>
         <arg value="minor=${@{ver}.amqp(minor)}"/>
         <arg value="registry_name=MainRegistry"/>
       </saxon>
+
       <!--
       <property name="cluster.asl" value="resources/cluster.asl"/>
       <property name="registry_template" value="resources/registry.template"/>
       <property name="registry_stylesheet" value="stylesheets/registry.xsl"/>
-      <saxon out="${generated.dir}/org/apache/activemq/qpid/command/v${@{ver}.amqp(major)}_${@{ver}.amqp(minor)}/cluster.out"
+      <saxon out="${target.src.dir}/org/apache/activemq/qpid/command/v${@{ver}.amqp(major)}_${@{ver}.amqp(minor)}/cluster.out"
              src="${cluster.asl}"
-             xsl="${stylesheet}">
+             xsl="stylesheets/framing.xsl">
         <arg value="major=${@{ver}.amqp(major)}"/>
         <arg value="minor=${@{ver}.amqp(minor)}"/>
         <arg value="registry_name=ClusterRegistry"/>
       </saxon>
-      <saxon out="${generated.dir}/org/apache/activemq/qpid/command/v${@{ver}.amqp(major)}_${@{ver}.amqp(minor)}/registry.out"
+      <saxon out="${target.src.dir}/org/apache/activemq/qpid/command/v${@{ver}.amqp(major)}_${@{ver}.amqp(minor)}/registry.out"
              src="${registry_template}"
              xsl="${registry_stylesheet}">
         <arg value="major=${@{ver}.amqp(major)}"/>

Copied: incubator/activemq/sandbox/qpid/stylesheets/command-java.xsl (from r454797, incubator/activemq/sandbox/qpid/stylesheets/java.xsl)
URL: http://svn.apache.org/viewvc/incubator/activemq/sandbox/qpid/stylesheets/command-java.xsl?view=diff&rev=454812&p1=incubator/activemq/sandbox/qpid/stylesheets/java.xsl&r1=454797&p2=incubator/activemq/sandbox/qpid/stylesheets/command-java.xsl&r2=454812
==============================================================================
--- incubator/activemq/sandbox/qpid/stylesheets/java.xsl (original)
+++ incubator/activemq/sandbox/qpid/stylesheets/command-java.xsl Tue Oct 10 09:32:45 2006
@@ -55,16 +55,7 @@
 <xsl:template name="generate-class"> 
     <xsl:param name="f"/>
     <xsl:value-of select="amq:copyright()"/>    
-<!-- package org.apache.qpid.framing_<xsl:value-of select="$major"/>_<xsl:value-of select="$minor"/>; -->
-package org.apache.qpid.framing;
-
-import org.apache.mina.common.ByteBuffer;
-import org.apache.qpid.framing.AMQFrame;
-import org.apache.qpid.framing.AMQFrameDecodingException;
-import org.apache.qpid.framing.AMQMethodBody;
-import org.apache.qpid.framing.EncodableAMQDataBlock;
-import org.apache.qpid.framing.EncodingUtils;
-import org.apache.qpid.framing.FieldTable;
+package org.apache.activemq.qpid.command;
 
 /**
  * This class is autogenerated, do not modify. [From <xsl:value-of select="$f/parent::frames/@protocol"/>]

Copied: incubator/activemq/sandbox/qpid/stylesheets/command.xsl (from r454797, incubator/activemq/sandbox/qpid/stylesheets/framing.xsl)
URL: http://svn.apache.org/viewvc/incubator/activemq/sandbox/qpid/stylesheets/command.xsl?view=diff&rev=454812&p1=incubator/activemq/sandbox/qpid/stylesheets/framing.xsl&r1=454797&p2=incubator/activemq/sandbox/qpid/stylesheets/command.xsl&r2=454812
==============================================================================
--- incubator/activemq/sandbox/qpid/stylesheets/framing.xsl (original)
+++ incubator/activemq/sandbox/qpid/stylesheets/command.xsl Tue Oct 10 09:32:45 2006
@@ -21,7 +21,7 @@
 <xsl:import href="prepare1.xsl"/>
 <xsl:import href="prepare2.xsl"/>
 <xsl:import href="prepare3.xsl"/>
-<xsl:import href="java.xsl"/>
+<xsl:import href="command-java.xsl"/>
 
 <xsl:output indent="yes"/> 
 <xsl:output method="text" indent="yes" name="textFormat"/> 

Copied: incubator/activemq/sandbox/qpid/stylesheets/marshaller-java.xsl (from r454797, incubator/activemq/sandbox/qpid/stylesheets/java.xsl)
URL: http://svn.apache.org/viewvc/incubator/activemq/sandbox/qpid/stylesheets/marshaller-java.xsl?view=diff&rev=454812&p1=incubator/activemq/sandbox/qpid/stylesheets/java.xsl&r1=454797&p2=incubator/activemq/sandbox/qpid/stylesheets/marshaller-java.xsl&r2=454812
==============================================================================
--- incubator/activemq/sandbox/qpid/stylesheets/java.xsl (original)
+++ incubator/activemq/sandbox/qpid/stylesheets/marshaller-java.xsl Tue Oct 10 09:32:45 2006
@@ -55,16 +55,10 @@
 <xsl:template name="generate-class"> 
     <xsl:param name="f"/>
     <xsl:value-of select="amq:copyright()"/>    
-<!-- package org.apache.qpid.framing_<xsl:value-of select="$major"/>_<xsl:value-of select="$minor"/>; -->
-package org.apache.qpid.framing;
+package org.apache.activemq.qpid.marshaller.v<xsl:value-of select="$major"/>_<xsl:value-of select="$minor"/>;
 
-import org.apache.mina.common.ByteBuffer;
-import org.apache.qpid.framing.AMQFrame;
-import org.apache.qpid.framing.AMQFrameDecodingException;
-import org.apache.qpid.framing.AMQMethodBody;
-import org.apache.qpid.framing.EncodableAMQDataBlock;
-import org.apache.qpid.framing.EncodingUtils;
-import org.apache.qpid.framing.FieldTable;
+import  org.apache.activemq.qpid.command.*;
+import  org.apache.activemq.qpid.marshaller.*;
 
 /**
  * This class is autogenerated, do not modify. [From <xsl:value-of select="$f/parent::frames/@protocol"/>]

Copied: incubator/activemq/sandbox/qpid/stylesheets/marshaller.xsl (from r454797, incubator/activemq/sandbox/qpid/stylesheets/framing.xsl)
URL: http://svn.apache.org/viewvc/incubator/activemq/sandbox/qpid/stylesheets/marshaller.xsl?view=diff&rev=454812&p1=incubator/activemq/sandbox/qpid/stylesheets/framing.xsl&r1=454797&p2=incubator/activemq/sandbox/qpid/stylesheets/marshaller.xsl&r2=454812
==============================================================================
--- incubator/activemq/sandbox/qpid/stylesheets/framing.xsl (original)
+++ incubator/activemq/sandbox/qpid/stylesheets/marshaller.xsl Tue Oct 10 09:32:45 2006
@@ -21,7 +21,7 @@
 <xsl:import href="prepare1.xsl"/>
 <xsl:import href="prepare2.xsl"/>
 <xsl:import href="prepare3.xsl"/>
-<xsl:import href="java.xsl"/>
+<xsl:import href="marshaller-java.xsl"/>
 
 <xsl:output indent="yes"/> 
 <xsl:output method="text" indent="yes" name="textFormat"/>