R
R.Schuetze
Hallo,
I'm working on an XSD schema for an 3D Point. The XML struktur of the
point is the following:
<Point name="6" target="Retro" type="TP" unit="m">
<param name="X" value="0.000"/>
<param name="Y" value="0.000"/>
<param name="Z" value="0.000"/>
</Point>
The user have to fill use all three coordinates (X,Y,Z). Does somebody
haven an idea how I can implement the schema?
Thanks
Rainer
My first implemention of the Point was, but this would work, the
validation of the XSD failed.
<xs:element name="Point" type="pointCoordType">
...
</xs:element>
<xs:complexType name="pointCoordType">
<xs:all>
<xs:element name="param">
<xs:complexType>
<xs:attribute name="name" use="required" type="xs:string"
fixed="X"/>
<xs:attribute name="value" use="required" type="xs:double" />
...
</xs:complexType>
</xs:element>
<xs:element name="param">
<xs:complexType>
<xs:attribute name="name" use="required" type="xs:string"
fixed="Y"/>
<xs:attribute name="value" use="required" type="xs:double" />
...
</xs:complexType>
</xs:element>
...
</xs:all>
</xs:complexType>
I'm working on an XSD schema for an 3D Point. The XML struktur of the
point is the following:
<Point name="6" target="Retro" type="TP" unit="m">
<param name="X" value="0.000"/>
<param name="Y" value="0.000"/>
<param name="Z" value="0.000"/>
</Point>
The user have to fill use all three coordinates (X,Y,Z). Does somebody
haven an idea how I can implement the schema?
Thanks
Rainer
My first implemention of the Point was, but this would work, the
validation of the XSD failed.
<xs:element name="Point" type="pointCoordType">
...
</xs:element>
<xs:complexType name="pointCoordType">
<xs:all>
<xs:element name="param">
<xs:complexType>
<xs:attribute name="name" use="required" type="xs:string"
fixed="X"/>
<xs:attribute name="value" use="required" type="xs:double" />
...
</xs:complexType>
</xs:element>
<xs:element name="param">
<xs:complexType>
<xs:attribute name="name" use="required" type="xs:string"
fixed="Y"/>
<xs:attribute name="value" use="required" type="xs:double" />
...
</xs:complexType>
</xs:element>
...
</xs:all>
</xs:complexType>