Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

ÓÃDom4J½âÎö´øÃüÃû¿Õ¼äµÄXMLÎļþ

Dom4JÊÇÒ»¸ö¿ªÔ´µÄÓÅÐãµÄXML½âÎöAPI£¬ÏÖÔÚÔ½À´Ô½¶àµÄÏîÄ¿ÖпªÊ¼²ÉÓÃÕâÖÖ½âÎö·½Ê½£¬ÆäÖаüº¬ÁËÖøÃûµÄHibernate¡£ÕâÀïÎÒÃÇʹÓÃDom4J½âÎöÒ»¸ö´øÃüÃû¿Õ¼äµÄCXFµÄSpringÅäÖÃÎļþ¡£Ïȵ¼Èëdom4j-1.6.1.jar
spring ÅäÖÃÎļþ applicationContext-cxf.xml:
 <?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:jaxws="http://cxf.apache.org/jaxws"
xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd
http://cxf.apache.org/jaxws
http://cxf.apache.org/schemas/jaxws.xsd"
default-autowire="byName" default-lazy-init="true">
<import resource="classpath:META-INF/cxf/cxf.xml" />
<import resource="classpath:META-INF/cxf/cxf-servlet.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
<bean id="jaxWsServiceFactoryBean" class="org.apache.cxf.jaxws.support.JaxWsServiceFactoryBean" scope="prototype">
<property name="wrapped" value="true"/>
<property name="dataBinding" ref="aegisBean"/>
<property name="serviceConfigurations">
<list>
<bean class="org.apache.cxf.jaxws.support.JaxWsServiceConfiguration"/>
<bean class="org.apache.cxf.aegis.databinding.AegisServiceConfiguration"/>
<bean class="org.apache.cxf.service.factory.DefaultServiceConfiguration"/>
</list>
</property>
</bean>
<bean id="aegisBean" class="org.apache.cxf.aegis.databinding.AegisDatabinding"/>

<jaxws:endpoint id="WSpersonService" implementor="#personService" address="/PersonService">
<jaxws:serviceFactory>


Ïà¹ØÎĵµ£º

hibernate.cfg.xml¹ØÁªOracleÊý¾Ý¿âµÄÅäÖÃ

<?xml version="1.0" encoding="UTF-8" ?> <!DOCTYPE hibernate-configuration (View Source for full doctype...)>
- <!-- Generated by MyEclipse Hibernate Tools.
--> - <!-- ÒÔÉϼ¸ÐÐËùÓеÄhibernate.cfg.xml¶¼Ïàͬ
--> [url=file:///C:/Documents%20and%20Settings/ ......

.NETÐÞ¸ÄxmlÎļþ

using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using i_salesDAL;
using i_s ......

XMLÎļþÐ޸IJÙ×÷

´ËXMLʵÀýÒÔ·þÎñÆ÷¶Ë²¿ÃŹÜÀíΪÀý£º£¨Æä½çÃæÈçÏ£©
  private void btn_UpdateGroup_Click(object sender, EventArgs e)
        {  
            XmlDocument xmlDoc = new XmlDocument();
  & ......

Сë¿xml¶ÁÊé±Ê¼Ç

1.Èç¹ûÐèÒªÔÚÓ¦ÓóÌÐòÖд¦ÀíxmlÊý¾Ý£¬Ê×ÏÈÒª´´½¨1¸öXmlDocument¶ÔÏó£¬È»ºóͨ¹ýload·½·¨´ÓxmlÊý¾ÝÔ´ÖмÓÔØ¶ÔÏó¡£
2.xmlÖеÄÊý¾ÝÖ÷Òª±íÏÖÎªÔªËØºÍÊôÐÔÁ½ÖÖÐÎʽ¡£
3.¶ÁÈ¡ÔªËØ
¶ÁÈ¡ÔªËØ¿Éͨ¹ýij½ÚµãµÄChildNodesÊôÐÔ»ñÈ¡Æä×ӽڵ㼯ºÏ£¬È»ºó¸ù¾Ý½ÚµãµÄNodeTypeÊôÐÔÈ·¶¨´Ë½ÚµãÊÇ·ñÊôÓÚÔªËØ½Úµã¡£ÔªËؽڵãµÄÃû³Æ¿Éͨ¹ýNameÊôÐÔ» ......

´´½¨×Ô¶¨ÒåÅÅÐòDataGrid¿Ø¼þµÄÀý×Ó(¶ÁÈ¡xml)

<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
layout="vertical"
verticalAlign="middle"
backgroundColor="white" viewSourceURL="srcview/index.html">
<mx:S ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