最近几年来,地理信息系统无论是在理论上还是应用上都处在一个飞速发展的阶段。 GIS被应用于多个领域的建模和决策支持,如城市管理、区划、环境整治等等,地理信息成为信息时代重要的组成部分之一; “数字地球”概念的提出,更进一步推动了作为其技术支撑的GIS的发展。 与此同时,一些学者致力于相关的理论研究,如空间感知、空间数据误差、空间关系的形式化等等。 这恰好说明了地理信息系统作为应用技术和学科的两个方面,并且这两个方面构成了相互促进的发展过程。
All properties are declared as simple types. Simple elements cannot have attributes. If an element has an attribute, it is treated as a compound type. But the property itself is always declared as a simple type. The syntax for defining attributes is Here, xxx refers to the name of the attribute, and yyy specifies the data type of the attribute. XML Schema has many built-in data types. Xs:string Xs:decimal Xs:integer Xs:boolean Xs:date Xs:time This is the XML element with attributes: This is the corresponding attribute definition: Property can have a specified default value or fixed value. When no other value is specified, the default value is automatically assigned to the element. In the following example, the default value is “EN”: Fixed values are also automatically assigned to elements, and you cannot specify additional values. In the following example, the fixed value is “EN”: By default, properties are optional. To specify the attribute as required, use the “use” attribute: When an XML element or attribute has a defined data type, a qualification is added to the content of the element or attribute. If the XML element is of type “xs:date” and contains a string similar to “Hello World”, the element will not be validated. With XML schema, you can also add your own qualifications to your XML elements and attributes. These qualifiers are called facet. You’ll learn more about facet in the next section. What is an attribute? ¶
How do I declare properties? ¶
<xs:attribute name="xxx" type="yyy"/>
The most common types are: ¶
Example ¶
<lastname lang="EN">Smithlastname>
<xs:attribute name="lang" type="xs:string"/>
Default value and fixed value of the attribute ¶
<xs:attribute name="lang" type="xs:string" default="EN"/>
<xs:attribute name="lang" type="xs:string" fixed="EN"/>
Optional and required properties ¶
<xs:attribute name="lang" type="xs:string" use="required"/>
Limitation of content ¶