CARIS BASE Editor : Support Files Guide : HCRF Configuration : Metadata Mapping File
 

Metadata Mapping File

Chart metadata is mapped to HCRF during export using the caris2hcrf_metadata.xml file.

Custom attributes can also be used. For example, if the Chart Comments (CHTCOM) attribute is replaced with a custom attribute, that attribute can be recorded in the metadata file.

This is a graphical representation of the file structure.

The following table describes each element in the file including:

if the attribute is a mandatory requirement for HCRF export

the attribute in PCE to which the HCRF attribute is mapped

if a custom attribute can be used in place of the PCE attribute

any additional information or error messages

Element

Description

<ChartMappings>

<CountryOfOrigin>

Alphanumeric value to identify the Country of Origin for the chart version.

Mandatory: Yes

Default chart attribute: PUBCON

Example: <CountryOfOrigin>PUBCON</CountryOfOrigin>

Custom attribute allowed: No

An error is reported if the value is not recorded in the caris2hcrf_countries.txt or if the translated value is not in COUNTRY.TAB

<EditionDate>

Date value to identify the Edition Date.

Mandatory: Yes

Default chart attribute: EDDATE

Example: <EditionDate>EDDATE</EditionDate>

Custom attribute allowed: No

The date is written to HCRF in YYYYMMDD format.

<ChartNumber>

Alphanumeric chart identifier.

Mandatory: Yes

Default chart attribute: CHTNUM

Example: <ChartNumber>CHTNUM</ChartNumber>

Custom attribute allowed: No

An error is reported if the chart ID is greater than eight characters.

<LatestNM>

Integer value for the latest Notice to Mariners on the image.

Mandatory: No

Default chart attribute: LTSTNM

Example: <LatestNM>LTSTNM</LatestNM>

Custom attribute allowed: No

The value is NNNNN/YY. An empty value indicates a new edition.

<MainTitle>

Alphanumeric value for main title.

Mandatory: Yes

Default chart attribute: CTITL1

Example: <MainTitle>CTITL1</MainTitle>

Custom attribute allowed: No

Title can exceed a maximum of 100 characters (HCRF limit). If character length exceeds the limit, then <ShortMainTitle> is used.

When non-ASCII character are used for panel or chart titles, the string is written in long normalized form minus non-ASCII characters.

<ShortMainTitle>

Alphanumeric value for main title

Mandatory: Yes if <MainTitle> is greater than 100 characters. The value will be truncated to 100 characters if necessary.

Default chart attribute: STITL1

Example: <ShortMainTitle>STITL1</ShortMainTitle>

Custom attribute allowed: Yes

An error is reported if attribute is needed but not found.

An error is reported if the <MainTitle> value is longer than 100 characters and this value is not set.

When non-ASCII character are used for panel or chart titles, the string is written in long normalized form minus non-ASCII characters.

<IntNumber>

Alphanumeric value for INT number

Mandatory: No

Default chart attribute: INTNUM

Example: <IntNumber>INTNUM</IntNumber>

Custom attribute allowed: No

An error is reported if the value is longer than five characters.

<IntProducer1>

Alphanumeric value for the producer of the INT version

Mandatory: Yes if <IntNumber> has a value

Default chart attribute: INTPR1

Example: <IntProducer1>INTPR1</IntProducer1>

Custom attribute allowed: No

Errors are reported for the following conditions:

if value is set but <IntNumber> is not set

if value is not set but <IntNumber> is set

if value is set but not listed in caris2hcrf_countries.txt

if value is set but translated value is not listed in COUNTRY.TAB

<IntProducer2>

Alphanumeric value for producer of INT version (2)

Mandatory: No

Default chart attribute: INTPR2

Example: <IntProducer2>INTPR2</IntProducer2>

Custom attribute allowed: No

Errors are reported for the following conditions:

value is set but <IntNumber> is not set

value is not set but <IntNumber> is set

value is set but not listed in caris2hcrf_countries.txt

value is set but translated value is not listed in COUNTRY.TAB

<ExplanatoryText>

Alphanumeric value for Explanatory Text

Mandatory: No

Default chart attribute: HCREXP

Example: <ExplanatoryText>HCREXP</ExplanatoryText>

Custom attribute allowed: Yes

Text is truncated to 500 characters.

If the attribute does not have a value, text is copied from the <explanatoryTextRcd> element in raster control file.

An error message is reported if text is not printable.

<PaletteId>

Enumerated value for PAL lookup table record.

Mandatory: Yes

Default chart attribute: HCRPAL

Example: <PaletteId>HCRPAL</PaletteId>

Custom attribute allowed: Yes

PCE uses the enumeration code as the palette ID.

The value of the palette ID is also used when PCE looks for day dusk and night colour tokens files. The palette ID is written to the .PAL lookup table Palette ID field which is a one unsigned byte field.

<ChartType>

Enumeration for chart type (not written to HCRF)

Mandatory: Yes

Default chart attribute: CHTYPE

Example: <ChartType>CHTYPE</ChartType>

Custom attribute allowed: No

The attribute value is used to determine the relevant RCS from the rcsControl.xml

<SheetMappings>

<SheetOfPlans>

Enumeration to determine if chart is a Sheet of Plans

Mandatory: Yes

Default chart attribute: TSHEET

Example: <SheetOfPlans>TSHEET</SheetOfPlans>

Custom attribute allowed: No

The attribute is not written to HCRF

<SopTrueValue>

A value of “Harbour Plans” in TSHEET indicates that the chart is part of a sheet of plans.

