Reader Directives

Workbench reader parameters are displayed in the Workbench Navigator. These parameters are the equivalent of FME reader mapping file directives, which are listed in the table below each parameter. Most (but not all) directives correspond directly to a Workbench parameter.

The directives that are processed by the reader are also listed below. The suffixes shown are prefixed by the current <ReaderKeyword>_ in a mapping file. By default, the <ReaderKeyword> for the reader is FMESERVERREPOSITORY.

DATASET

This specifies the machine running an FME Server instance to read from as either an IP address or host name. The FME Server must have proper permissions and be set up correctly to accept connections from a remote machine.

Required/Optional

Required

Mapping File Syntax

DATASET myfmeserver 

Workbench Parameter

Source FME Server Repository Host

REPOSITORY_PORT

When connecting remotely, this directive specifies the TCP/IP port through which to connect to the FME Server.

The default port is 7071.

Required/Optional

Required

Mapping File Syntax

REPOSITORY _PORT 7071

Workbench Parameter

Port

REPOSITORY_USERNAME

This directive contains the name of user who will access the FME Server. The named user must exist with appropriate permissions.

The default user name is admin.

Required/Optional

Required

Mapping File Syntax

REPOSITORY _USERNAME admin

Workbench Parameter

Username

REPOSITORY_PASSWORD

This directive contains the password of the user accessing the database.

Required/Optional

Required

Mapping File Syntax

REPOSITORY _PASSWORD password

Workbench Parameter

Password

REPOSITORY_SAVE_TEMP_FILES

This directive determines whether the files downloaded from the repositories will be saved in a user’s temp folder after the translation has completed.

The default is no, which means the downloaded files will be deleted from user’s temp folder after all features have been read.

Required/Optional

Optional

Mapping File Syntax

REPOSITORY _SAVE_TEMP_FILES <yes|no>

Workbench Parameter

Save temporary repository files

DEF

Required/Optional

Required

Mapping File Syntax

The syntax of the definition is:

FMESERVEREPOSITORY_DEF <repository name> \
 repository_name varchar(255) \
 repository_description buffer \
 repository_item_id int32 \
 repository_item_name varchar(255) \
 repository_item_path buffer \
 [repository_item_resource_name{} varchar(255) \] + 
 [repository_item_resource_path{} buffer \] +
 [repository_item_property_key{} varchar(255) \] +
 [repository_item_property_value{} buffer \] +
 [repository_item_property_key{}.attribute_key{} varchar(255) \] +
 [repository_item_property_key{}.attribute_value{} buffer] +

OR

FMESERVEREPOSITORY FMESERVERSERICES \
 repository_service_id int32 \
 repository_service_name varchar(255) \
 repository_service_displayname varchar(255) \
 repository_service_urlpattern buffer \
 repository_service_description buffer \
 repository_service_allow_workspace_registration \
 [repository_service_workspace{} buffer \] +
 [repository_ service_category_name{} varchar(255) \] +
 [repository_service_category_name{}.property_key{} varchar(255) \] +
 [repository_service_category_name{}._property_value{} buffer \] +
 [repository_service_category_name{}._property_key{}.attribute_key{} varchar(255) \] +
 [repository_service_category_name{}._property_key{}.attribute_value{} buffer] +

The <repository name> must match the name of an existing repository in the FME Server. This will be used as the feature type of all the repository items read from the repository.

The <attrType> of each field must be given, but it is not verified against the database definition for the field. In effect, it is ignored.

The following table shows the attribute types supported.

Field Type

Description

varchar(<width>)

Character fields store variable length strings. The width parameter controls the maximum number of characters that can be stored by the field. No padding is required for strings shorter than this width.

buffer(<width>)

Character fields store fixed length strings.

The width parameter controls the maximum number of characters that can be stored by the field. No padding is required for strings shorter than this width.

number(<width>,<decimals>)

Number fields store single and double precision floating point values.

The width parameter is the total number of characters allocated to the field, including the decimal point. The decimals parameter controls the precision of the data and is the number of digits to the right of the decimal.

logical Logical fields store a Boolean value in the form of 0 or 1, or Yes or No.

The following example shows a basic repository feature type.

FMESERVEREPOSITORY _DEF MYREP \
 repository_name varchar(255) \
 repository_description buffer \
 repository_item_id int32 \
 repository_item_name varchar(255) \
 repository_item_path buffer

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