Reader Overview

The OSM reader can interpret OSM XML files in several different ways. The reader may output un-categorized nodes, ways and relations, or it may categorize these data primitives according to the recommended interpretations found in http://wiki.openstreetmap.org/index.php/Map_Features.

The OSM reader provides two options when directed to interpret the OSM data with the OSM community approved feature types. The data can be interpreted with either broad or specific categories.

For example, when set to specific, the reader will output highway_motorway, highway_primary, highway_unclassified, etc., as feature types, whereas it will only output a highway feature type when its mode is set to broad.

Note that to determine the possible attribute name/value pairs of each feature type, the reader can either perform a schema scan on the entire data file, or it can provide an extensive list of feature types from which the desired types can be manually selected. These two options are available because a schema scan on a large file can be a slow process: in these cases, it may be more desirable to simply select feature types manually.

With three exceptions the OSM relations are not interpreted. The interpreted relations are the ones that are tagged with a key of type and values of either multipolygon, route, or restriction. Both route and restriction are output as non-geometrical features, and their feature types are set to relation_route and relation_restriction, respectively. The multipolygon relation is output as an area or multi-area geometry; this includes donuts, or an aggregate of polygons and donuts. The multipolygon relation may be output as a line or a non-geometrical feature. In the case of bad geometrical information, the multipolygon relation feature type will be set to relation_multipolygon.