属性节点
属性节点 表示 XML 属性。
属性节点可以具有一个父代,也可以没有父代。 可将拥有属性的元素节点认为是它的父代,尽管属性节点不是它的父元素的子代。
属性节点具有下列节点属性:
- 节点名
- 母公司
- 类型名称(DB2® 中属性节点的类型名称总是 xs:untypedAtomic.)
- 字符串值
- 类型值
<product xmlns="http://posample.org" pid="100-101-01">
<description>
<name>Snow Shovel, Deluxe 24"</name>
<details>A Deluxe Snow Shovel, 24 inches wide, ergonomic
curved handle with D-Grip</details>
<price>19.99</price>
<weight>2 kg</weight>
</description>
pid 属性具有以下属性值:
| 节点属性 | 值 | 值类型 |
|---|---|---|
| 节点名 | 进程标识 | |
| 母公司 | 产品节点 | |
| 类型名称 | xs:untypedAtomic | |
| 字符串值 | "100-101-01" | xs:string |
| 类型值 | 100-101-01" | xs:untypedAtomic |