-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to generate the HTML from XSD #27
Comments
Do you get the same error with another XSLT compiler, such as libxslt? |
Have not tried that. Though I used the online tool what you have, that
works fine and I am able to generate the HTML.
…On Fri, Jul 12, 2019, 3:07 PM Michiel Meulendijk ***@***.***> wrote:
Do you get the same error with another XSLT compiler, such as libxslt?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#27?email_source=notifications&email_token=AASORSIRBCUCKZLYPXTY5RLP7BGDXA5CNFSM4ICFG4UKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODZZILUA#issuecomment-510821840>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AASORSKKGKHWDPCPBSWQVWDP7BGDXANCNFSM4ICFG4UA>
.
|
But I want to make this work as part of my build process and need make this
work either by Java/shell script.
On Fri, Jul 12, 2019, 3:25 PM Akhil khandelwal <[email protected]>
wrote:
… Have not tried that. Though I used the online tool what you have, that
works fine and I am able to generate the HTML.
On Fri, Jul 12, 2019, 3:07 PM Michiel Meulendijk ***@***.***>
wrote:
> Do you get the same error with another XSLT compiler, such as libxslt?
>
> —
> You are receiving this because you authored the thread.
> Reply to this email directly, view it on GitHub
> <#27?email_source=notifications&email_token=AASORSIRBCUCKZLYPXTY5RLP7BGDXA5CNFSM4ICFG4UKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODZZILUA#issuecomment-510821840>,
> or mute the thread
> <https://github.com/notifications/unsubscribe-auth/AASORSKKGKHWDPCPBSWQVWDP7BGDXANCNFSM4ICFG4UA>
> .
>
|
If you have a script/program which can be called from command line and if
you do not mind it sharing, Please share.
I need to automate the generation process.
Regards,
Akhil
On Fri, Jul 12, 2019 at 3:39 PM Akhil khandelwal <[email protected]>
wrote:
… But I want to make this work as part of my build process and need make
this work either by Java/shell script.
On Fri, Jul 12, 2019, 3:25 PM Akhil khandelwal ***@***.***>
wrote:
> Have not tried that. Though I used the online tool what you have, that
> works fine and I am able to generate the HTML.
>
> On Fri, Jul 12, 2019, 3:07 PM Michiel Meulendijk <
> ***@***.***> wrote:
>
>> Do you get the same error with another XSLT compiler, such as libxslt?
>>
>> —
>> You are receiving this because you authored the thread.
>> Reply to this email directly, view it on GitHub
>> <#27?email_source=notifications&email_token=AASORSIRBCUCKZLYPXTY5RLP7BGDXA5CNFSM4ICFG4UKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODZZILUA#issuecomment-510821840>,
>> or mute the thread
>> <https://github.com/notifications/unsubscribe-auth/AASORSKKGKHWDPCPBSWQVWDP7BGDXANCNFSM4ICFG4UA>
>> .
>>
>
--
Akhil Khandelwal
Mobile-9008602942
|
Just use libxslt. You can run it from the command line on Linux or Windows with a one-liner: xsltproc -o form.html xsd2html2xml.xsl dynamicui-definitions.xsd |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hello,
Thank you for wonderful library. I was trying to generate the HTML from one of my XSD.
Following is the java program which I wrote:
`public class XSLTransform
{
public static void main( String [] args ) throws Exception {
if ( args.length < 2 || !args[0].endsWith(".xsl") ) {
System.err.println("usage: XSLTransform file.xsl file.xml");
System.exit(1);
}
String xslFile = args[0], xmlFile = args[1];
}`
And I run this program as:
java XSLTransform xsd2html2xml.xsl dynamicui-definitions.xsd.
Output:
Compiler warnings:
file:///C:/xsd2html2xml-3.3/xsd2html2xml-3.3/utils/gui-attributes.xsl: line 413: Attribute 'step' outside of element.
file:///C:/xsd2html2xml-3.3/xsd2html2xml-3.3/utils/gui-attributes.xsl: line 424: Attribute 'step' outside of element.
file:///C:/xsd2html2xml-3.3/xsd2html2xml-3.3/utils/gui-attributes.xsl: line 435: Attribute 'step' outside of element.
file:///C:/xsd2html2xml-3.3/xsd2html2xml-3.3/handlers/default-types.xsl: line 135: Attribute 'data-xsd2html2xml-primitive' outside of element.
file:///C:/xsd2html2xml-3.3/xsd2html2xml-3.3/handlers/default-types.xsl: line 135: Attribute 'data-xsd2html2xml-primitive' outside of element.
file:///C:/xsd2html2xml-3.3/xsd2html2xml-3.3/handlers/default-types.xsl: line 139: Attribute 'data-xsd2html2xml-description' outside of element.
file:///C:/xsd2html2xml-3.3/xsd2html2xml-3.3/handlers/default-types.xsl: line 139: Attribute 'data-xsd2html2xml-description' outside of element.
file:///C:/xsd2html2xml-3.3/xsd2html2xml-3.3/xsd2html2xml.xsl: line 264: Attribute 'namespace' outside of element.
ERROR: 'Could not compile stylesheet'
FATAL ERROR: 'file:///C:/xsd2html2xml-3.3/xsd2html2xml-3.3/utils/namespaces.xsl: line 175: Second argument to document() function must be a node-set.'
:file:///C:/xsd2html2xml-3.3/xsd2html2xml-3.3/utils/namespaces.xsl: line 175: Second argument to document() function must be a node-set.
Exception in thread "main" javax.xml.transform.TransformerConfigurationException: file:///C:/xsd2html2xml-3.3/xsd2html2xml-3.3/utils/namespaces.xsl: line 175: Second argument to document() function must be a node-set.
at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl.newTemplates(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl.newTransformer(Unknown Source)
at XSLTransform.main(XSLTransform.java:16)
Caused by: file:///C:/xsd2html2xml-3.3/xsd2html2xml-3.3/utils/namespaces.xsl: line 175: Second argument to document() function must be a node-set.
at com.sun.org.apache.xalan.internal.xsltc.compiler.DocumentCall.typeCheck(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.CopyOf.typeCheck(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.SyntaxTreeNode.typeCheckContents(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.XslElement.typeCheck(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.SyntaxTreeNode.typeCheckContents(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.If.typeCheck(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.SyntaxTreeNode.typeCheckContents(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.ForEach.typeCheck(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.SyntaxTreeNode.typeCheckContents(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.Template.typeCheck(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.SyntaxTreeNode.typeCheckContents(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.Stylesheet.typeCheck(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.Parser.createAST(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.XSLTC.compile(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.XSLTC.compile(Unknown Source)
... 3 more
file:///C:/xsd2html2xml-3.3/xsd2html2xml-3.3/utils/namespaces.xsl: line 175: Second argument to document() function must be a node-set.
at com.sun.org.apache.xalan.internal.xsltc.compiler.DocumentCall.typeCheck(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.CopyOf.typeCheck(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.SyntaxTreeNode.typeCheckContents(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.XslElement.typeCheck(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.SyntaxTreeNode.typeCheckContents(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.If.typeCheck(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.SyntaxTreeNode.typeCheckContents(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.ForEach.typeCheck(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.SyntaxTreeNode.typeCheckContents(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.Template.typeCheck(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.SyntaxTreeNode.typeCheckContents(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.Stylesheet.typeCheck(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.Parser.createAST(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.XSLTC.compile(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.compiler.XSLTC.compile(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl.newTemplates(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl.newTransformer(Unknown Source)
at XSLTransform.main(XSLTransform.java:16)
The text was updated successfully, but these errors were encountered: