[OSM-talk] Xml design
scott
scott at waye.co.uk
Sun Jan 7 12:21:01 GMT 2007
Some thoughts:
With the current XML design of k="" v="" it would seem very difficult to
create a useful XSD for the data. A tight XSD would help to avoid
duplication,spelling mistakes, reduce the xml size, and would allow for
the gui to present useful drop downs. For example we currently have
<way id="4073353" timestamp="2006-12-13T01:57:16+00:00">
<seg id="65667" />
<seg id="65652" />
<tag k="created_by" v="JOSM" />
<tag k="highway" v="unclassified" />
<tag k="oneway" v="true" />
</way>
What I am proposing is to have
<way id="4073353" timestamp="2006-12-13T01:57:16+00:00"
created_by="JOSM" highway="unclassified oneway="true">
<seg id="65667" />
<seg id="65652" />
</way>
We could then have an XSD which lists the valid values for the highway
attribute, and applications like JOSM could present those in a drop
down. Presently, for example, in the database we have the following
attributes:
abbutter
abbutters
abutment
abutters
abuttors
we also have at least 10 versions (these are just the ones that begin
with h) of highway:
hgihway
hifgway
highawy
highjway
highwau
highway
highway:
highwy
higway
hoghway
The argument might be put forward that the current design allows more
flexibility. But I dont buy that. There is nothing to stop you
extending the XSD when needed. That is what the X stands for,
extensibility.
I dont care if they are stored in the SQL database as name value pairs,
thats a different issue, and the current implementation is fine as far
as I'm concerned.
Any thoughts?
--
Scott
More information about the talk
mailing list