ID: | AIXM-400 |
target version: | AIXM 5.2 |
version: | 1.1 |
last updated: | JUNE 2020 |
status: | UPDATE IN PROGRESS |
Description
This document describes data mapping solutions applied in the change proposals. It contains proposed rules for converting the AIXM data either “forward” (from the older version into the new version) or “backward” (from the new version into the older version).
Work in progress
This Change Proposal might be updated with additional mapping cases that appear in the latest change proposals.
Rationale for change
See https://aixmccb.atlassian.net/browse/AIXM-328
A new AIXM version can come with new features, properties or allowable values. In the same time, existing features, properties or allowable values may be deleted. Each change proposal is required to propose data mapping/conversion rules for all the elements affected.
In principle, similar mapping situations should be treated in similar ways. Therefore, the objective of this change proposal is to identify the generic mapping cases that could occur between two consecutive AIXM versions and to propose generic data conversion rules. This should also facilitate the writing of the other change proposals, which could refer to the identifier of each generic mapping case.
The following high-level principles are applied:
- No backwards mapping for complex new concepts
A new version might come with several new features and properties, that model a new concept, such as GNSS systems. In this situation, no backward mapping is really possible, since the current model does not have any class that would correspond to the new concept. The only solution for systems using a previous AIXM version and that are interested in the new data is to define and use an extension.
- Conversion rules are only recommendations
All forward and backward mapping / conversion rules are formulated as proposals only. The final decision to actually convert the data will depend on the actual user needs. For example, if a new attribute is introduced in a newer version, some users of the previous version might be willing to get the data as a simple text annotation, because they might have a specific need for that information, even if it implies manual processing by an operator. However, other users might not be interested at all in the new value and might just discard it.
- Annotations are not structured
When annotations are used in order to save some information from the newer version (such as a new property), they remain free text annotations. Annotations are not suitable for automatic processing and therefore it is not appropriate to use structured data inside an annotation, in order to mimic a new property and its values. Instead, if a system using an older AIXM version is really interested to get structured data for the new information that comes with the newer version, an extension shall be defined and used.
- Use OTHER:NEW_VALUE… for new codelist values
When new allowable values are introduced in a codelist in a newer AIXM version, they can always be mapped backwards using the codelist extension mechanism, which consists into prefixing the new value with “OTHER:”. This codelist extension mechanism was intentionally made available in AIXM version 5 for this purpose. The only limitation that needs to be kept in mind is that the maximum length of the coded value is 58 characters, so that it fits in the schema pattern for “OTHER:..”
- Some conversion rules should not be applicable to PERMDELTA TimeSlices
Conversion rules that result in the creation of a new annotation.Note should not be applied when working with PERMDELTA. Otherwise, each time a PERMDELTA is converted, a new annotation.Note may be created and saved in the BASELINE data, as there is no possibility to identify which existing annotation.Note might have been generated with a similar past mapping and which could be replaced. Therefore, such annotations risk to accumulate and duplicate each other after several conversions.
- Moving properties from a feature into another feature requires TimeSlices alignment
Some change proposals might move one or more, simple or complex properties from one feature into another feature. There are two extreme situations:
- a feature that becomes an object in the new model, which practically means that all the properties of one feature are transferred to another feature and the current feature does no longer exist;
- an object becomes a feature, which practically means that the object properties are transferred to a new feature. This is in fact the reverse mapping case of the previous bullet point.
In all such cases, the “recipient” feature timeline might need to be split with additional TimeSlices, in order to accommodate the possibly different timeline the properties concerned. The following diagram shows an example of a fictitious situation that falls in this category:
In this case, a property is moved from feature B into feature A. Within feature B, the property has no value during the validTime of the TimeSlice B/TS1, then it has two different values V1 and V2 during the validTime of the TimeSlices B/TS2 and B/TS3 respectively. The validity periods of the feature B TimeSlices is different from the validity periods of the feature A TimeSlices. When mapping the values of the property moved into feature A, the diagram shows that the TimeSlice structure of feature A needs to be changed, in order to correctly reflect the values of the additional property. For example, the TimeSlice A/TS2 needs to be split into two different TimeSlices, as the moved property will get a value V1 starting sometime in the middle of the validTime of the A/TS2 TimeSlice.
The process described above might be very difficult to apply to the complete set of TimeSlices of an existing feature. The recipient system might decide to limit this kind of mapping to the current and future BASELINE only.
Change Proposal details
This section identifies typical mapping cases that could occur between AIXM 5.1.1 and AIXM 5.2 and provides forward/backward mapping rules for each such case. In order to allow referencing these mapping cases from the change proposal concerned, each case is identified with the acronym “MAPC” (MAPping Case) followed by a two digit number. The same identifier is used in both the forwards and backwards mapping cases.
[MAPC-00] 1:1 conversions
Some change proposals might be fully 1:1 mappable between versions. For example, the change of a code used in a list of values without a change of the meaning. The mapping rules are provided directly in the change proposal concerned.
[MAPC-01] New or removed allowable value
In this case, a new value (“NEW_VAL”) is added in the new version to an existing AIXM CodeList or an existing value is deleted, as highlighted in the UML class diagram to the right.
All AIXM codelists allow the use of the value “OTHER:” followed by a coded value. Therefore, the forward mapping will use the “OTHER:OLD_VALUE”. It can also be assumed that OTHER:NEW_VAL is used as workaround for the missing value in the current model version. However, when this workaround mapping is applied, it should be verified that the OTHER:NEW_VAL in the previous AIXM version had exactly the same semantics as the NEW_VAL in the new AIXM version.
Forward mapping (from AIXM 5.1.1 to AIXM 5.2)
The forward mapping approach proposed in this case is as follows:
- Replace “OTHER:NEW_VAL” with “NEW_VAL”
- Replace “OLD_VALUE” with “OTHER:OLD_VALUE”
Backward mapping (from AIXM 5.2 to AIXM 5.1.1)
The backward mapping approach proposed in this case is as follows:
- Replace “NEW_VAL” with “OTHER:NEW_VAL”
[MAPC-02] New attribute or association to feature (simple property)
In this case, a new attribute (“newAtribute”) or a new association to another feature (“newAssociation”) is added to an existing class, as highlighted in the UML class diagrams to the right.
The new property models information that could not be coded in the existing version. Therefore, no data from the existing version can be mapped into the new attribute.
For the backwards mapping, several options are possible:
- in case the data recipient is not interested in the new information, the element may simply be removed. This option being straightforward, it is not further detailed.
- in case the data recipient needs the new information in structure format, an extension of the previous AIXM version needs to be defined and used. Obviously, this requires a system upgrade. This option being straightforward, it is not further detailed.
- as an intermediate solution, the new property may be converted into an annotation. This will not be suitable for automatic processing, but it might be still useful in case the data recipient is interested to know that the new information exists. In addition, if the new property is logically related to an existing property, the backwards created Note can be specified as being associated with that existing property.
Forward mapping (from AIXM 5.1.1 to AIXM 5.2)
Not applicable.
Backward mapping (from AIXM 5.2 to AIXM 5.1.1)
From the three backward mapping options discussed above, the first two (discard the value or use an extension) are straightforward and do not need any further details. The 3rd option (backward mapping into a Note) is detailed in order to provide a complete description of this case and its conversion option. The following mapping into Note algorithm is proposed:
- Remove the new element
- Add an annotation.Note associated with the owner class having
- purpose=“OTHER:BACKWARD_MAPPING”;
- translatedNote.LinguisticNote.note=”newValue: <newValue> <uom>, where
- <newValue> is the actual value of the newAttribute or of the newRole.xlink:href;
- <uom> is the value of the unit of measurement associated with the newAttribute data type, if applicable;
- if the current model has a property that is logically related, then the name of that property shall be used as the Note.propertyName value.