Example: <SopTrueValue>Harbour Plans</SopTrueValue>

<PanelMappings>

<PanelNumber>

Integer for Sub-Panel Number also used as xx in .Pxx and Nxx files.

Mandatory: Yes

Default chart attribute: PANNUM

Example: <PanelNumber>PANNUM</PanelNumber>

Custom attribute allowed: No

Errors are reported for the following conditions:

values for panels are not unique

values do not form unbroken numerical sequence, starting at 0 if not sheet of plans, or 1 if sheet of plans

value is greater than 99

<PanelTitle>

Alphanumeric value for panel title

Mandatory: Yes

Default chart attribute: PANNAM

Example: <PanelTitle>PANNAM</PanelTitle>

Custom attribute allowed: No

If panel title exceeds 100 characters then <ShortPanelTitle> is used.

<ShortPanelTitle>

Alphanumeric value for panel title.

Mandatory: Yes if the panel name is greater than 100 characters. The panel name is truncated if necessary.

Default chart attribute: SPNNAM

Example: <ShortPanelTitle>SPNNAM</ShortPanelTitle>

Custom attribute allowed: Yes

Errors are reported for the following conditions:

attribute is required but not found

<PanelMainTitle> is greater than 100 characters and the attribute value is not set

<Projection>

Alphanumeric value for Projection (parameters 1-4)

Mandatory: Yes

Default chart attribute: PRJCTN

Example: <Projection>PRJCTN</Projection>

Custom attribute allowed: No

Errors are reported for the following conditions:

Value parsed from PRJCTN is in caris2hcrf_projections.txt

Translated value not listed in PROJCODE.TAB

<Scale>

Integer for Projection Scale

Mandatory: Yes

Default chart attribute: PSCALE

Example: <Scale>PSCALE</Scale>

Custom attribute allowed: No

<HorizontalDatum>

Alphanumeric value for Horizontal Datum

Mandatory: Yes

Default chart attribute: DATUM

Example: <HorizontalDatum>DATUM</HorizontalDatum>

Custom attribute allowed: No

Errors are reported for the following conditions:

Value not found in caris2hcrf_horizontalDatums.txt

Translated horizontal datum code not found in HORDAT.TAB

Translated spheroid code not found in HcrfSpheroids.txt

<DepthUnits>

Alphanumeric value for Depth Units

Mandatory: Yes

Default chart attribute: DEPUNT

Example: <DepthUnits>DEPUNT</DepthUnits>

Custom attribute allowed: No

Errors are reported for the following conditions:

Value not found in caris2hcrf_verticalUnits.txt

Translated vertical units code not found in UNITS.TAB

<DepthDatum>

Alphanumeric value for Depth Datum

Mandatory: Yes

Default chart attribute: DEPDAT

Example: <DepthDatum>DEPDAT</DepthDatum>

Custom attribute allowed: No

Errors are reported for the following conditions:

Value not found in caris2hcrf_verticalDatums.txt

Translated vertical datum code not found in VERDAT.TAB

<HeightUnits>

Alphanumeric value for Height Units

Mandatory: Yes

Default chart attribute: HGHTUN

Example: <HeightUnits>HGHTUN</HeightUnits>

Custom attribute allowed: No

Errors are reported for the following conditions:

Value not found in caris2hcrf_verticalUnits.txt

Translated vertical units code not found in UNITS.TAB

<HeightDatum>

Alphanumeric value for Height Datum

Mandatory: Yes

Default chart attribute: HGHTDA

Example: <HeightDatum>HGHTDA</HeightDatum>

Custom attribute allowed: No

Errors are reported for the following conditions:

Value not found in caris2hcrf_verticalDatums.txt.

Translated vertical datum code not found in VERDAT.TAB.

<WgsShiftNs>

Numeric value for WGS84 shift data N/S in minutes

Mandatory: Yes if the HCRF horizontal datum code is listed in wgs84Relationships.xml.

Default chart attribute: SHFTNS

Example: <WgsShiftNs>SHFTNS</WgsShiftNs>

Custom attribute allowed: No

Errors are reported for the following conditions:

Value translated from DATUM is considered equivalent to WGS-84 and the <WgsShiftNs> value is non-zero. (Do not report error if the value is undefined: assume it is 0.)

Value translated from DATUM is considered UndeterminedShiftsUnknown with respect to WGS-84 and the <WgsShiftNs> has a value. (It should not have any value since shifts are supposedly unknown)

<WgsShiftNs> is supposed to have a value but does not have a value

<WgsShiftNs> is supposed to have a value, and does have a value, but <WgsShiftEw> does not have a value

<WgsShiftNs> value is not in range -99.99...99.99

<WgsShiftEw>

Numeric value for WGS84 shift data E/W in minutes.

Mandatory: Yes if the HCRF horizontal datum code is listed in wgs84Relationships.xml.

Default chart attribute: SHFTEW.

Example: <WgsShiftEw>SHFTEW</WgsShiftEw>

Custom attribute allowed: No.

Errors are reported for the following conditions:

<WgsShiftEw> has a value but <WgsShiftNs> does not have a value.

Value is not in range -99.99 to 99.99.

<PanelType>

Enumerated value to determine whether or not to skip creation on Pxx/Nxx files for this panel. List of enumeration values are in excludedPanelTypes.txt.

Mandatory: Yes.

Default chart attribute: PANTYP

Example: <PanelType>PANTYP</PanelType>

Custom attribute allowed: No