|
RULE restrict_applied_action_assignment FOR (applied_action_assignment, object_role); WHERE wr1: SIZEOF ( QUERY ( aaa <* applied_action_assignment | ( aaa . role . description = 'activity element' ) AND NOT ( 'automotive_design.' + 'executed_action' IN TYPEOF ( aaa . assigned_action ) ) ) ) = 0 ; wr2: SIZEOF ( QUERY ( aaa <* applied_action_assignment | ( aaa . role . description = 'activity element' ) AND NOT item_correlation ( aaa . items , [ 'action' , 'action_method' , 'action_property' , 'assembly_component_usage_substitute' , 'configuration_item' , 'configuration_effectivity' , 'configured_effectivity_assignment' , 'document_file' , 'draughting_model' , 'drawing_revision' , 'general_property' , 'material_designation' , 'mechanical_design_geometric_presentation_representation' , 'presentation_area' , 'product' , 'product_concept' , 'product_concept_feature' , 'product_concept_feature_association' , 'product_concept_feature_category' , 'product_concept_feature_category_usage' , 'product_definition' , 'product_definition_formation' , 'product_definition_relationship' , 'product_definition_substitute' , 'property_definition' , 'resource_property' , 'shape_aspect' , 'shape_representation' ] ) ) ) = 0 ; wr3: SIZEOF ( QUERY ( aaa <* applied_action_assignment | ( NOT EXISTS ( aaa . role ) OR ( aaa . role . description = 'activity element' ) ) AND ( SIZEOF ( QUERY ( i <* aaa . items | 'automotive_design.' + 'applied_action_assignment' IN TYPEOF ( i ) ) ) > 0 ) ) ) = 0 ; wr4: SIZEOF ( QUERY ( aaa <* applied_action_assignment | ( aaa . role . name = 'deliverable element' ) AND ( NOT ( 'automotive_design.' + 'element_delivery' IN TYPEOF ( aaa . assigned_action ) ) OR ( SIZEOF ( QUERY ( i <* aaa . items | 'automotive_design.' + 'applied_action_assignment' IN TYPEOF ( i ) ) ) > 1 ) OR ( SIZEOF ( QUERY ( i <* aaa . items | ( 'automotive_design.' + 'applied_action_assignment' IN TYPEOF ( i ) ) AND ( i \ action_assignment . role . description <> 'activity element' ) ) ) > 0 ) ) ) ) = 0 ; wr5: SIZEOF ( QUERY ( aaa <* applied_action_assignment | ( aaa . role . name = 'retention' ) AND NOT ( 'automotive_design.' + 'retention' IN TYPEOF ( aaa . assigned_action ) ) ) ) = 0 ; wr6: SIZEOF ( QUERY ( aaa <* applied_action_assignment | ( aaa . role . name = 'retention' ) AND NOT item_correlation ( aaa . items , [ 'action' , 'action_directive' , 'action_property' , 'action_relationship' , 'applied_action_assignment' , 'applied_classification_assignment' , 'assembly_component_usage_substitute' , 'certification' , 'class_system' , 'configuration_effectivity' , 'configuration_item' , 'configured_effectivity_assignment' , 'document_file' , 'draughting_model' , 'drawing_revision' , 'general_property' , 'material_designation' , 'mechanical_design_geometric_presentation_representation' , 'organizational_project' , 'presentation_area' , 'product' , 'product_concept' , 'product_concept_feature' , 'product_concept_feature_association' , 'product_concept_feature_category' , 'product_concept_feature_category_usage' , 'product_definition' , 'product_definition_formation' , 'product_definition_relationship' , 'product_definition_substitute' , 'property_definition' , 'resource_property' , 'shape_representation' , 'versioned_action_request' ] ) ) ) = 0 ; wr7: SIZEOF ( QUERY ( aaa <* applied_action_assignment | ( aaa . role . name = 'test activity' ) AND NOT item_correlation ( aaa . items , [ 'property_definition' ] ) ) ) = 0 ; END_RULE; -- restrict_applied_action_assignment |
|
public class RRestrict_applied_action_assignment public int rWr7(SdaiContext _context) public int rWr6(SdaiContext _context) public int rWr5(SdaiContext _context) public int rWr4(SdaiContext _context) public int rWr3(SdaiContext _context) public int rWr2(SdaiContext _context) public int rWr1(SdaiContext _context) public int run(SdaiContext _context, A_string violations) |