FUNCTION acyclic_mapped_representation
(* SCHEMA Ap210_electronic_assembly_interconnect_and_packaging_design_mim_lf; *)
FUNCTION acyclic_mapped_representation
(mi: mapped_item) : BOOLEAN;
LOCAL
rms : SET OF representation_map;
mis : SET OF mapped_item;
rs1, rs2 : SET OF representation;
END_LOCAL;
rs1 := using_representations(mi);
rs2 := [];
-- loop as long as there are elements in rs1
REPEAT WHILE SIZEOF(rs1) > 0;
REPEAT i := 1 TO HIINDEX(rs1);
-- Determine the set of representation_map that reference the parent_set
rms := bag_to_set(USEDIN(rs1[i], 'AP210_ELECTRONIC_ASSEMBLY_INTERCONNECT_AND_PACKAGING_DESIGN_MIM_LF.REPRESENTATION_MAP.MAPPED_REPRESENTATION'));
IF SIZEOF(rms) > 0 THEN
REPEAT j := 1 TO HIINDEX(rms);
mis := bag_to_set(USEDIN(rms[i], 'AP210_ELECTRONIC_ASSEMBLY_INTERCONNECT_AND_PACKAGING_DESIGN_MIM_LF.MAPPED_ITEM.MAPPING_SOURCE'));
IF SIZEOF(mis) > 0 THEN
REPEAT j := 1 TO HIINDEX(mis);
-- check mis members for instance equal with mi. If so then there is a cycle
IF mis[i] :=: mi THEN
RETURN (FALSE);
END_IF;
rs2 := rs2 + using_representations(mis[i]);
END_REPEAT;
END_IF;
END_REPEAT;
END_IF;
END_REPEAT;
rs1 := rs2;
rs2 := [];
END_REPEAT;
RETURN (TRUE);
END_FUNCTION;
Referenced By
Defintion acyclic_mapped_representation is references by the following definitions:
[Top Level Definitions] [Exit]Generated by STEP Tools® EXPRESS to HTML Converter
2012-03-27T17:15:33-04:00