[Openstreetmap-dev] Data Primatives & schema

Tom Carden tom at tom-carden.co.uk
Wed Dec 21 09:47:30 GMT 2005

> Following on from my stab last month on a schema, I took on board the
> comments and decided on a different tack. Matt had taken a look at an OSM
> XML schema so I'm kind of feeding off that but focussing on the user end
> of
> things rather than how the database stores and communicates with users.
> First off I wanted to go back to the data primitives. No intention
> whatsoever in trying to change the principal database structure in any way
> but rather wanting to consolidate some of the recent discussion and make
> some minor revisions of the wiki page.

</disclaimer> :)

> The definitions on the wiki are not entirely explicit, thus I produced the
> following to try and be a little more explicit.
> NODE: Any point on, under or attached to the earth.

Has latitude, longitude, uid and tags.

> Line SEGMENT: An association of two separate NODEs

Has start node uid, end node uid, uid and tags.

> WAY: An association of one or more line SEGMENTS

Has a list of segment uids, uid and tags?

> ZONE: An association of three or more NODEs where the first and last NODEs
> have the same uid.

If you're having the first and last node the same, you need four nodes to
be sure of having an area.  Also, specifying that the first and last node
need to be the same is superfluous - just say a zone is always closed. 
It's probably more correct to say that 3 or more poiints form a zone so
long as they are not co-linear.

> Just three questions:
> 1. Are the definitions sufficiently explicit?
> 2. Are the statements correct?
> 3. Any comments on the nomenclature change of Street to WAY and Area to

Agreed on the change of street to way, if we must.  Confused as to why
'area' isn't the best word for an, um, area.

> Initially I called the WAY (formerly Street) a POLYLINE, however a
> polyline
> would be made up of nodes and not line segments. Since I could not see any
> reason why we would have to have polylines with no breaks I think the
> original idea of it being made up from line SEGMENTs is better. Its also a
> more logical way of mapping since on the whole its better to lay down the
> nodes and segments before establishing that the whole is Baker Street.
> "Way"
> was used instead of "Track" because of the similarity with gps tracks
> which
> was pointed out.

FWIW, polyline would be fine by me... where does the requirement that
polylines must be collections of nodes come from - wouldn't that be
polynode?  Stick with "way", anyway.



More information about the dev mailing list