USES Common/std; USES Common/Converters; USES Common/CommonUtil; USES Common/ModelDataRetreive; USES Common/StringUtil; proc main() Init(); info = "UML check STARTED at \t"time()"\n"; TrashItems(); info = "UML check STOPPED at \t"time()"\n"; end proc proc Init() //Language setLanguage("SQL"); mkdir([OutputDir]); setOutput( [OutputDir] "/" "TrashItems.bat" ); info = "Output generatig into: " [OutputDir] "/" "TrashItems.bat\n"; end proc proc TrashItems() loop (Instances -> MClass as Entity Where(getStereotype([Entity]) == "Entity" ) ) loop ( Entity -> Role as eRole -> MAssociation as Assoc where(getStereotype([Assoc])=="Uses" ) ) loop ( Assoc -> MAssociationEnd as rRole -> MClass as ROService where (getStereotype([ROService])=="ROService" ) ) local rolecount = 0; local isAssocClass = _False(); loop ( Entity -> MAssociation ) [isAssocClass] = _True(); end loop loop ( Entity -> Role) [rolecount] = incr([rolecount]); end loop if ( [rolecount] == "1" ) if ( [isAssocClass] == _False() ) info = "[Entity:" [Entity.name] "][ROService:"[ROService.name]"]{"getStereotype([Assoc])"}\n"; GenerateEditorNavigation([Entity.guid]); end if end if end loop end loop end loop end proc