R
Russ
Suppose I want to specify a position on the earth. I could define an
element such as
<position coords="WGS84", lat="34.56223", lon="-121.8277"/>
where lat and lon are latitude and longitude in the WGS84 coordinate
system. Now suppose I also want to have the option of specifying the
position in another coordinate system, a locally level cartesian
system. I could define an element such as
<position coords="DFW", x="236.764", y="129.667"/>
where "DFW" is a predefined coordinate system.
I'm new to XML, and I'd like to know if it is possible to define a
schema that would enforce consistency for both options and perhaps
others as well. The trick here is that for the WGS84 coordinate
system, the coordinate attributes are lat and lon, whereas for the DFW
system they are x and y. Is it possible to write a schema to require
this? Thanks.
element such as
<position coords="WGS84", lat="34.56223", lon="-121.8277"/>
where lat and lon are latitude and longitude in the WGS84 coordinate
system. Now suppose I also want to have the option of specifying the
position in another coordinate system, a locally level cartesian
system. I could define an element such as
<position coords="DFW", x="236.764", y="129.667"/>
where "DFW" is a predefined coordinate system.
I'm new to XML, and I'd like to know if it is possible to define a
schema that would enforce consistency for both options and perhaps
others as well. The trick here is that for the WGS84 coordinate
system, the coordinate attributes are lat and lon, whereas for the DFW
system they are x and y. Is it possible to write a schema to require
this? Thanks.