Java XML工具包 nala

码农软件 · 软件分类 · XML相关工具 · 2019-09-17 16:42:19

软件介绍

Nala 是一个基于Java的XML对象绑定工具,支持将Java对象序列化为XML或者将XML绑定在Java对象上

  • 支持Map/注释信息的Java对象/命名约束的Java对象与XML之间的绑定

  • 支持Cdata对象的绑定和Xml作为文本进行绑定

  • 支持Xpath指定路径进行绑定

安装方法:

<dependency>
    <groupId>org.pinae</groupId>
    <artifactId>nala</artifactId>
    <version>1.6</version>
</dependency>

示例代码:

public class DemoTestManager {
    public static void main(String arg[]) throws Exception {
        try {
            StringBuffer xml = new ResourceReader().readFile("test.xml");
            //Parse XML to Object
            Map map = Xml.toMap(xml.toString(), "utf8");
            //convert Object to XML 
            String xml = Xml.toXML(map, "utf8", true);
        } catch (IOException e) {

        }
    }
}

本文地址:https://codercto.com/soft/d/14807.html

The Book of CSS3

The Book of CSS3

Peter Gasston / No Starch Press / 2011-5-13 / USD 34.95

CSS3 is the technology behind most of the eye-catching visuals on the Web today, but the official documentation can be dry and hard to follow. Luckily, The Book of CSS3 distills the heady technical la......一起来看看 《The Book of CSS3》 这本书的介绍吧!

JS 压缩/解压工具
JS 压缩/解压工具

在线压缩/解压 JS 代码

HEX CMYK 转换工具
HEX CMYK 转换工具

HEX CMYK 互转工具

HSV CMYK 转换工具
HSV CMYK 转换工具

HSV CMYK互换工具