[josm-dev] JOSM file format extensions

Russ Nelson nelson at crynwr.com
Sat Mar 20 02:32:10 GMT 2010


Frederik Ramm writes:
 > If JOSM used a special JOSM format which other software would not 
 > recognize, then we could provide import and export functions or 
 > converters that would make sure that things are handled correctly, e.g. 
 > that if you export from JOSM to an <osm> file all objects marked as 
 > deleted will not be exported, and so on. People would not be tempted to 
 > think "oh, it's an OSM file, I can use it with the XYZ application".

Simply done: When reading a file, accept either <osm>...</osm> content
or <josm>...</josm> content.  When writing a file, write
<josm>...</josm> only.  If somebody wants their tool to read and write
<joom /> files, they can modify it so it knows about <josm /> and
respects the action= parameter.

Actually, the more I think about it, the more I think it's a damned
good idea and ... oh, wait.  It's *my* idea.  Of course I think it's a
great idea, otherwise I wouldn't waste your time with it.

Addendum: only write a .josm file with <josm /> if they've made
changes to the data.  If they just downloaded something into memory,
then we can safely write it out as if they'd done a wget with the
appropriate parameters.

-- 
--my blog is at    http://blog.russnelson.com
Crynwr supports open source software
521 Pleasant Valley Rd. | +1 315-600-8815
Potsdam, NY 13676-3213  |     Sheepdog       




More information about the josm-dev mailing list