code: private boolean allConnectionsFromOtherStage(final ExecutionGroupVertex groupVertex, final boolean forward) {
  
  		if (forward) {
  			for (int i = 0; i < groupVertex.getNumberOfBackwardLinks(); i++) {
  				if (this.stage == groupVertex.getBackwardEdge(i).getSourceVertex().getStageNumber()) {
  					return false;
  				}
  			}
  		} else {
  			for (int i = 0; i < groupVertex.getNumberOfForwardLinks(); i++) {
  				if (this.stage == groupVertex.getForwardEdge(i).getTargetVertex().getStageNumber()) {
  					return false;
  				}
  			}
  		}
  
  		return true;
  	}
docs: Checks if for the given group vertex all incoming (if forward is <code>true</code>) or outgoing links (if forward
  is <code>false</code>) come from
  other stages than the one the given vertex is in.
  
  @param groupVertex
  the group vertex to check for
  @param forward
  <code>true</code> if incoming links should be considered, <code>false</code> for outgoing links
  @return <code>true</code> if all incoming or outgoing links (depends on the forward switch) come from other
  stages, <code>false</code> otherwise