|
RULE restrict_default_settings FOR (applied_document_reference, representation); WHERE wr1: ( SIZEOF ( QUERY ( r <* representation | ( r . name = 'default tolerances' ) AND ( r . context_of_items . context_type = 'default setting' ) AND ( SIZEOF ( r . items ) <> 1 ) ) ) = 0 ) AND ( SIZEOF ( QUERY ( r <* representation | ( r . name = 'default tolerances' ) AND ( r . context_of_items . context_type = 'default setting' ) AND ( SIZEOF ( QUERY ( i <* r . items | ( 'automotive_design.' + 'descriptive_representation_item' IN TYPEOF ( i ) ) AND ( i . name = 'tolerance class' ) ) ) <> 1 ) ) ) = 0 ) ; wr2: SIZEOF ( QUERY ( r <* representation | ( r . name = 'default tolerances' ) AND ( r . context_of_items . context_type = 'default setting' ) AND ( SIZEOF ( QUERY ( adr <* USEDIN ( r , 'automotive_design.applied_document_reference.items' ) | adr . role . name = 'general tolerance definition' ) ) + SIZEOF ( QUERY ( rr <* USEDIN ( r , 'automotive_design.representation_relationship.rep_2' ) | ( rr . name = 'general tolerance definition' ) AND ( 'automotive_design.' + 'default_tolerance_table' IN TYPEOF ( rr . rep_1 ) ) ) ) <> 1 ) ) ) = 0 ; END_RULE; -- restrict_default_settings |
|
public class RRestrict_default_settings public int rWr2(SdaiContext _context) public int rWr1(SdaiContext _context) public int run(SdaiContext _context, A_string violations) |