use of org.eclipse.tycho.classpath.ClasspathEntry.AccessRule in project tycho by eclipse.
the class DependencyComputer method addVisiblePackagesFromState.
private void addVisiblePackagesFromState(StateHelper helper, BundleDescription desc, Map<BundleDescription, ArrayList<AccessRule>> visiblePackages) {
if (desc == null)
return;
ExportPackageDescription[] exports = helper.getVisiblePackages(desc, StateHelper.VISIBLE_INCLUDE_EE_PACKAGES);
for (int i = 0; i < exports.length; i++) {
BundleDescription exporter = exports[i].getExporter();
if (exporter == null)
continue;
ArrayList<AccessRule> list = visiblePackages.get(exporter);
if (list == null)
list = new ArrayList<>();
AccessRule rule = getRule(helper, desc, exports[i]);
if (!list.contains(rule))
list.add(rule);
visiblePackages.put(exporter, list);
}
}
Aggregations