Java代码从XSD创建XML文件,没有任何POJO [英] Java Code to create XML file from XSD without any POJO

查看:113
本文介绍了Java代码从XSD创建XML文件,没有任何POJO的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我只想在不使用任何POJO的情况下仅使用XSD创建XML文件。我试图搜索解决方案,但大多数使用JAXB,这些都依赖于Classes和Marshaling。我想用XSD创建一个XML文件,我们不需要任何其他依赖项。

I just want to create XML file by only using XSD without using any POJO. I tried to search solutions, but most of them using JAXB those are dependent on Classes and Marshaling. I feel like to create an XML file with XSD we don't require any other dependencies.

推荐答案

我使用jlib为这个问题找到了最简单的解决方案。

I got the simplest solution for this problem using jlib.

https://github.com /elbuo8/Sample-XSD-to-XML-Batch-Generator/blob/master/Runner.java

这篇关于Java代码从XSD创建XML文件,没有任何POJO的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