易截截图软件、单文件、免安装、纯绿色、仅160KB

高性能XML解析类

//pugxml.h
///////////////////////////////////////////////////////////////////////////////
//
// Pug XML Parser - Version 1.0002
// --------------------------------------------------------
// Copyright (C) 2003, by Kristen Wegner (kristen@tima.net)
// Released into the Public Domain. Use at your own risk.
// See pugxml.xml for further information, history, etc.
// Contributions by Neville Franks (readonly@getsoft.com).
//
///////////////////////////////////////////////////////////////////////////////
#if !defined(_PUGXML_)
#define _PUGXML_
#pragma once
//#define PUGOPT_MEMFIL //Uncomment to enable memory-mapped file parsing support.
//#define PUGOPT_NONSEG //Uncomment to enable non-destructive (non-segmenting) parsing support.
#ifdef PUGOPT_MEMFIL
# ifndef PUGOPT_NONSEG
#  define PUGOPT_NONSEG //PUGOPT_MEMFIL implies PUGOPT_NONSEG.
# endif
#endif
#include <iostream>
#include <ostream>
#include <string>
#if defined(PUGOPT_MEMFIL) | defined(PUGOPT_NONSEG)
# include <assert.h>
#endif
#ifndef HIWORD
# define HIWORD(X) ((unsigned short)((unsigned long)(X)>>16))
# define LOWORD(X) ((unsigned short)((unsigned long)(X)&0xFFFF))
#endif
//<summary>
// Library variant ID. The ID 0x58475550 is owned by Kristen Wegner. You *MUST*
// provide your own unique ID if you modify or fork the code in this library to
// your own purposes. If you change this then *you* are now the maintainer, not me.
// Change also in the package section of pugxml.xml, and append yourself to the
// authors section.
//</summary>
#define PUGAPI_INTERNAL_VARIANT 0x58475550
//<summary>Major version. Increment for each major release. Only change if you own the variant.</summary>
#define PUGAPI_INTERNAL_VERSION_MAJOR 1
//<summary>Minor version. Increment for each minor release. Only change if you own the variant ID.</summary>
#define PUGA


相关文档:

Spring XML配置的12个技巧

Spring是一个强有力的java程序框架,其被广泛应用于java的程序中。它用POJO提供了企业级服务。Spring利用依赖注入可以获得简单而有效的测试能力。Spring beans,依赖关系,以及服务所需要的bean都将在配置文件中予以描述,配置文件一般采用XML格式。然而XML配置文件冗长而不易使用,在你进行一个使用了大量bean的大项目中它 ......

获取某个文件夹信息,并生成XML文件,按树形显示

private XmlDocument xmlDoc;
        private void btnCreateXml_Click(object sender, EventArgs e)
        {
            //自 ......

将XML数据填充到TreeView中

文档及代码下载:http://www.dingos.cn/index.php?topic=1899.0
介绍

当菜单项是经常改变时,从XML文档中创建TreeView才当是非常有用的。例如,使用XML作为数据库存储记录。
这里有个简单示例。以防混淆这个例子比较简单。
背景
对XML、TreeView控件的应用,在Visual Studio中有助于理解这些步骤。
使用代码
注意 ......

C#读取XML文件的简单方法

一、XML只有一个Table的情况
      (1)userInfo.xml
              <?xml version="1.0" encoding="utf-8" ?>
              <UserInfo ......

XML 中,有 5 个预定义的实体引用:


&lt;
<
小于
&gt;
>
大于
&amp;
&
和号
&apos;
'
单引号
&quot;
"
引号
 
注释:在 XML 中,只有字符 "<" 和 "&" 确实是非法的。大于号是合法的,但是用实体引用来代替它是一个好习惯。 ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号