public final List<OtfGroup> getGroupsByApp(final OtfApplication app) { List<OtfGroup> groups = new ArrayList<OtfGroup>(); for (OtfAccountStore acs : app.getAccountStores().values()) { if (acs.isDir()) { String dirName = acs.getName(); groups.addAll(getGroupsByDirName(dirName)); } } return groups; }
@Override public final List<String> getDirsByAppName(final String appnameIn) { List<String> dirs = new ArrayList<String>(); OtfApplication oapp = getLocalModel().getApps().getAppByName(appnameIn); if (oapp != null) { Map<String, OtfAccountStore> acsmap = oapp.getAccountStores(); if (acsmap != null && acsmap.size() > 0) { for (OtfAccountStore acs : acsmap.values()) { if (acs.isDir()) { dirs.add(acs.getName()); } } } } return dirs; }