(*
 * $Id$
 *
 * JSDAI(TM), a way to implement STEP, ISO 10303
 * Copyright (C) 1997-2008, LKSoftWare GmbH, Germany
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU Affero General Public License
 * version 3 as published by the Free Software Foundation (AGPL v3).
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 * See the GNU Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 *
 * JSDAI is a registered trademark of LKSoftWare GmbH, Germany
 * This software is also available under commercial licenses.
 * See also http://www.jsdai.net/
 *)

(*schema_mapping assembly_module_design(Assembly_module_design_arm, Assembly_module_design_mim);*)
entity_mapping Assembly_connection_zone_position_relationship(Assembly_connection_zone_position_relationship, representation_relationship_with_transformation);

mapping_constraints;
{representation_relationship_with_transformation <=
representation_relationship
representation_relationship.name = 'design view connection zone position relationship'}

end_mapping_constraints;

attribute_mapping associating_design_view_shape(associating_design_view_shape, $PATH, Shape_representation);
representation_relationship_with_transformation <=
representation_relationship
representation_relationship.rep_1 ->
{representation
representation.name = 'design view shape'}
representation =>
shape_representation

end_attribute_mapping;

attribute_mapping associated_usage(associated_usage, $PATH, Connection_zone_in_design_view);
representation_relationship_with_transformation <=
representation_relationship
representation_relationship.rep_2 ->
{representation
representation.name = 'zone shape'}
{representation =>
shape_representation}
representation <-
property_definition_representation.used_representation
property_definition_representation
property_definition_representation.definition ->
property_definition
property_definition.definition ->
characterized_definition
characterized_definition = shape_definition
shape_definition
shape_definition = shape_aspect
shape_aspect
{shape_aspect
shape_aspect.description = 'connection zone'}

end_attribute_mapping;

attribute_mapping associated_connection_zone_shape_definition(associated_connection_zone_shape_definition, $PATH, Shape_representation);
representation_relationship_with_transformation <=
representation_relationship
representation_relationship.rep_2 ->
{representation
representation.name = 'zone shape'}
representation =>
shape_representation

end_attribute_mapping;

attribute_mapping associated_usage_placement(associated_usage_placement, $PATH, axis2_placement);
representation_relationship_with_transformation
representation_relationship_with_transformation.transformation_operator ->
transformation
transformation = item_defined_transformation
item_defined_transformation.transform_item_1 ->
representation_item =>
geometric_representation_item =>
placement

end_attribute_mapping;

attribute_mapping associating_design_view(associating_design_view, $PATH, Part_design_view);
 representation_relationship_with_transformation <=
representation_relationship
representation_relationship.rep_1 ->
{representation =>
shape_representation}
representation <-
property_definition_representation.used_representation
property_definition_representation
property_definition_representation.definition ->
property_definition =>
product_definition_shape =>
physical_unit

end_attribute_mapping;

end_entity_mapping;

entity_mapping Assembly_module(Assembly_module, physical_unit);

mapping_constraints;
[physical_unit <=
product_definition_shape <=
property_definition
{property_definition.name = 'assembly module'}]
[physical_unit <=
product_definition
/SUPERTYPE(Assembly_definition_armx)/]


end_mapping_constraints;

end_entity_mapping;

entity_mapping Bare_die_component_armx(Bare_die_component_armx, bare_die_component);

mapping_constraints;
bare_die_component <=
physical_component <=
assembly_component <=
component_definition <=
product_definition
/SUPERTYPE(Assembly_definition_armx)/

end_mapping_constraints;

attribute_mapping derived_from(derived_from, $PATH, Bare_die_armx);
bare_die_component <=
physical_component <=
assembly_component <=
component_definition <=
product_definition <-
product_definition_relationship.related_product_definition
product_definition_relationship
{product_definition_relationship
product_definition_relationship.name = 'definition usage'}
product_definition_relationship.relating_product_definition ->
product_definition =>
physical_unit =>
bare_die

end_attribute_mapping;

end_entity_mapping;

entity_mapping Bare_die_component_terminal(Bare_die_component_terminal, physical_component_terminal);

mapping_constraints;
 physical_component_terminal <=
component_terminal <=
component_feature <=				
shape_aspect
{shape_aspect
[shape_aspect.description = 'bare die component terminal']
[shape_aspect.product_definitional = .TRUE.]}

end_mapping_constraints;

