Set<T> in = removeChildrenAndParents(task, graph
.getIncomingTasksFor(task));
for (T t : in) {
IDependency<T> dependency = graph
.getDependencyFrom(t, task);
DependencyType type = DependencyType.END_START;
if (dependency != null) {
type = dependency.getType();
}
addDepedenciesAndRelatedTasks(result,
removeContainers(Arrays.asList(t)), allChildren,
type);
}
Set<T> out = removeChildrenAndParents(task, graph
.getOutgoingTasksFor(task));
for (T t : out) {
IDependency<T> dependency = graph
.getDependencyFrom(task, t);
DependencyType type = DependencyType.END_START;
if (dependency != null) {
type = dependency.getType();
}
addDepedenciesAndRelatedTasks(result, allChildren,
removeContainers(Arrays.asList(t)), type);