public List <T> getGlossaryItemsFromPackage <T>(TSF_EA.Package package, GlossaryItemSearchCriteria criteria) where T : GlossaryItem, new() { T dummy = new T(); // needed to get the stereotype //build a search string var sqlTop = criteria.showAll ? string.Empty : "top 50"; string sqlGetGlossaryItems = string.Format(@"select " + sqlTop + @" o.[Object_ID] from t_object o where ( o.[Name] like '%{0}%' or o.[Name] is null ) and ( o.[Note] like '%{1}%' or o.[Note] is null ) and o.[Stereotype] = '{2}' and o.[Package_ID] in ({3})", criteria.nameSearchTerm, criteria.descriptionSearchTerm, dummy.Stereotype, package.getPackageTreeIDString()); return(this.getGlossaryItemsFromQuery <T>(sqlGetGlossaryItems)); }
public DiagramLayoutCorrector(MagicDrawReader magicDrawReader, TSF_EA.Model model, TSF_EA.Package mdPackage) : base(magicDrawReader, model, mdPackage) { packageTreeIDString = mdPackage.getPackageTreeIDString(); }