use of org.bndtools.core.ui.IFormPageFactory in project bndtools by bndtools.
the class BndEditor method getPagesBnd.
private List<String> getPagesBnd(String fileName) {
List<String> pages = new ArrayList<String>(5);
boolean isProjectFile = Project.BNDFILE.equals(fileName);
List<String> subBndFiles = model.getSubBndFiles();
boolean isSubBundles = subBndFiles != null && !subBndFiles.isEmpty();
for (Entry<String, IFormPageFactory> pageEntry : pageFactories.entrySet()) {
String pageId = pageEntry.getKey();
IFormPageFactory page = pageEntry.getValue();
if (!isSubBundles && page.supportsMode(IFormPageFactory.Mode.bundle))
pages.add(pageId);
else if (isProjectFile && page.supportsMode(IFormPageFactory.Mode.project))
pages.add(pageId);
}
return pages;
}
Aggregations