站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > JBoss 4.0.1 sp1 varia API Documentation 英文版文档

JarTransformer (Various API) - JBoss 4.0.1 sp1 varia API Documentation 英文版文档


org.jboss.varia.deployment.convertor
Class JarTransformer

java.lang.Object
  extended byorg.jboss.varia.deployment.convertor.JarTransformer

public class JarTransformer
extends Object

JarTransformer is used to transform passed in jar file. Transformation algorithm: 1. open JarInputStream on passed in Jar file, open JarOutputStream for result; 2. read next Jar entry; 3. check whether Jar entry is an XML file - if it's not, copy Jar entry to result and go to step 2. 4. check whether there is an XSL file with name equal to XML file's in classpath. - if there isn't, copy Jar entry to result and go to step 2. 5. check whether there is a properties file with the name equal to XML file's name + "-output.properties" 6. set needed xsl parameters 7. transform Jar entry with xsl template and output properties (if were found) 8. check whether there is a property "newname" in output properties - if there is, write transformed entry to result with the value of "newname"; - otherwise write transformed entry to result with the original Jar entry name

Author:
Alex Loubyansky

Constructor Summary
JarTransformer()
           
 
Method Summary
static void transform(File root, Properties globalXslParams)
          Applies transformations to xml sources for passed in jar file
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JarTransformer

public JarTransformer()
Method Detail

transform

public static void transform(File root,
                             Properties globalXslParams)
                      throws Exception
Applies transformations to xml sources for passed in jar file

Throws:
Exception


Copyright © 2002 JBoss Group, LLC. All Rights Reserved.