Writer Directives
The suffixes shown are prefixed by the current <WriterKeyword>
in a mapping file. By default, the <WriterKeyword>
for the FFS writer is FFS
.
DATASET
The value for this directive is the destination file name for the FFS files.
Required/Optional
Required
Mapping File Syntax
A typical mapping file fragment specifying an output FFS dataset:
<WriterKeyword>_DATASET /usr/data/ffs/new.ffs
Workbench Parameter
Destination FME Feature Store (FFS) File
DEF
The definition lists only the feature type of those features to be written to the file.
Required/Optional
Optional
Mapping File Syntax
The syntax of the DEF directive is:
<WriterKeyword>_DEF <baseName>
[<attrName> <attrType>]+
This fragment defines a feature type in the FFS file for all features whose feature type was roads:
<WriterKeyword>_DEF roads
INDEXED
This flag indicates whether or not a spatial index should be created and saved along with the output FFS file.
The spatial index has the same base name as the FFS file, but it will have an .fsi
extension. Spatial indexes are needed if the FFS file is later used as the source for spatial queries by the FFS reader.
Note: If a spatial index has been requested, this forces a non-compressed output .ffs
file to allow for efficient random access.
Required/Optional
Optional
Mapping File Syntax
This fragment specifies that a spatial index should be created:
<WriterKeyword>_INDEXED yes
Workbench Parameter
Create Spatial Index
STRICT_SCHEMA
This flag indicates whether or not features should be modified to adhere to the schema. This may include removing all user attributes not listed on the DEF line before they are saved, or enforcing that attribute types match the type specified on the schema.
Strictly adhering to a schema can, in some cases, greatly reduce file size by removing unnecessary attributes. Additionally, enforcing both names and types may dramatically improve read performance of the output file.
Values
no (default) | names | names_and_types
If set to no, features will be saved without modification.
If set to names, attributes not specified on the schema will be stripped.
If set to names_and_types, attributes not specified on the schema will be stripped, and attributes specified on the schema will be saved with the specified type.
Required/Optional
Optional
Mapping File Syntax
This fragment specifies that all features strictly adhere to the defined schema:
<WriterKeyword>_STRICT_SCHEMA names_and_types
Workbench Parameter
Enforce Strict Schema (Workbench Navigator pane)
Note:
- In Workbench Navigator parameters, Enforce Strict Schema = Yes corresponds to STRICT_SCHEMA = names_and_types
- In Workbench Navigator parameters, Enforce Strict Schema = No corresponds to STRICT_SCHEMA = no
MAX_FILE_SIZE
This directive (which is not generally used) limits the size of each FFS file.
If a file exceeds the specified number of bytes, it will be closed and a new file with a numeric suffix starting at 1 will be created. A single spatial index is created for the group of files.
Required/Optional
Optional
Mapping File Syntax
<WriterKeyword>_MAX_FILE_SIZE 1000000
Workbench Parameter
Maximum FFS File Size, in Bytes
PASSPHRASE
This specification is used to encrypt the output dataset for additional security. This exact passphrase must be used to decrypt this dataset when it is read in again.
If this directive is not used when writing the output dataset, it is not necessary to specify it when reading it in again.
Required/Optional
Optional
Mapping File Syntax
<WriterKeyword>_PASSPHRASE <character string>
Workbench Parameter
Password
COMPRESSION
A lower COMPRESSION_LEVEL
value will result in faster operation for both reading and writing, while a higher compression level will result in smaller file sizes.
Note: If a spatial index has been requested, this forces a non-compressed output .ffs
file, regardless of this value, to allow for efficient random access.
Required/Optional
Optional
Values
0 to 9
Default Value: 0
Mapping File Syntax
<WriterKeyword>_COMPRESSION_LEVEL 0
Workbench Parameter
Compression Level
BYTE_ORDER
The directive BYTE_ORDER indicates whether the resulting file should be optimized for either LITTLE_ENDIAN or BIG_ENDIAN machines.
For example, the architecture of machines running Microsoft Windows is little endian.
Required/Optional
Optional
Values
Default Value: NATIVE
The BYTE_ORDER of NATIVE means the file should be optimized for the type of machine on which it is currently running.
Note: All files created can be read back on machines of either byte order; the only issue is that reading back files optimized for the opposite byte order will take slightly longer.
Mapping File Syntax
<WriterKeyword>_BYTE_ORDER LITTLE_ENDIAN
Workbench Parameter
Byte Order
FILE_DEST_DATASET
This writer directive allows the FFS writer to write to single files instead of folders (early versions of the FFS writer wrote only to folders).
This directive is supplied by default in all newly generated workspaces.
Note: If you are using this writer through the FMEObjects SDK, the old behavior will still apply and you will need to use this directive to enable the new behavior. If a folder output is still required, you might consider using Fanout Dataset in Workbench.
Required/Optional
Optional
Values
Default Value: YES
Mapping File Syntax
<WriterKeyword>_FILE_DEST_DATASET YES