public void addEdge(long timestamp, String edgeName, String state, String source, String dest,
      boolean isFromPattern) {

    Vertex destVertex = new Vertex(this, dest, state, timestamp);
    SortedMap<Long, Vertex> map = indexedVertices.get(dest);
    if (map == null) {
      map = new TreeMap<>();
      indexedVertices.put(dest, map);
    }

    // If this edge is being added by a pattern event, only
    // add the edge if the destination changes state as a result
    // of this edge. This cuts down on noise in the graph.
    if (isFromPattern) {
      SortedMap<Long, Vertex> headMap = map.headMap(timestamp);
      if (headMap != null && !headMap.isEmpty()) {
        Long previousKey = headMap.lastKey();
        Vertex previousVertex = headMap.get(previousKey);
        if (previousVertex.getState().equals(state)) {
          return;
        }
      } else {
        // Super hack here. Don't add a transition from the non existent state to
        // the destroyed state in a lifeline.
        if (state.equals("destroyed")) {
          return;
        }
      }
    }
    map.put(timestamp, destVertex);

    edges.add(new Edge(this, timestamp, edgeName, source, destVertex));
  }
Add an edge to this graph.
geode-core/src/main/java/org/apache/geode/internal/sequencelog/model/Graph.java