FUNCTION acyclic_product_category_relationship

(* SCHEMA step_merged_ap_schema; *)
-- DIFF IN AP214
-- DIFF IN AP238 STEP-NC
-- DIFF IN AP232
-- IN AP214/AP232/AP238 STEP-NC/AP242
FUNCTION acyclic_product_category_relationship
      (relation : product_category_relationship;
       children : SET OF product_category ) : BOOLEAN;
   LOCAL
      x : SET OF product_category_relationship;
      local_children : SET OF product_category;
   END_LOCAL;
      REPEAT i := 1 TO HIINDEX(children);
         IF relation.category :=: children[i] THEN
            RETURN (FALSE);
         END_IF;
      END_REPEAT;
      x := bag_to_set(USEDIN(relation.category, 'STEP_MERGED_AP_SCHEMA.PRODUCT_CATEGORY_RELATIONSHIP.SUB_CATEGORY'));
      local_children := children + relation.category;
      IF SIZEOF(x) > 0 THEN
         REPEAT i := 1 TO HIINDEX(x);
            IF NOT acyclic_product_category_relationship(x[i], local_children) THEN
               RETURN (FALSE);
            END_IF;
         END_REPEAT;
      END_IF;
      RETURN (FALSE);
END_FUNCTION;

Referenced By

Defintion acyclic_product_category_relationship is references by the following definitions:
DefinitionType
 product_category_relationship ENTITY


[Top Level Definitions] [Exit]

Generated by STEP Tools® EXPRESS to HTML Converter
2020-07-28T17:02:20-04:00