attribute_mapping associated_component(associated_component, $PATH, Bare_die_component_armx);
physical_component_terminal <=
component_terminal <=
component_feature <=	
shape_aspect
shape_aspect.of_shape ->
product_definition_shape =>
assembly_component =>
physical_component =>
bare_die_component

end_attribute_mapping;

attribute_mapping definition(definition, $PATH, Bare_die_terminal_armx);
physical_component_terminal <=
component_terminal <=
component_feature <=	
shape_aspect <-
shape_aspect_relationship.related_shape_aspect
shape_aspect_relationship
{shape_aspect_relationship
shape_aspect_relationship.name = 'instantiated feature'}
shape_aspect_relationship.relating_shape_aspect ->
shape_aspect =>
minimally_defined_bare_die_terminal =>
bare_die_terminal

end_attribute_mapping;

end_entity_mapping;

entity_mapping Component_external_reference(Component_external_reference, representation);

mapping_constraints;
{representation
representation.name = 'component external reference'}

end_mapping_constraints;

attribute_mapping design_owner(design_owner, descriptive_representation_item);
representation
representation.items[i] ->
{representation_item
representation_item.name = 'design owner'}
representation_item =>
descriptive_representation_item

end_attribute_mapping;

attribute_mapping part_number(part_number, descriptive_representation_item);
representation
representation.items[i] ->
{representation_item
representation_item.name = 'part number'}
representation_item =>
descriptive_representation_item

end_attribute_mapping;

attribute_mapping revision_code(revision_code, descriptive_representation_item);
representation
representation.items[i] ->
{representation_item
representation_item.name = 'revision code'}
representation_item =>
descriptive_representation_item

end_attribute_mapping;

attribute_mapping product_definition_id(product_definition_id, descriptive_representation_item);
representation
representation.items[i] ->
{representation_item
representation_item.name = 'product definition id'}
representation_item =>
descriptive_representation_item

end_attribute_mapping;

attribute_mapping reference_designation(reference_designation, descriptive_representation_item);
representation
representation.items[i] ->
{representation_item
representation_item.name = 'reference designation'}
representation_item =>
descriptive_representation_item

end_attribute_mapping;

end_entity_mapping;

entity_mapping Component_feature_external_reference(Component_feature_external_reference, descriptive_representation_item);

mapping_constraints;
descriptive_representation_item <=
{representation_item
representation_item.name = 'component feature external reference'}
representation_item

end_mapping_constraints;

attribute_mapping name(name, descriptive_representation_item.description);

end_attribute_mapping;

attribute_mapping associated_component(associated_component, $PATH, Component_external_reference);
descriptive_representation_item <=
representation_item <-
representation.items[i]
{representation
representation.name = 'component external reference'}
representation

end_attribute_mapping;

end_entity_mapping;

entity_mapping Component_mounting_clearance_relationship(Component_mounting_clearance_relationship, representation);

mapping_constraints;
{representation.name = 'mounting clearance'}

end_mapping_constraints;

attribute_mapping mounting_clearance(mounting_clearance, $PATH, Length_tolerance_characteristic);
{representation.name = 'mounting clearance'}
representation <-
representation_relationship.rep_1
representation_relationship
{representation_relationship.name = 'mounting clearance'}
representation_relationship.rep_2 ->
representation

end_attribute_mapping;

attribute_mapping feature_relationship(feature_relationship, $PATH, Component_feature_relationship_armx);
{representation.name = 'mounting clearance'}
representation <-
property_definition_representation.used_representation
property_definition_representation
property_definition_representation.definition ->
property_definition
{property_definition
property_definition.name = 'component mounting property'}
property_definition.definition ->
characterized_definition
characterized_definition = shape_definition 
shape_definition = shape_aspect_relationship 
shape_aspect_relationship =>
component_feature_relationship

end_attribute_mapping;

end_entity_mapping;

entity_mapping Component_mounting_feature_armx(Component_mounting_feature_armx, component_mounting_feature);

mapping_constraints;
component_mounting_feature <=
physical_component_feature <=
component_feature <=				
shape_aspect

end_mapping_constraints;

attribute_mapping definition(definition, $PATH, Part_mounting_feature_armx);
component_mounting_feature <=
physical_component_feature <=
component_feature <=				
shape_aspect <-
shape_aspect_relationship.related_shape_aspect
{shape_aspect_relationship
shape_aspect_relationship.name = 'instantiated feature'}
shape_aspect_relationship
shape_aspect_relationship.relating_shape_aspect ->
shape_aspect =>
part_mounting_feature

end_attribute_mapping;

