Details
-
Type:
New Feature
-
Status:
Open
-
Priority:
Minor
-
Resolution: Unresolved
-
Affects Version/s: None
-
Fix Version/s: None
-
Component/s: None
-
Labels:None
-
Environment:MAVEN 1.0 RC1
-
Number of attachments :
Description
I tried to automatically generate a repport from a castor schema by using the castor plugin. I think, it can be quite interesting to automatically generate an HTML page containing all the descriptions of the castor configuration file and also an SVG document representing the configuration tree.
I tried to implement this feature ... I know this is still a draft!
<goal name="castor:doc"> ${systemScope.setProperty('javax.xml.transform.TransformerFactory','org.apache.xalan.processor.TransformerFactoryImpl')}
<ant:xslt
in="${maven.castor.schema.file}"
out="${maven.castor.doc.file}"
style="${maven.castor.transformer}">
<ant:classpath>
<ant:path refid="maven.dependency.classpath"/>
<ant:pathelement location="${tools.jar}"/>
</ant:classpath>
</ant:xslt>
</goal>
maven.castor.doc.dir = ${maven.build.dir}/docs/schema maven.castor.schema.file = ${maven.src.dir}/schema/project-conf.xsd
maven.castor.transformer = ${maven.src.dir}/schema/xsd2html.xsl
maven.castor.doc.file = ${maven.castor.doc.dir}/conf.html
- I create a new goal in the plugin.jelly file:
<goal name="castor:doc"> ${systemScope.setProperty('javax.xml.transform.TransformerFactory','org.apache.xalan.processor.TransformerFactoryImpl')} <ant:xslt in="${maven.castor.schema.file}" out="${maven.castor.doc.file}" style="${maven.castor.transformer}"> <ant:classpath> <ant:path refid="maven.dependency.classpath"/> <ant:pathelement location="${tools.jar}"/> </ant:classpath> </ant:xslt> </goal>- Some new properties
maven.castor.doc.dir = ${maven.build.dir}/docs/schema maven.castor.schema.file = ${maven.src.dir}/schema/project-conf.xsd maven.castor.transformer = ${maven.src.dir}/schema/xsd2html.xsl maven.castor.doc.file = ${maven.castor.doc.dir}/conf.html