}
});
}
public static DependencyInfo buildReverseDependencyMap(BundlableNode bundlableNode, SourceModule sourceModule) throws ModelOperationException {
BundleSet bundleSet = bundlableNode.getBundleSet();
DependencyAdder dependencyAdder = new DependencyAdder() {
@Override
public void add(DependencyInfo dependencyInfo, LinkedAsset sourceAsset, LinkedAsset targetAsset) {
addDependency(dependencyInfo, targetAsset, sourceAsset);
}
};
DependencyInfo reverseDependencyGraph;
if((sourceModule == null) || bundleSet.getSourceModules().contains(sourceModule)) {
reverseDependencyGraph = buildDependencyGraphFromBundleSet(bundleSet, dependencyAdder);
}
else {
reverseDependencyGraph = buildDependencyGraphFromBundlableNode(bundleSet.getBundlableNode(), dependencyAdder);
}
return reverseDependencyGraph;
}