end_entity_mapping;

entity_mapping Component_overlap_relationship(Component_overlap_relationship, representation);

mapping_constraints;
{representation.name = 'overlap clearance'}

end_mapping_constraints;

attribute_mapping added_clearance(added_clearance, $PATH, Length_tolerance_characteristic);
{representation.name = 'overlap clearance'}
representation <-
representation_relationship.rep_1
representation_relationship
{representation_relationship.name = 'added clearance'}
representation_relationship.rep_2 ->
representation

end_attribute_mapping;

attribute_mapping current_component(current_component, $PATH, next_assembly_usage_occurrence);
{representation.name = 'overlap clearance'}
representation <-
property_definition_representation.used_representation
property_definition_representation
property_definition_representation.definition ->
{property_definition
[property_definition.name = 'component overlap property']
[property_definition.description = 'current component']}
property_definition
property_definition.definition ->
characterized_definition
characterized_definition = characterized_product_definition
characterized_product_definition
characterized_product_definition = product_definition_relationship
product_definition_relationship =>
product_definition_usage =>
assembly_component_usage =>
(next_assembly_usage_occurrence)
([next_assembly_usage_occurrence]
[quantified_assembly_component_usage])

end_attribute_mapping;

attribute_mapping previously_placed_component(previously_placed_component, $PATH, next_assembly_usage_occurrence);
{representation.name = 'overlap clearance'}
representation <-
property_definition_representation.used_representation
property_definition_representation
property_definition_representation.definition ->
{property_definition
[property_definition.name = 'component overlap property']
[property_definition.description = 'previously placed component']}
property_definition
property_definition.definition ->
characterized_definition
characterized_definition = characterized_product_definition
characterized_product_definition
characterized_product_definition = product_definition_relationship
product_definition_relationship =>
product_definition_usage =>
assembly_component_usage =>
(next_assembly_usage_occurrence)
([next_assembly_usage_occurrence]
[quantified_assembly_component_usage])

end_attribute_mapping;

end_entity_mapping;

entity_mapping Minimally_defined_component_terminal(Minimally_defined_component_terminal, physical_component_terminal);

mapping_constraints;
{physical_component_terminal <=
component_terminal <=
component_feature <=				
shape_aspect
shape_aspect.description = 'minimally defined component terminal'}

end_mapping_constraints;

attribute_mapping definition(definition, $PATH, Part_terminal_external_reference);
physical_component_terminal <=
component_terminal <=
component_feature <=	
shape_aspect
shape_definition = shape_aspect
characterized_definition = shape_definition
characterized_definition <-
property_definition.definition
property_definition <-
property_definition_representation.definition
property_definition_representation
property_definition_representation.used_representation ->
{representation
representation.name = 'part terminal external reference'}
representation

end_attribute_mapping;

end_entity_mapping;

entity_mapping Movable_packaged_component_join_terminal(Movable_packaged_component_join_terminal, physical_component_terminal);

mapping_constraints;
physical_component_terminal <=
component_terminal <=
component_feature <=				
shape_aspect
{shape_aspect
[shape_aspect.description = 'movable packaged component join terminal']
[shape_aspect.product_definitional = .TRUE.]}

end_mapping_constraints;

attribute_mapping wire_terminal_length(wire_terminal_length, $PATH, Length_tolerance_characteristic);
physical_component_terminal <=
component_terminal <=
component_feature <=	
shape_aspect
shape_definition = shape_aspect
shape_definition
characterized_definition = shape_definition
characterized_definition <-
property_definition.definition
{property_definition.name = 'wire terminal length'}
property_definition <-
property_definition_representation.definition
property_definition_representation
property_definition_representation.used_representation ->
representation

end_attribute_mapping;

end_entity_mapping;


entity_mapping Packaged_component_armx(Packaged_component_armx, packaged_component);

mapping_constraints;
packaged_component <=
physical_component <=
assembly_component <=
component_definition <=
product_definition

end_mapping_constraints;

attribute_mapping derived_from(derived_from, $PATH, Packaged_part_armx);
packaged_component <=
physical_component <=
assembly_component <=
component_definition <=
product_definition <-
product_definition_relationship.related_product_definition
{product_definition_relationship
product_definition_relationship.name = 'definition usage'}
product_definition_relationship
product_definition_relationship.relating_product_definition ->
product_definition =>
physical_unit =>
packaged_part

end_attribute_mapping;

