Reader Directives

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

DATASET

Required/Optional: Required

The value for this directive is the URL for the WMS server. A typical URL specifying a WMS server looks like:

WMS_DATASET http://www.fmeserver.com/wms

Workbench Parameter: Web Map Service URL

MINX, MINY, MAXX, MAXY

Required/Optional

Optional

These optional directives are used to specify the value of the rectangular bounding box parameter value that is submitted during a request for feature information.

The syntax for the values of these directives is:

<ReaderKeyword>_MINX <value>

<ReaderKeyword>_MINY <value>

<ReaderKeyword>_MAXX <value>

<ReaderKeyword>_MAXY <value>

All values must be specified in decimal, integer or scientific notation.

If all values for MINX, MINY, MAXX and MAXY have a value of 0, then the default bounding boxes for the selected layers are used.

Workbench Parameter:

Search Envelope Min X, Search Envelope Min Y, Search Envelope Max X, Search Envelope Max Y

DEF

Required/Optional

Required

The syntax for a WMS DEF line is:

<ReaderKeyword>_DEF <feature-type> \
		wms_selected_layers set(layer1,layer2,...,layerN)

Where “layer1,layer2,...,layerN” in the “wms_selected_layers” attributes lists the layers selected for the particular image represented by the DEF line. If one and only one layer is selected then “layer1” will match the “feature-type”, otherwise, “feature-type” will be the name for requested layers’ common parent layer.

HTTP_AUTH_USER

Required/Optional

Optional

This optional directive specifies the user name when accessing a password protected HTTP server. The directive has no default value.

Example

<ReaderKeyword>_HTTP_AUTH_USER someusername

Workbench Parameter

Http Authentication User

HTTP_AUTH_PASSWORD

Required/Optional: Optional

This optional directive specifies the password when accessing a password protected HTTP server. The directive has no default value.

Example:

<ReaderKeyword>_HTTP_AUTH_PASSWORD my123secret

Workbench Parameter: Http Authentication Password

HTTP_AUTH_METHOD

Required/Optional

Optional

This optional directive specifies the authentication method when accessing a password protected HTTP server. Valid values for this directive are “Basic”, “Digest” and “NTLM”. The default value is “Basic”.

Note: The HTTP basic access authentication is a mechanism designed to allow a client to provide credentials to a server on the assumption that the connection between them is trusted and secure. That is, any credentials passed from client to server can be easily intercepted through an insecure connection.

Example:

<ReaderKeyword>_HTTP_AUTH_METHOD Digest

Workbench Parameter

Http Authentication Method

HTTP_PROXY

Required/Optional

Optional

This optional directive specifies the HTTP proxy to be used for network fetches. The port number may be specified at the end the proxy by appending :[port number] or through the HTTP_PROXY_PORT directive.

Example:

<ReaderKeyword>_HTTP_PROXY www.someproxy.net

or

<ReaderKeyword>_HTTP_PROXY www.someproxy.net:8081

Note: Users may bypass the HTTP_PROXY and HTTP_PROXY directives and still have http proxy support by specifying the http_proxy environment variable. The value for this environment variable should be of the form [protocol://][user:password@]machine[:port], where components within [] are optional. An example value for the http_proxy environment variable is: www.someproxy.net:8081.

Workbench Parameter

Proxy Address

HTTP_PROXY_PORT

Required/Optional

Optional

This optional directive is used if the HTTP proxy port was not specified in the HTTP_PROXY directive.

Example

<ReaderKeyword>_HTTP_PROXY_PORT 8081

Workbench Parameter

Proxy Port

HTTP_PROXY_USER

Required/Optional

Optional

This optional directive specifies the user name when accessing a password protected proxy server. The directive has no default value.

Example:

<ReaderKeyword>_HTTP_PROXY_USER someusername

Workbench Parameter

Proxy User

HTTP_PROXY_PASSWORD

Required/Optional

Optional

This optional directive specifies the password when accessing a password protected proxy server. The directive has no default value.

Example:

<ReaderKeyword>_HTTP_PROXY_PASSWORD my123secret

Workbench Parameter

Proxy Password

HTTP_PROXY_AUTH_METHOD

Required/Optional

Optional

This optional directive specifies the authentication method when accessing a password protected proxy server. Valid values for this directive are “Basic”, “Digest” and “NTLM”, with “Basic” being the default value.

Example

<ReaderKeyword>_HTTP_PROXY_AUTH_METHOD Digest

Workbench Parameter

Proxy Authorization Method

SRS

Required/Optional

Optional

This optional directive specifies the desired coordinate system. The default value is “CRS:84” for WMS 1.3.0 and “EPSG:4326” for WMS 1.1.0 and 1.1.1.

Example:

<ReaderKeyword>_SRS EPSG:32610

Workbench Parameter

SRS

TRANSPARENT

Required/Optional

Optional

This optional directive sets the background transparency for a map. The map server will send an image with transparent background when this directive is set to “Yes” and the image format supports transparency (e.g., PNG and GIF). The default value for this directive is “No”.

Example:

<ReaderKeyword>_TRANSPARENT Yes

Workbench Parameter

Transparent Map Background

SPLIT_REQUESTS

Required/Optional

Optional

When set to “Yes” this directive instructs the WMS reader to split the selected layers into separate HTTP Get Requests, i.e., if N layers are selected then N separate HTTP GetMap requests are performed fetching N images. The default value for this directive is “No”.

Example:

<ReaderKeyword>_SPLIT_REQUESTS Yes

Workbench Parameter:

Split GetMap Request

MAP_HEIGHT

Required/Optional: Optional

This optional directive specifies the height in pixels for the image. The default value for this directive is “300”.

Example:

<ReaderKeyword>_MAP_HEIGHT 600

Workbench Parameter: Image Height

MAP_WIDTH

Required/Optional: Optional

This optional directive specifies the width in pixels for the image. The default value for this directive is “560”.

Example:

<ReaderKeyword>_MAP_WIDTH 800

Workbench Parameter: Image Width

MAP_FORMAT

Required/Optional: Optional

This optional directive specifies the image output format as a MIME type. The output format must be one of the formats listed in the WMS capabilities document. The directive defaults to “image/png”.

Example:

<ReaderKeyword>_MAP_FORMAT image/gif

Workbench Parameter: Image Width

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