@Override
	public boolean addEdge(AttributedVertex source, AttributedVertex target, AttributedEdge edge) {
		ensureInGraph(source);
		ensureInGraph(target);
		if (collapseDuplicateEdges) {
			AttributedEdge existingEdge = getEdge(source, target);
			if (existingEdge != null) {
				incrementWeightProperty(existingEdge);
				return true;
			}
		}
		return super.addEdge(source, target, edge);
	}
Creates and adds a new directed edge with the given edge object. If the graph is set to
collapse duplicate edges and an edge for that
source and target exists, then the existing edge will be return with its "Weight" attribute
set to the total number of edges that have been added between the source and target vertices.

@param source the source vertex of the directed edge to be created.
@param target the target vertex of the directed edge to be created.
@param edge the BasicEdge object to use for the new edge.  Note: if this is a duplicate and
edges are being collapsed, then this edge object will not be used.
@return true if the edge was added. Note that if this graph is collapsing duplicate edges, then
it will always return true.
Ghidra/Framework/Graph/src/main/java/ghidra/service/graph/AttributedGraph.java