JAXB也使编组过程更容易了。
解组从编组创建的XML文档。
Then it unmarshals the XML document created from the marshalling.
编组和解组对象和XML
清单8显示编组程序生成的json。
在运行时,使用jaxb库进行编组和反编组。
At runtime, JAXB libraries are used in marshalling and unmarshalling.
于是就可以在编组和解组的过程中使用jaxb库。
JAXB libraries are then used in the process of marshalling and unmarshalling.
清单1是应用程序用于执行编组和解组操作的配置文件。
Listing 1 is the configuration file that the application USES to perform the marshalling and unmarshalling.
清单12中的代码片段说明如何创建反编组器。
The code snippet in Listing 12 shows how the unmarshaller is created.
消费者将文档编组成请求,并通过网络发送给服务。
The consumer marshals the document in a request and sends it over a network to the service.
作为开发人员,您有两种选择:xml解析器或者编组组件。
As a developer, you have two options: an XML parser or a marshalling component.
编组组件内嵌有xml解析器,可以确信它们完全实现了语法。
Marshalling components embed an XML parser, so you can be sure that they implement the syntax fully.
这种排名方法可以通过一次简单的排序将信息分为相关的编组。
This approach to ranking allows for a simple first-pass sorting of information into relevant groups.
因此,您可以确保通过编组所生成的文档总是与所期望的结构相匹配。
Thus, you can ensure that the documents you generate through marshalling always match the expected structure.
下一篇文章,我将从类生成转移到解组和编组,并说明它是如何工作的。
In my next article, I'll move from class generation to unmarshalling and marshalling, and show you how those processes work.
因此,在进行编组的时候,需要将此零索引参数重命名为course。
So rename this zeroth index parameter to course when performing marshalling.
然后,需要在那些类之上放置一些编组代码,以便为前端提供一个访问层。
Then you need to put some marshalling code atop that to provide an access layer to the front end.
对于任何绑定中包含的每个类,它都添加了适当的数据编组或数据编出代码。
For each class included in any of the bindings it adds the appropriate marshalling or unmarshalling code.
编组(Marshalling)是把内存中的数据转化到存储媒介上的过程。
Marshalling is the process of converting data in memory to a storage medium.
要数据编组的对象必须是类的一个实例,该类是用绑定中的全局映射定义的。
The object to be marshalled must be an instance of a class that's defined with a global mapping in the binding.
通过定义服务组,我们可以以逻辑方式对服务编组,从而满足业务需求。
By defining the service group, we can logically group the services to match the business meaning.
霍雷斯说,企业界正组建越来越多的临时编组,其成员经常是来自世界各地。
Companies are putting together many more AD hoc teams often connected virtually around the world, notes Mr Joerres.
但是,一般而言每个绑定有四个方法(两个用于数据编组,两个用于数据编出)。
Four methods per binding (two for marshalling, two for unmarshalling) is about the average, though.
JAXB的有用特性之一是,在反编组操作过程中可以根据相关联的模式检验源数据。
A useful feature of JAXB is the ability to validate the source data against the associated schema as part of the unmarshalling operation.
清单7中的代码将DojoList(列表对象)的实例编组成JSON。
The code in Listing 7 marshals the instance of DojoList (list object) into JSON.
如同上述数据编出示例一样,该示例只是数据编组调用可以使用的几个变体中的一种。
As with the unmarshal example, this is just one of several variations that can be used for the marshal call.
构建远程调用(例如查找Home接口,构建编组程序(marshaller)等。)
Setting up a remote call (finding Home interface for example, setting up marshaller, etc.)
通过调用根级别节点的toString方法,这个框架可以轻松编组整个XML文档。
By calling the toString method of the root-level node, the framework can easily marshal the entire XML document.
日期被自动编组为6个范围,2个月一个范围,然后这些范围形成了分层结构的下一级别。
The dates have been automatically grouped into six two-month ranges, which then form the next level of the hierarchy.
一般而言,对于每个包含该类的数据编组或数据编出绑定,都会在被绑定类文件中添加一对方法。
In general, you get a pair of added methods in your bound class files for each marshalling or unmarshalling binding that includes that class.
JiBX使用的第二种上下文是数据编组上下文,用于在进行数据编组时编写XML文档。
JiBX USES a second type of context, the marshalling context, for writing an XML document when marshalling.
应用推荐