FUNCTION validate_accuracy_types

(* SCHEMA Ap242_managed_model_based_3d_engineering_mim_LF; *)
  FUNCTION validate_accuracy_types
    (ei:shape_data_quality_criterion;
     type_list:BAG OF STRING):LOGICAL;
     LOCAL
       sdqca: BAG OF
        SHAPE_DATA_QUALITY_CRITERION_AND_ACCURACY_ASSOCIATION:=[];
       sma: BAG OF SHAPE_MEASUREMENT_ACCURACY:=[];
       sdqir: SET OF
        SHAPE_DATA_QUALITY_INSPECTION_RESULT:=[];
       scraa: BAG OF
        SHAPE_INSPECTION_RESULT_ACCURACY_ASSOCIATION:=[];
       t_logic:BOOLEAN;
     END_LOCAL;
     -- STEP-1
     -- collect types of range attribute of shape_measurement_accuracy
     -- referred from shape_data_quality_criterion_and_accuracy_association 
     -- that refers to given shape_data_quality_criterion.
     sdqca := USEDIN(ei,
               'AP242_MANAGED_MODEL_BASED_3D_ENGINEERING_MIM_LF.'+
               'SHAPE_DATA_QUALITY_CRITERION_AND_ACCURACY_ASSOCIATION.'+
               'SHAPE_DATA_QUALITY_CRITERION');
     IF(SIZEOF(sdqca) <> 0) THEN
       REPEAT i:= 1 TO SIZEOF(sdqca);
         sma := sma + sdqca[i].required_specific_accuracy;
       END_REPEAT;
  
       -- STEP-2
       -- check whether the collected types include all the type names
       -- in the type list given as an input argument of this function
       -- and they do not include any other type names. 
       IF(SIZEOF(type_list) < SIZEOF(sma)) THEN
         RETURN(FALSE);
       END_IF;
  
       REPEAT i:= 1 TO SIZEOF(sma);
         t_logic := FALSE;
         REPEAT j:= 1 TO SIZEOF(type_list);
           IF(type_list[j] IN value_limit_type(sma[i].range)) THEN
             t_logic := TRUE;
             ESCAPE;
           END_IF;
         END_REPEAT;
         IF(NOT(t_logic)) THEN
           RETURN(FALSE);
         END_IF;
       END_REPEAT;
    END_IF;
  
     -- STEP-3
     -- collect types of range attribute of shape_measurement_accuracy
     -- referred from shape_inspection_result_accuracy_association
     -- that refers to shape_data_quality_inspection_result
     -- for the given shape_data_quality_criterion.
     sdqir := QUERY(q <* bag_to_set(USEDIN(ei,
                   'AP242_MANAGED_MODEL_BASED_3D_ENGINEERING_MIM_LF.'+
                   'DATA_QUALITY_INSPECTION_RESULT.'+
                   'CRITERION_INSPECTED'))|
           'AP242_MANAGED_MODEL_BASED_3D_ENGINEERING_MIM_LF.'+
           'SHAPE_DATA_QUALITY_INSPECTION_RESULT'
            IN TYPEOF(q));
     IF(SIZEOF(sdqir) = 0) THEN
       RETURN(TRUE);
     END_IF;
  
     REPEAT i:= 1 TO SIZEOF(sdqir);
       scraa := USEDIN(sdqir[i],
               'AP242_MANAGED_MODEL_BASED_3D_ENGINEERING_MIM_LF.'+
               'SHAPE_INSPECTION_RESULT_ACCURACY_ASSOCIATION.'+
               'SHAPE_DATA_QUALITY_RESULT');
       IF(SIZEOF(scraa) <> 0) THEN
         sma := [];
         REPEAT j:= 1 TO SIZEOF(scraa);
           sma := sma + scraa[j].applied_specific_accuracy;
         END_REPEAT;
  
         -- STEP-4
         -- check whether the collected types include all the type
         -- names in the type list given as an input argument of
         -- this function and they do not include any other type names.
         IF(SIZEOF(type_list) < SIZEOF(sma)) THEN
           RETURN(FALSE);
         END_IF;
  
         REPEAT j:= 1 TO SIZEOF(sma);
           t_logic := FALSE;
           REPEAT k:= 1 TO SIZEOF(type_list);
             IF(type_list[k] IN value_limit_type(sma[j].range)) THEN
               t_logic := TRUE;
               ESCAPE;
             END_IF;
           END_REPEAT;
           IF(NOT(t_logic)) THEN
             RETURN(FALSE);
           END_IF;
         END_REPEAT;
       END_IF;
     END_REPEAT;
  
     RETURN(TRUE);
  END_FUNCTION;

