Slide 18 of 26
Notes:
After identifying where the information is in the source schema, the next step is to define the mappings.
Basically, defining the mappings means describing how data that conforms to one or more source schemas is mapped into a target (or view) schema.
In general, the definition of the mappings requires the following information :
- The source schema(s): from which the view will be derived (AP210 for the board outline example). In general, there could be more than one base schema.
- The target schema: product model for the materialized view - i.e., the entity types that will be in the view and the attributes for each of these entity types. (the APM in our example)
- Source entities: the entities in the source schema from which the entities in the target schema will be created. (shape_definition_representations in our example)
- Target entities: the entities in the target schema that will be created from the source entities (xy_coordinates).
- Mapping conditions: the conditions that must be true for a new view instance to be created. In the example, there is only one mapping condition, which states that only shape_definition_representations whose definition attribute is a product_definition_shape, whose definition attribute is an inter_stratum_feature, whose name attribute is a string equal to board outline, will be taken into account for the mapping.
- Mapping assignments: how the values of each attribute of a new view instance are computed. In our example, the mapping assignments specify how instances of xy_coordinate are created from the end points of each line and trimmed curve that define the outline of the board in the AP210 file. The pseudocode of this mapping assignments is shown in the next slide.