×Ô¶¯¼ìË÷XMLÊý¾Ý
1.books.html
<!--
To change this template, choose Tools | Templates
and open the template in the editor.
-->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<script>
var xmlHttpReq = false;
function createXMLHttpRequest(){
try{
//Firefox,Opera8.0+,Safari
xmlHttpReq = new XMLHttpRequest();
}catch(e){
//Internet Explorer
try{
//Internet Explorer 6.0
xmlHttpReq = new ActiveXObject("Msxml2.XMLHTTP");
}catch(e){
Ïà¹ØÎĵµ£º
public sealed class XmlHelper
{
public static void Serialize<T>(T obj,string fileName)
{
TextWriter writer = new StreamWriter(fileName);
try
{
XmlSerializer ser = new XmlSerializer(typeof(T));
......
XML DOM
¡¡¡¡XML DOM ¶¨ÒåÁË·ÃÎʺʹ¦Àí XML ÎĵµµÄ±ê×¼·½·¨¡£
¡¡¡¡XML DOM ÊÇ XML Document Object Model µÄËõд£¬¼´ XML Îĵµ¶ÔÏóÄ£ÐÍ¡£
¡¡¡¡Ò»¡¢DOM ¼ò½é
¡¡¡¡Ê²Ã´ÊÇ DOM£¿
¡¡¡¡DOM ÊÇ W3C£¨ÍòÎ¬ÍøÁªÃË£© µÄÍÆ¼ö±ê×¼¡£
¡¡¡¡DOM ¶¨ÒåÁË·ÃÎÊÖîÈç XML ºÍ XHTML ÎĵµµÄ±ê×¼¡£
¡¡¡¡“W3C Îĵµ¶ÔÏóÄ£ÐÍ£¨DOM£©ÊÇÒ»¸ ......
1.¶ÁÈ¡XMLÎļþµÄÀࣺ
public class XMLUtils {
private final String DB_XML_FILE = "/XMLSetting.xml";
public Properties getPropertiesfromXML() {
URL url = XMLUtils.class.getResource(dBXMLFILE);
URI uri;
try {
uri = url.toURI();
InputSource xmlfile = new InputSource(uri.g ......
ÎÒдµÄµÚÒ»¸ö³ÌÐòÖÐдXMLµÄ´úÂëÖ´ÐÐËÙ¶ÈÓÐЩÎÊÌ⣬¸ÄÁËһϣ¬ÏÖÔÚÓÐËù¸ÄÉÆ¡£
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Diagnostics;
using System.Linq;
using System.ServiceProcess;
using System.Text;
using System.Data.SqlClient;
......
Ò»¸öC# xml ÐòÁл¯´íÎó
Ê·¢ÏÖ³¡£º
xmlÐòÁл¯µÄÊý¾ÝÖд洢µÄ½ÚµãÊý¾ÝÊÇ
<Module>536870912</Module> £¨xmlÎļþÖУ©
¶ÔÓ¦µÄÀàÊôÐÔÊÇ
public short Module { get; set; } £¨C#ÀàÖУ©
ÐòÁл¯µÄ´úÂ룺
public static FMDSTimeSeriesDefinitio ......