Reader Directives
The suffixes shown are prefixed by the current <ReaderKeyword> in a mapping file. By default, the <ReaderKeyword> for the OSM reader is OSM.
DATASET
The location of the OSM file to be read.
Required/Optional
Required
Mapping File Syntax
OSM_DATASET c:\sample.osm
Workbench Parameter
Source OpenStreetMap File(s)
CLOSE_AREAS
Specifies whether the OSM reader should create area geometries for OSM ways, whose first and last point equal, even if their “area” tag is not appropriately set. The valid values for this directive are ‘Yes’ and ‘No’, with the default being ‘Yes’.
This directive is used when generating workspaces and mapping files. As a result, it is not editable within Workbench after the workspace has been generated.
Required/Optional
Optional
Mapping File Syntax
OSM_CLOSE_AREAS No
Workbench Parameter
Close Off Default Areas Even if 'area' Tag is Not Set
CUSTOM_AREA
This directive relies on a text file whose content lists the way feature types that should be converted into area geometries when their first and last coordinates equal.
The format of the text file is simple: each feature type that should be considered a possible area is listed on a separate line. Two example files can be found under <FME InstallDir>\xml\osm\AreaFeatureLists\osm_specific_areas.txt
and <FME InstallDir>\xml\osm\AreaFeatureLists\osm_broad_areas.txt
.
This directive is used when generating workspaces and mapping files. As a result, it is not editable within Workbench after the workspace has been generated.
Required/Optional
Optional
Mapping File Syntax
OSM_CUSTOM_AREA c:\my_osm_areas.txt
Workbench Parameter
Custom Area Feature List:
REMOVE_NODE_LIST
This directive controls whether way feature types should have the list of nodes added to the features as list attribute.
Values
YES | NO (default)
Required/Optional
Optional
Mapping File Syntax
OSM_REMOVE_NODE_LIST NO
Workbench Parameter
Remove Node List Attribute in Way
BUILD_MULTIPOLYGON_RELATION
This directive controls whether multipolygon relation feature types (that is, type tag has multipolygon value) should have its geometry built if set to YES or kept as a list attribute containing all the members if set to NO.
Values
YES | NO (default)
Required/Optional
Optional
Mapping File Syntax
OSM_BUILD_MULTIPOLYGON_RELATION NO
Workbench Parameter
Build Geometry for Multipolygon Relation
SCHEMA_CHOICE
This optional directive specifies whether the OSM primitives should be interpreted via predefined FME factory pipelines that categorize the nodes, ways, and relations according to the recommended interpretations found in http://wiki.openstreetmap.org/index.php/Map_Features, or if a user defined factory pipeline should be used.
This directive is used when generating workspaces and mapping files. As a result, it is not editable within Workbench after the workspace has been generated.
Values
COMMUNITY (default) | CUSTOM
The COMMUNITY_FEATURE_TYPES directive should be used in conjunction with this directive when this directive is set to ‘COMMUNITY’.
The CUSTOM_OSM_PIPELINE directive should be used in conjunction with this directive when this directive is set to ‘CUSTOM’.
Required/Optional
Optional
Mapping File Syntax
OSM_SCHEMA_CHOICE CUSTOM
Workbench Parameter
Feature Types
SCAN_ALL_FEATURES_FOR_SCHEMA
This optional directive specifies whether the OSM schema features should be retrieved by performing a full dataset scan or by manual selection from a list of predetermined feature types.
This directive is used when generating workspaces and mapping files. As a result, it is not editable within Workbench after the workspace has been generated.
Values
YES | NO (default)
Required/Optional
Optional
Mapping File Syntax
OSM_SCAN_ALL_FEATURES_FOR_SCHEMA
Workbench Parameter
Determine feature types by scanning entire dataset
COMMUNITY_FEATURE_TYPES
This optional directive is applicable when the SCHEMA_CHOICE
is set to COMMUNITY. It specifies the predefined FME factory pipeline that categorizes the nodes, ways, and relations into to the recommended interpretations found in http://wiki.openstreetmap.org/index.php/Map_Features.
This directive is used when generating workspaces and mapping files. As a result, it is not editable within Workbench after the workspace has been generated.
Required/Optional
Optional
Values
BROAD (default) | SPECIFIC | RAW
- BROAD (default): The OSM reader will use the
“{FME Folder”\xml\osm\schemaMap\osm_broad_schema.fmi”
to categorize the OSM data primitives into broader categories. Theosm_broad_schema.fmi
contains a sequence of FME factories that would assign a node, way, or relation an specific feature according to the existence of certain tag keys. For example, any way with a highway tag key regardless of its tag value will be categorized into a highway feature type. - SPECIFIC: the OSM reader will use the
“{FME Folder”\xml\osm\schemaMap\osm_specific_schema.fmi”
to categorize the OSM data primitives into more detailed categories. Theosm_specific_schema.fmi pipeline
contains a SchemaMappingFactory that loads a CSV file,{FME Folder}\xml\osm\schemaMap\osm_specific_schema.fmi
, to help it categorize the OSM data primitives according to the tag key and tag value. For example, any OSM way primitive with a highway tag key and tag value of primary will be categorized into ahighway_primary
feature type. - RAW: The OSM reader will leave the OSM nodes, ways, and relations unprocessed.
Mapping File Syntax
OSM_COMMUNITY_FEATURE_TYPES SPECIFIC
Workbench Parameter
OSM Community-Approved Feature Types
CUSTOM_OSM_PIPELINE
This optional directive is applicable when the SCHEMA_CHOICE
directive is set to CUSTOM
. It specifies a user-defined factory pipeline that can be used to transform the OSM nodes, ways and relations into user-defined feature types.
This directive is used when generating workspaces and mapping files. As a result, it is not editable within the Workbench after the workspace has been generated.
Required/Optional
Optional
Mapping File Syntax
OSM_CUSTOM_OSM_PIPELINE c:\my_osm_feature_categorization.fmi
Workbench Parameter
Custom Pipeline File:
SEARCH_ENVELOPE
Using the minimum and maximum x and y parameters, define a bounding box that will be used to filter the input features. Only features that interact with the bounding box are returned.
If all four coordinates of the search envelope are specified as 0, the search envelope will be disabled.
Mapping File Syntax
<ReaderKeyword>_SEARCH_ENVELOPE <minX> <minY> <maxX> <maxY>
Note: If all four coordinates of the search envelope are specified as zero, the search envelope will be disabled.
Required/Optional
Optional
Workbench Parameter
Minimum X, Minimum Y, Maximum X, Maximum Y
SEARCH_ENVELOPE_COORDINATE_SYSTEM
This directive specifies the coordinate system of the search envelope if it is different than the coordinate system of the data.
The COORDINATE_SYSTEM
directive, which specifies the coordinate system associated with the data to be read, must always be set if the SEARCH_ENVELOPE_COORDINATE_SYSTEM
directive is set.
If this directive is set, the minimum and maximum points of the search envelope are reprojected from the SEARCH_ENVELOPE_COORDINATE_SYSTEM
to the reader COORDINATE_SYSTEM
prior to applying the envelope.
Required/Optional
Optional
Mapping File Syntax
<ReaderKeyword>_SEARCH_ENVELOPE_COORDINATE_SYSTEM <coordinate system>
Workbench Parameter
Search Envelope Coordinate System
CLIP_TO_ENVELOPE
This directive specifies whether or not FME should clip features to the envelope specified in the SEARCH_ENVELOPE
directive.
Values
YES | NO (default)
Mapping File Syntax
<ReaderKeyword>_CLIP_TO_ENVELOPE [yes | no]
Workbench Parameter
Clip To Envelope
EXPOSED_ATTRS
This directive allows the selection of format attributes to be explicitly added to the reader feature type.
This is similar to exposing format attributes on a reader feature type once it has been generated; however, it is even more powerful because it enables schema-driven applications other than Workbench to access and leverage these attributes as if they were explicitly on the schema as user attributes.
The result of picking a list of attributes is a comma-separated list of attribute names and types that will be added to the schema features. Currently all reader feature types will receive the same set of additional schema attributes for a given instance of the reader.
Required/Optional
Optional
Mapping File Syntax
Not applicable.
While it is possible for FME Objects applications to invoke this directive, the required format is not documented.
This directive is intended for use in our GUI applications (for example, Workbench) only.
Workbench Parameter
Additional Attributes to Expose