|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] How to achieve java format on generated code using xsl
Hi,
I am using xsl/xslt to generate java code. The problem I have is to make the output more readable.
Here is part of the code that I generate:
public void actionTcp (Coordinator c) throws Exception,
HwException,
SwException,
FailoverException;
I would rather see something like:
public void actionStartTpcInsertion(Coordinator c) throws Exception,
HwException,
SwException,
FailoverException;
( If it does not show up in the mail, I mean all Execptions below each other in a straight line.)
How can I make sure that they begin under Exception and in a straight line?
This is the xsl that I am using:
<xsl:when test="returnType/void">
public void action<xsl:call-template name="CapFirstLetterOfAttr">
<xsl:with-param name="x" select="@name"/></xsl:call-template>(Coordinator c) throws MoAccessException<xsl:if test="raisesException">
<xsl:text>,</xsl:text></xsl:if><xsl:text>
</xsl:text><xsl:for-each select="raisesException"><xsl:value-of select="@name"/>
<xsl:if test="not(position()=last())">,<xsl:text>
</xsl:text> </xsl:if></xsl:for-each>;
</xsl:when>
All hints are greatly appreciated!! Does anyone of you ( somewhere out there......) have any experience with code generation? I am willing to share my experience.
Regards,
//Mikael
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








