private static CombinedDiffNode buildDiffNode(
      final CombinedGraph combinedGraph,
      final SingleDiffNode primaryDiffNode,
      final SingleDiffNode secondaryDiffNode,
      final SuperDiffNode superDiffNode,
      final RawCombinedBasicBlock combinedBasicblock) {
    ZyLabelContent primaryNodeContent = null;
    if (primaryDiffNode != null) {
      primaryNodeContent = primaryDiffNode.getRealizer().getNodeContent();
    }

    ZyLabelContent secondaryNodeContent = null;
    if (secondaryDiffNode != null) {
      secondaryNodeContent = secondaryDiffNode.getRealizer().getNodeContent();
    }

    final CombinedNodeRealizer combinedNodeRealizer =
        new CombinedNodeRealizer(primaryNodeContent, secondaryNodeContent);

    final CodeNodeRealizerUpdater updater = new CodeNodeRealizerUpdater();
    combinedNodeRealizer.setUpdater(updater);
    updater.setRealizer(combinedNodeRealizer);

    final Node yCombinedNode = combinedGraph.getGraph().createNode();
    final CombinedDiffNode combinedDiffNode =
        new CombinedDiffNode(
            yCombinedNode, combinedNodeRealizer, combinedBasicblock, superDiffNode);
    combinedNodeRealizer.setUserData(new ZyNodeData<>(combinedDiffNode));

    return combinedDiffNode;
  }
Utility class to remove basic block matches from BinDiff graphs.
java/ui/src/main/java/com/google/security/zynamics/bindiff/graph/helpers/BasicBlockMatchRemover.java