最新下载
热门教程
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
asp.net c#封装的一个xml文件读取类
时间:2022-06-25 06:34:48 编辑:袖梨 来源:一聚教程网
A:在XML文件中有多个集,每个集里面包含多个节点。
B:可根据集的名字的取出这个集合下面的所有节点值
C:可一次性取出所有的节点值
D:其中有一个是无限拓展的就是:表达式
E:把集合读取到一个模型(实体类)当中
getmxl.cs文件
代码如下 | 复制代码 |
using System; namespace XmlOperation /// /// /// |
xmcommandMode.cs文件
代码如下 | 复制代码 |
using System; namespace XmlOperation } /// private string commandName; private string commandValue; private string[] commandPuts; |
xmlopt.cs文件
代码如下 | 复制代码 |
using System; namespace XmlOperation ///
/// /// /// /// private string filePath; |
最后一个简单的配置codetest.snl
代码如下 | 复制代码 |
Microsoft Visual Studio Solution File, Format Version 10.00 # Visual Studio 2008 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MyXML", "MyXMLMyXML.csproj", "{283858AE-82B4-4411-810F-C6AD19833132}" EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "XmlOperation", "XmlOperationXmlOperation.csproj", "{9A50C0DB-77F2-4B31-A451-90222CB56E00}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU Release|Any CPU = Release|Any CPU EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution {283858AE-82B4-4411-810F-C6AD19833132}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {283858AE-82B4-4411-810F-C6AD19833132}.Debug|Any CPU.Build.0 = Debug|Any CPU {283858AE-82B4-4411-810F-C6AD19833132}.Release|Any CPU.ActiveCfg = Release|Any CPU {283858AE-82B4-4411-810F-C6AD19833132}.Release|Any CPU.Build.0 = Release|Any CPU {9A50C0DB-77F2-4B31-A451-90222CB56E00}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {9A50C0DB-77F2-4B31-A451-90222CB56E00}.Debug|Any CPU.Build.0 = Debug|Any CPU {9A50C0DB-77F2-4B31-A451-90222CB56E00}.Release|Any CPU.ActiveCfg = Release|Any CPU {9A50C0DB-77F2-4B31-A451-90222CB56E00}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection EndGlobal |