private void addDependency(EntityLink link, Set<EntityLink> cyclicGuard) {
if (!cyclicGuard.add(link)) {
return;
}
IntegrationEntity depObj = link.getDependantObject();
add(new Dependency(depObj, link.isStrong()));
// If the link is strong we continue down the dependency chain, otherwise we stop here.
if (link.isStrong()) {
for (EntityLink link2 : dependencyStore.getLinksFrom(depObj)) {
addDependency(link2, cyclicGuard);