FUNCTION get_coordinate_values

(* SCHEMA step_merged_ap_schema; *)
-- IN AP238 STEP-NC/AP242
FUNCTION get_coordinate_values
      (source : tessellated_surface_item ) : coordinates_list;
   LOCAL
      coordinate_values : coordinates_list;
      max : INTEGER;
   END_LOCAL;
      CASE TRUE OF
         'STEP_MERGED_AP_SCHEMA.TESSELLATED_FACE' IN TYPEOF(source) :
               BEGIN
                  coordinate_values := source\tessellated_face.coordinates;
                  RETURN (coordinate_values);
               END;
         'STEP_MERGED_AP_SCHEMA.TESSELLATED_SURFACE_SET' IN TYPEOF(source) :
               BEGIN
                  coordinate_values := source\tessellated_surface_set.coordinates;
                  RETURN (coordinate_values);
               END;
         'STEP_MERGED_AP_SCHEMA.TESSELLATED_SOLID' IN TYPEOF(source) :
               BEGIN
                  IF 'STEP_MERGED_AP_SCHEMA.TESSELLATED_FACE' IN TYPEOF(source\tessellated_solid.items[1]) THEN
                     coordinate_values := source\tessellated_solid.items[1]\tessellated_face.coordinates;
                  END_IF;
                  IF 'STEP_MERGED_AP_SCHEMA.TESSELLATED_EDGE' IN TYPEOF(source\tessellated_solid.items[1]) THEN
                     coordinate_values := source\tessellated_solid.items[1]\tessellated_edge.coordinates;
                  END_IF;
                  IF 'STEP_MERGED_AP_SCHEMA.TESSELLATED_VERTEX' IN TYPEOF(source\tessellated_solid.items[1]) THEN
                     coordinate_values := source\tessellated_solid.items[1]\tessellated_vertex.coordinates;
                  END_IF;
                  max := SIZEOF(source\tessellated_solid.items);
                  IF max = 1 THEN
                     RETURN (coordinate_values);
                  ELSE
                     REPEAT i := 2 TO max;
                        IF 'STEP_MERGED_AP_SCHEMA.TESSELLATED_FACE' IN TYPEOF(source\tessellated_solid.items[i]) THEN
                           IF NOT (coordinate_values :=: source\tessellated_solid.items[i]\tessellated_face.coordinates) THEN
                              RETURN (?);
                           END_IF;
                        END_IF;
                        IF 'STEP_MERGED_AP_SCHEMA.TESSELLATED_EDGE' IN TYPEOF(source\tessellated_solid.items[i]) THEN
                           IF NOT (coordinate_values :=: source\tessellated_solid.items[i]\tessellated_edge.coordinates) THEN
                              RETURN (?);
                           END_IF;
                        END_IF;
                        IF 'STEP_MERGED_AP_SCHEMA.TESSELLATED_VERTEX' IN TYPEOF(source\tessellated_solid.items[i]) THEN
                           IF NOT (coordinate_values :=: source\tessellated_solid.items[i]\tessellated_vertex.coordinates) THEN
                              RETURN (?);
                           END_IF;
                        END_IF;
                     END_REPEAT;
                     RETURN (coordinate_values);
                  END_IF;
               END;
         'STEP_MERGED_AP_SCHEMA.TESSELLATED_SHELL' IN TYPEOF(source) :
               BEGIN
                  IF 'STEP_MERGED_AP_SCHEMA.TESSELLATED_FACE' IN TYPEOF(source\tessellated_shell.items[1]) THEN
                     coordinate_values := source\tessellated_shell.items[1]\tessellated_face.coordinates;
                  END_IF;
                  IF 'STEP_MERGED_AP_SCHEMA.TESSELLATED_EDGE' IN TYPEOF(source\tessellated_shell.items[1]) THEN
                     coordinate_values := source\tessellated_shell.items[1]\tessellated_edge.coordinates;
                  END_IF;
                  IF 'STEP_MERGED_AP_SCHEMA.TESSELLATED_VERTEX' IN TYPEOF(source\tessellated_shell.items[1]) THEN
                     coordinate_values := source\tessellated_shell.items[1]\tessellated_vertex.coordinates;
                  END_IF;
                  max := SIZEOF(source\tessellated_shell.items);
                  IF max = 1 THEN
                     RETURN (coordinate_values);
                  ELSE
                     REPEAT i := 2 TO max;
                        IF 'STEP_MERGED_AP_SCHEMA.TESSELLATED_FACE' IN TYPEOF(source\tessellated_shell.items[i]) THEN
                           IF NOT (coordinate_values :=: source\tessellated_shell.items[i]\tessellated_face.coordinates) THEN
                              RETURN (?);
                           END_IF;
                        END_IF;
                        IF 'STEP_MERGED_AP_SCHEMA.TESSELLATED_EDGE' IN TYPEOF(source\tessellated_shell.items[i]) THEN
                           IF NOT (coordinate_values :=: source\tessellated_shell.items[i]\tessellated_edge.coordinates) THEN
                              RETURN (?);
                           END_IF;
                        END_IF;
                        IF 'STEP_MERGED_AP_SCHEMA.TESSELLATED_VERTEX' IN TYPEOF(source\tessellated_shell.items[i]) THEN
                           IF NOT (coordinate_values :=: source\tessellated_shell.items[i]\tessellated_vertex.coordinates) THEN
                              RETURN (?);
                           END_IF;
                        END_IF;
                     END_REPEAT;
                     RETURN (coordinate_values);
                  END_IF;
               END;
      END_CASE;
END_FUNCTION;

Referenced By

Defintion get_coordinate_values is references by the following definitions:
DefinitionType
 styled_tessellated_item_with_colours ENTITY


[Top Level Definitions] [Exit]

Generated by STEP Tools® EXPRESS to HTML Converter
2024-09-06T14:00:33-04:00