Description
The MapFeatures process converts input features and saves them to the output.
An XML mapping rule file is used to associate features that are defined in an input catalogue to features that are defined in an output catalogue in order to convert them. For example, S-57 features may be converted to VPF features using an ENC-to-DNC mapping rule file.
Input
Features in a supported format. HOB, H2O, 000 (S-57 or S-101 specification) and HPD URIs are supported as well as OGR sources such as Shapefile and GML.
Shapefiles must be in CARIS Shapefile Format and use a recognized Shapefile Coordinate Reference System.
Output
HOB file, H2O file or HPD URI. An HPD URI must specify the project to use and either a usage or a product to update.
If an output HOB or H2O file already exists, it is overwritten.
Command Line Syntax
carisbatch --run MapFeatures [options] <input> <output>
Options
Long | Short | Description | Can Repeat | Notes |
|---|---|---|---|---|
--input-feature-catalogue | -i | A string specifying the name of the catalogue that defines the input features and attributes. The available catalogues are controlled by the Catalogue Control file. An example of a catalogue name is "S-57 ENC 3.1". | FALSE | Optional. Required only if the input is a HOB file. If the input is not a HOB file and this option is used, a warning message reports that the option has been ignored. |
--output-feature-catalogue | -o | A string specifying the name of the catalogue that defines the output features and attributes. The available catalogues are controlled by the Catalogue Control file. An example of a catalogue name is "S-57 ENC 3.1". | FALSE | Optional. Required only if the output is a HOB or H20 file. If the output is not a HOB or H20 file and this option is used, a warning message reports that the option has been ignored. |
--mapping-rules | -p | Name of the mapping rules for converting features. This is shown in the Name field in an XML mapping table (e.g., S-57 3.1 to S-101 1.0). | FALSE | Optional. Replaces the mapping rule file option. |
--keep-foid | -k | If set, the feature object identifiers (FOIDS) of the input are used for the output features when they are unique in the output. If not set, new FOIDs are assigned for all mapped features. This option applies only for S-57/S-100 feature mapping. A warning is issued if this option is used with any other input format. For 1:1 mapping, FOIDs are kept. For 1:many mapping, the FOID from the input feature is assigned to the first mapped feature. Subsequent features mapped from the same input feature are assigned a new FOID. For many:1 mapping, the FOID from the first input feature mapped is assigned to the mapped feature. In all cases, if a FOID creates a duplicate FOID in the output map, a new FOID is generated. | FALSE | Optional. |
Examples
HOB file | ||
Objective | Convert S-57 features to VPF features using an ENC-to-DNC mapping rule file, and save the results to a HOB output file. | |
Description | Command Line Syntax | |
Keep FOIDs of the input features in the output. |
| |
Feature catalogue for the input file. |
| |
Feature catalogue for the output file. |
| |
XML mapping rule file to use when converting features. |
| |
Path of the input file. |
| |
Path of the output file. |
| |
Command Line |
| |
Outcome | A new file is created in the specified location with features converted according to the specified mapping rule file. | |
HOB file | ||
Objective | Convert Shapefile features to VPF features using an ENC-to-DNC mapping rule file. | |
Description | Command Line Syntax | |
XML mapping rule file to use when converting features. |
| |
Path of the input file in a supported format. |
| |
HPD Product URI. |
| |
Command Line |
| |
Outcome | The HPD usage is updated with features converted according to the specified mapping rule file. | |
S-57 to S-101 HPD database | ||
Objective | Convert S-57 features to S-101 features using an S-57-to-S-101 mapping rule file, and save the results to a HPD S-101 database usage. | |
Description | Command Line Syntax | |
Keep FOIDs of the input features in the output. |
| |
Feature catalogue for the input file. |
| |
Feature catalogue for the output file. |
| |
XML mapping rule file to use when converting features. | --mapping-rules "S-57 3.1 to S-101 1.4.1" | |
Path of the input file. | D:\S-57dataset.000 | |
Path of the output file. | hpd://username:password@database?UsageId=1;ProjectId=1234 | |
Command Line |
| |
Outcome | The HPD usage is updated with features converted according to the specified mapping rule file. | |