Referenced By

Defintion validate_accuracy_types is references by the following definitions:
DefinitionType
 abrupt_change_of_surface_normal ENTITY
 curve_with_excessive_segments ENTITY
 curve_with_small_curvature_radius ENTITY
 disconnected_face_set ENTITY
 edge_with_excessive_segments ENTITY
 entirely_narrow_face ENTITY
 entirely_narrow_solid ENTITY
 entirely_narrow_surface ENTITY
 erroneous_b_spline_curve_definition ENTITY
 erroneous_b_spline_surface_definition ENTITY
 excessively_high_degree_curve ENTITY
 excessively_high_degree_surface ENTITY
 extreme_patch_width_variation ENTITY
 face_surface_with_excessive_patches_in_one_direction ENTITY
 free_edge ENTITY
 g1_discontinuity_between_adjacent_faces ENTITY
 g1_discontinuous_curve ENTITY
 g1_discontinuous_surface ENTITY
 g2_discontinuity_between_adjacent_faces ENTITY
 g2_discontinuous_curve ENTITY
 g2_discontinuous_surface ENTITY
 gap_between_adjacent_edges_in_loop ENTITY
 gap_between_edge_and_base_surface ENTITY
 gap_between_faces_related_to_an_edge ENTITY
 gap_between_pcurves_related_to_an_edge ENTITY
 gap_between_vertex_and_base_surface ENTITY
 gap_between_vertex_and_edge ENTITY
 high_degree_axi_symmetric_surface ENTITY
 high_degree_conic ENTITY
 high_degree_linear_curve ENTITY
 high_degree_planar_surface ENTITY
 inconsistent_adjacent_face_normals ENTITY
 inconsistent_curve_transition_code ENTITY
 inconsistent_edge_and_curve_directions ENTITY
 inconsistent_face_and_closed_shell_normals ENTITY
 inconsistent_face_and_surface_normals ENTITY
 inconsistent_surface_transition_code ENTITY
 indistinct_curve_knots ENTITY
 indistinct_surface_knots ENTITY
 intersecting_connected_face_sets ENTITY
 intersecting_loops_in_face ENTITY
 intersecting_shells_in_solid ENTITY
 multiply_defined_cartesian_points ENTITY
 multiply_defined_curves ENTITY
 multiply_defined_directions ENTITY
 multiply_defined_edges ENTITY
 multiply_defined_faces ENTITY
 multiply_defined_placements ENTITY
 multiply_defined_solids ENTITY
 multiply_defined_surfaces ENTITY
 multiply_defined_vertices ENTITY
 narrow_surface_patch ENTITY
 nearly_degenerate_surface_boundary ENTITY
 nearly_degenerate_surface_patch ENTITY
 non_manifold_at_edge ENTITY
 non_manifold_at_vertex ENTITY
 open_closed_shell ENTITY
 open_edge_loop ENTITY
 over_used_vertex ENTITY
 partly_overlapping_curves ENTITY
 partly_overlapping_edges ENTITY
 partly_overlapping_faces ENTITY
 partly_overlapping_solids ENTITY
 partly_overlapping_surfaces ENTITY
 self_intersecting_curve ENTITY
 self_intersecting_loop ENTITY
 self_intersecting_shell ENTITY
 self_intersecting_surface ENTITY
 short_length_curve ENTITY
 short_length_curve_segment ENTITY
 short_length_edge ENTITY
 small_area_face ENTITY
 small_area_surface ENTITY
 small_area_surface_patch ENTITY
 small_volume_solid ENTITY
 solid_with_excessive_number_of_voids ENTITY
 solid_with_wrong_number_of_voids ENTITY
 steep_angle_between_adjacent_edges ENTITY
 steep_angle_between_adjacent_faces ENTITY
 surface_with_excessive_patches_in_one_direction ENTITY
 surface_with_small_curvature_radius ENTITY
 unused_patches ENTITY
 wrongly_oriented_void ENTITY
 wrongly_placed_loop ENTITY
 wrongly_placed_void ENTITY
 zero_surface_normal ENTITY


[Top Level Definitions] [Exit]

Generated by STEP Tools® EXPRESS to HTML Converter
2012-03-27T17:20:10-04:00