code: protected static void initialiseOutbound(Node n, long baseTime, CommunicationDetails cd,
              StringBuilder nodeId) {
          CommunicationDetails.Outbound ob = new CommunicationDetails.Outbound();
          ob.getLinkIds().add(nodeId.toString());
          ob.setMultiConsumer(true);
          ob.setProducerOffset(n.getTimestamp() - baseTime);
          cd.getOutbound().add(ob);
  
          if (n.getClass() == Producer.class) {
              ob = new CommunicationDetails.Outbound();
              for (int j = 0; j < n.getCorrelationIds().size(); j++) {
                  CorrelationIdentifier ci = n.getCorrelationIds().get(j);
                  if (ci.getScope() == Scope.Interaction || ci.getScope() == Scope.ControlFlow) {
                      ob.getLinkIds().add(ci.getValue());
                  }
              }
              // Only record if outbound ids found
              if (!ob.getLinkIds().isEmpty()) {
                  // Check if pub/sub
                  ob.setMultiConsumer(((Producer) n).multipleConsumers());
  
                  ob.setProducerOffset(n.getTimestamp() - baseTime);
                  cd.getOutbound().add(ob);
              }
          } else if (n.containerNode()) {
              for (int i = 0; i < ((ContainerNode)n).getNodes().size(); i++) {
                  int len = nodeId.length();
                  nodeId.append(':');
                  nodeId.append(i);
                  initialiseOutbound(((ContainerNode) n).getNodes().get(i), baseTime, cd, nodeId);
  
                  // Remove this child's specific path, so that next iteration will add a different path number
                  nodeId.delete(len, nodeId.length());
              }
          }
      }
docs: This method initialises the outbound information from the consumer's nodes in the supplied
  communication details.
  
  @param n The node
  @param baseTime The fragment's base time (ns)
  @param cd The communication details
  @param nodeId The path id for the node