attribute_mapping selected_package_alternate(selected_package_alternate, $PATH, Altered_package);
packaged_component <=
physical_component <=
assembly_component <=
component_definition <=
product_definition <-
product_definition_relationship.related_product_definition
{product_definition_relationship
product_definition_relationship.name = 'package alternate'}
product_definition_relationship
product_definition_relationship.relating_product_definition ->
{product_definition
product_definition.description = 'altered package'}
product_definition =>
physical_unit =>
package

end_attribute_mapping;

end_entity_mapping;

entity_mapping Packaged_component_join_terminal(Packaged_component_join_terminal, physical_component_terminal);

mapping_constraints;
physical_component_terminal <=
component_terminal <=
component_feature <=				
shape_aspect
{shape_aspect
[(shape_aspect.description = 'packaged component join terminal')
(shape_aspect.description = 'movable packaged component join terminal')]
[shape_aspect.product_definitional = .TRUE.]}

end_mapping_constraints;

attribute_mapping associated_component(associated_component, $PATH, Packaged_component_armx);
physical_component_terminal <=
component_terminal <=
component_feature <=	
shape_aspect
shape_aspect.of_shape ->
product_definition_shape =>
assembly_component =>
physical_component =>
packaged_component

end_attribute_mapping;

attribute_mapping definition(definition, $PATH, Packaged_part_join_terminal);
physical_component_terminal <=
component_terminal <=
component_feature <=	
shape_aspect <-
shape_aspect_relationship.related_shape_aspect
{shape_aspect_relationship
shape_aspect_relationship.name = 'instantiated feature'}
shape_aspect_relationship
shape_aspect_relationship.relating_shape_aspect ->
{shape_aspect
shape_aspect.description = 'join terminal'}
shape_aspect =>
packaged_part_terminal

end_attribute_mapping;

end_entity_mapping;

entity_mapping Pca(Pca, assembly_definition);

mapping_constraints;
[assembly_definition <=
physical_unit <=
product_definition_shape <=
property_definition
{property_definition.name = 'assembly module'}]
[assembly_definition <=
physical_unit <=
product_definition
/SUPERTYPE(Assembly_definition_armx)/]

end_mapping_constraints;

attribute_mapping usage_view(usage_view, $PATH, Pca_usage_view);
assembly_definition <=
 physical_unit <=
product_definition <-
product_definition_relationship.related_product_definition
{product_definition_relationship
product_definition_relationship.name = 'design usage'}
product_definition_relationship
product_definition_relationship.relating_product_definition ->
product_definition =>
physical_unit =>
assembly_definition

end_attribute_mapping;

end_entity_mapping;

entity_mapping Routed_interconnect_component_armx(Routed_interconnect_component_armx, routed_interconnect_component);

mapping_constraints;
routed_interconnect_component <=
physical_component <=
assembly_component <=
component_definition <=
product_definition

end_mapping_constraints;

attribute_mapping routed_centreline_shape(routed_centreline_shape, $PATH, Planar_path_shape_model_with_parameters);
routed_interconnect_component <=
physical_component <=
assembly_component <=
component_definition <=
product_definition
characterized_product_definition = product_definition
characterized_product_definition
characterized_definition = characterized_product_definition
characterized_definition <-
property_definition.definition
property_definition
{property_definition
property_definition.name = 'routed centreline shape'}
property_definition <-
property_definition_representation.definition
property_definition_representation
property_definition_representation.used_representation ->
representation =>
shape_representation =>
csg_2d_shape_representation =>
single_area_csg_2d_shape_representation

end_attribute_mapping;

end_entity_mapping;

entity_mapping Routed_physical_component_armx(Routed_physical_component_armx, routed_physical_component);

mapping_constraints;
routed_physical_component <=
physical_component <=
assembly_component <=
component_definition <=
product_definition

end_mapping_constraints;

attribute_mapping routed_centreline_shape(routed_centreline_shape, $PATH, Planar_path_shape_model_with_parameters);
routed_physical_component <=
physical_component <=
assembly_component <=
component_definition <=
product_definition
characterized_product_definition = product_definition
characterized_product_definition
characterized_definition = characterized_product_definition
characterized_definition <-
property_definition.definition
property_definition
{property_definition
property_definition.name = 'routed centreline shape'}
property_definition <-
property_definition_representation.definition
property_definition_representation
property_definition_representation.used_representation ->
representation =>
shape_representation =>
csg_2d_shape_representation =>
single_area_csg_2d_shape_representation

end_attribute_mapping;


end_entity_mapping;
(*end_schema_mapping;*)
