GML对象的层次结构
GML是一个复杂的标准。本文的内容以OGC GML 3.1.0为参考标准。它包含的内容非常多,除常规的二维矢量GIS信息以外,还包括复杂目标、拓扑信息、三维目标、时态信息、地理覆盖、注记符号、空间参考、元数据、栅格数据等等信息。和GML2版本不同,GML3.1.0中的Feature并不总是几何对象,而是真正成为一个有实际意义的地理对象(实体或现象)的抽象。这样的Feature既可以描述具体实在的对象,也可以表达抽象的或者是概念上的对象,还可以描述变化中的与空间位置相关联的现象。
下面的UML图表示了GML对象的层次结构,各个对象的模式文档基本上都是围绕着图中的对象分类来进行组织的。
<!--[if mso & !supportInlineShapes & supportFields]><span
lang=EN-US><span style='mso-element:field-begin;mso-field-lock:yes'></span><span
style='mso-spacerun:yes'> </span>SHAPE<span style='mso-spacerun:yes'>
</span>/* MERGEFORMAT <span style='mso-element:field-separator'></span></span><![endif]--><!--[if gte vml 1]><v:group id="_x0000_s1026" editas="canvas"
style='width:372pt;height:289pt;mso-position-horizontal-relative:char;
mso-position-vertical-relative:line' coordorigin="1613,9168" coordsize="7200,5780">
<o:lock v:ext="edit" aspectratio="t" />
<v:shapetype id="_x0000_t75" coordsize="21600,21600" o:spt="75"
o:preferrelative="t" path="[email protected]@[email protected]@[email protected]@[email protected]@5xe" filled="f" stroked="f">
<v:stroke joinstyle="miter" />
<v:formulas>
<v:f eqn="if lineDrawn pixelLineWidth 0" />
<v:f eqn="sum @0 1 0" />
<v:f eqn="sum 0 0 @1" />
<v:f eqn="prod @2 1 2" />
<v:f eqn="prod @3 21600 pixelWidth" />
<v:f eqn="prod @3 21600 pixelHeight" />
<v:f eqn="sum @0 0 1" />
<v:f eqn="prod @6 1 2" />
<v:f eqn="prod @7 21600 pixelWidth" />
<v:f eqn="sum @8 21600 0" />
<v:f eqn="prod @7 21600 pixelHeight" />
<v:f eqn="sum @10 21600 0" />
</v:formulas>
<v:path o:extrusionok="f" gradientshapeok="t" o:connecttype="rect" />
<o:lock v:ext="edit" aspectratio="t" />
</v:shapetype><v:shape id="_x0000_s1027" type="#_x0000_t75" style='position:absolute;
left:1613;top:9168;width:7200;height:5780' o:preferrelative="f">
<v:fill o:detectmouseclick="t" />
<v:path o:extrusionok="t" o:connecttype="none" />
<o:lock v:ext="edit" text="t" />
</v:shape><v:rect id="_x0000_s1028" style='position:absolute;left:4400;top:9338;
width:1278;height:510'>
<v:textbox style='mso-next-textbox:#_x0000_s1028'>
<![if !mso]>
<table cellpadding=0 cellspacing=0 width="100%">
<tr>
<td><![endif]>
<div>
<p class=MsoNormal><span lang=EN-US style='font-size:9.0pt'>gml:_Object<o:p></o:p></span></p>
</div>
<![if !mso]></td>
</tr>
</table>
<![endif]></v:textbox>
</v:rect><v:shapetype id="_x0000_t5" coordsize="21600,21600" o:spt="5" adj="10800"
path="[email protected],l,21600r21600,xe">
<v:stroke joinstyle="miter" />
<v:formulas>
<v:f eqn="val #0" />
<v:f eqn="prod #0 1 2" />
<v:f eqn="sum @1 10800 0" />
</v:formulas>
<v:path gradientshapeok="t" o:connecttype="custom" o:connectlocs="@0,0;@1,10800;0,21600;10800,21600;21600,21600;@2,10800"
textboxrect="0,10800,10800,18000;5400,10800,16200,18000;10800,10800,21600,18000;0,7200,7200,21600;7200,7200,14400,21600;14400,7200,21600,21600" />
<v:handles>
<v:h position="#0,topLeft" xrange="0,21600" />
</v:handles>
</v:shapetype><v:shape id="_x0000_s1029" type="#_x0000_t5" style='position:absolute;
left:4981;top:9848;width:232;height:170' />
<v:line id="_x0000_s1030" style='position:absolute' from="3936,10188" to="6374,10188" />
<v:line id="_x0000_s1031" style='position:absolute' from="5097,10018" to="5097,10188" />
<v:rect id="_x0000_s1032" style='position:absolute;left:3239;top:10528;
width:1278;height:510'>
<v:textbox style='mso-next-textbox:#_x0000_s1032'>
<![if !mso]>
<table cellpadding=0 cellspacing=0 width="100%">
<tr>
<td><![endif]>
<div>
<p class=MsoNormal><span lang=EN-US style='font-size:9.0pt'>gml:_GML<o:p></o:p></span></p>
</div>
<![if !mso]></td>
</tr>
</table>
<![endif]></v:textbox>
</v:rect><v:rect id="_x0000_s1033" style='position:absolute;left:5794;top:10528;
width:1278;height:510'>
<v:textbox style='mso-next-textbox:#_x0000_s1033'>
<![if !mso]>
<table cellpadding=0 cellspacing=0 width="100%">
<tr>
<td><![endif]>
<div>
<p class=MsoNormal><span lang=EN-US style='font-size:9.0pt'>gml:_Value<o:p></o:p></span></p>
</div>
<![if !mso]></td>
</tr>
</table>
<![endif]></v:textbox>
</v:rect><v:line id="_x0000_s1034" style='position:absolute' from="3936,10188"
to="3936,10528" />
<v:line id="_x0000_s1035" style='position:absolute' from="6374,10188" to="6374,10528" />
<v:shape id="_x0000_s1036" type="#_x0000_t5" style='position:absolute;left:3819;
top:11038;width:233;height:170' />
<v:line id="_x0000_s1037" style='position:absolute' from="3936,11208" to="3937,11378" />
<v:line id="_x0000_s1038" style='position:absolute' from="2542,11378" to="8116,11379" />
<v:rect id="_x0000_s1039" style='position:absolute;left:3703;top:11718;
width:1510;height:510'>
<v:textbox style='mso-next-textbox:#_x0000_s1039'>
<![if !mso]>
<table cellpadding=0 cellspacing=0 width="100%">
<tr>
<td><![endif]>
<div>
<p class=MsoNormal><span lang=EN-US style='font-size:9.0pt'>gml:_Geometry<o:p></o:p></span></p>
</div>
<![if !mso]></td>
</tr>
</table>
<![endif]></v:textbox>
</v:rect><v:rect id="_x0000_s1040" style='position:absolute;left:5561;top:11718;
width:1627;height:510'>
<v:textbox style='mso-next-textbox:#_x0000_s1040'>
<![if !mso]>
<table cellpadding=0 cellspacing=0 width="100%">
<tr>
<td><![endif]>
<div>
<p class=MsoNormal><span lang=EN-US style='font-size:9.0pt'>gml:_TimeObject<o:p></o:p></span></p>
</div>
<![if !mso]></td>
</tr>
</table>
<![endif]></v:textbox>
</v:rect><v:rect id="_x0000_s1041" style='position:absolute;left:6258;top:12398;
width:2323;height:510'>
<v:textbox style='mso-next-textbox:#_x0000_s1041'>
<![if !mso]>
<table cellpadding=0 cellspacing=0 width="100%">
<tr>
<td><![endif]>
<div>
<p class=MsoNormal><span lang=EN-US style='font-size:9.0pt'>gml:_TimeReferenceSystem<o:p></o:p></span></p>
</div>
<![if !mso]></td>
</tr>
</table>
<![endif]></v:textbox>
</v:rect><v:rect id="_x0000_s1042" style='position:absolute;left:1961;top:11718;
width:1395;height:510'>
<v:textbox style='mso-next-textbox:#_x0000_s1042'>
<![if !mso]>
<table cellpadding=0 cellspacing=0 width="100%">
<tr>
<td><![endif]>
<div>
<p class=MsoNormal><span lang=EN-US style='font-size:9.0pt'>gml:_Topology<o:p></o:p></span></p>
</div>
<![if !mso]></td>
</tr>
</table>
<![endif]></v:textbox>
</v:rect><v:rect id="_x0000_s1043" style='position:absolute;left:4632;top:12398;
width:1395;height:510'>
<v:textbox style='mso-next-textbox:#_x0000_s1043'>
<![if !mso]>
<table cellpadding=0 cellspacing=0 width="100%">
<tr>
<td><![endif]>
<div>
<p class=MsoNormal><span lang=EN-US style='font-size:9.0pt'>gml:Definition<o:p></o:p></span></p>
</div>
<![if !mso]></td>
</tr>
</table>
<![endif]></v:textbox>
</v:rect><v:rect id="_x0000_s1044" style='position:absolute;left:7536;top:11718;
width:1161;height:510'>
<v:textbox style='mso-next-textbox:#_x0000_s1044'>
<![if !mso]>
<table cellpadding=0 cellspacing=0 width="100%">
<tr>
<td><![endif]>
<div>
<p class=MsoNormal><span lang=EN-US style='font-size:9.0pt'>gml:_Style<o:p></o:p></span></p>
</div>
<![if !mso]></td>
</tr>
</table>
<![endif]></v:textbox>
</v:rect><v:rect id="_x0000_s1045" style='position:absolute;left:2774;top:12398;
width:1279;height:510'>
<v:textbox style='mso-next-textbox:#_x0000_s1045'>
<![if !mso]>
<table cellpadding=0 cellspacing=0 width="100%">
<tr>
<td><![endif]>
<div>
<p class=MsoNormal><span lang=EN-US style='font-size:9.0pt'>gml:_Feature<o:p></o:p></span></p>
</div>
<![if !mso]></td>
</tr>
</table>
<![endif]></v:textbox>
</v:rect><v:line id="_x0000_s1046" style='position:absolute' from="2542,11378"
to="2542,11718" />
<v:line id="_x0000_s1047" style='position:absolute' from="8116,11378" to="8116,11718" />
<v:line id="_x0000_s1048" style='position:absolute' from="4400,11378" to="4400,11718" />
<v:line id="_x0000_s1049" style='position:absolute' from="6258,11378" to="6258,11718" />
<v:line id="_x0000_s1050" style='position:absolute' from="3471,11378" to="3472,12398" />
<v:line id="_x0000_s1051" style='position:absolute' from="5329,11378" to="5329,12398" />
<v:line id="_x0000_s1052" style='position:absolute' from="7303,11378" to="7303,12398" />
<v:shape id="_x0000_s1053" type="#_x0000_t5" style='position:absolute;left:3239;
top:12908;width:232;height:170' />
<v:line id="_x0000_s1054" style='position:absolute' from="3355,13078" to="3356,13248" />
<v:shape id="_x0000_s1055" type="#_x0000_t5" style='position:absolute;left:5213;
top:12908;width:232;height:170' />
<v:line id="_x0000_s1056" style='position:absolute' from="5329,13078" to="5330,13248" />
<v:rect id="_x0000_s1057" style='position:absolute;left:1729;top:13418;
width:1394;height:510'>
<v:textbox style='mso-next-textbox:#_x0000_s1057'>
<![if !mso]>
<table cellpadding=0 cellspacing=0 width="100%">
<tr>
<td><![endif]>
<div>
<p class=MsoNormal><span lang=EN-US style='font-size:9.0pt'>gml:_Coverage<o:p></o:p></span></p>
</div>
<![if !mso]></td>
</tr>
</table>
<![endif]></v:textbox>
</v:rect><v:rect id="_x0000_s1058" style='position:absolute;left:3239;top:13418;
width:1509;height:510'>
<v:textbox style='mso-next-textbox:#_x0000_s1058'>
<![if !mso]>
<table cellpadding=0 cellspacing=0 width="100%">
<tr>
<td><![endif]>
<div>
<p class=MsoNormal><span lang=EN-US style='font-size:9.0pt'>gml:Observation<o:p></o:p></span></p>
</div>
<![if !mso]></td>
</tr>
</table>
<![endif]></v:textbox>
</v:rect><v:rect id="_x0000_s1059" style='position:absolute;left:4981;top:13418;
width:1974;height:510'>
<v:textbox style='mso-next-textbox:#_x0000_s1059'>
<![if !mso]>
<table cellpadding=0 cellspacing=0 width="100%">
<tr>
<td><![endif]>
<div>
<p class=MsoNormal><span lang=EN-US style='font-size:9.0pt'>gml:_ReferenceSystem<o:p></o:p></span></p>
</div>
<![if !mso]></td>
</tr>
</table>
<![endif]></v:textbox>
</v:rect><v:rect id="_x0000_s1060" style='position:absolute;left:7071;top:13418;
width:1742;height:510'>
<v:textbox style='mso-next-textbox:#_x0000_s1060'>
<![if !mso]>
<table cellpadding=0 cellspacing=0 width="100%">
<tr>
<td><![endif]>
<div>
<p class=MsoNormal><span lang=EN-US style='font-size:9.0pt'>gml:_UnitDefinition<o:p></o:p></span></p>
</div>
<![if !mso]></td>
</tr>
</table>
<![endif]></v:textbox>
</v:rect><v:line id="_x0000_s1061" style='position:absolute' from="2426,13248"
to="3936,13248" />
<v:line id="_x0000_s1062" style='position:absolute' from="2426,13248" to="2426,13418" />
<v:line id="_x0000_s1063" style='position:absolute' from="3936,13248" to="3936,13418" />
<v:line id="_x0000_s1064" style='position:absolute' from="5213,13248" to="8000,13248" />
<v:line id="_x0000_s1065" style='position:absolute' from="5213,13248" to="5213,13418" />
<v:line id="_x0000_s1066" style='position:absolute' from="8000,13248" to="8000,13418" />
<v:shape id="_x0000_s1067" type="#_x0000_t5" style='position:absolute;left:5910;
top:13928;width:232;height:170' />
<v:line id="_x0000_s1068" style='position:absolute' from="6025,14098" to="6026,14268" />
<v:rect id="_x0000_s1069" style='position:absolute;left:5445;top:14268;
width:1162;height:510'>
<v:textbox style='mso-next-textbox:#_x0000_s1069'>
<![if !mso]>
<table cellpadding=0 cellspacing=0 width="100%">
<tr>
<td><![endif]>
<div>
<p class=MsoNormal><span lang=EN-US style='font-size:9.0pt'>gml:_CRS<o:p></o:p></span></p>
</div>
<![if !mso]></td>
</tr>
</table>
<![endif]></v:textbox>
</v:rect><w:wrap type="none" />
<w:anchorlock />
</v:group><![endif]--><!--[if mso & !supportInlineShapes & supportFields]><span
lang=EN-US><v:shape id="_x0000_i1025" type="#_x0000_t75" style='width:372pt;
height:289pt'>
<v:imagedata croptop="-65520f" cropbottom="65520f" />
</v:shape><span style='mso-element:field-end'></span></span><![endif]-->
图中以下划线开头的项(如Feature)可看作该类的典型对象实例。例如,元素gml:_Feature应该解释为“任何GML要素”,它可以用来定义GML特性的值是“任何要素”的变量或模板。
地理要素包含一系列的空间和非空间属性,要素模式(Feature Schema)为创建GML的要素和要素集合提供了一个框架,它定义了抽象和具体的要素元素及类型,并通过<include>元素引入了几何模式和时态模式中的定义和声明。几何模式(Geometry Schema)详细地描述了地理要素的几何模型。时态模式(Temporal Schema)扩展了GML的核心元素,使其包括描述地理数据时态特征的元素,它提供一种框架用于描述动态要素的时间变化。覆盖模式(Coverage Schema)支持从时空域到属性值的映射,属性类型对于时空域里的所有地理位置是公共的,时空域直接由坐标空间中的许多直接位置组成。拓扑模式(Topology Schema)定义了反映地理要素之间关系的拓扑对象。