Exemple #1
0
        /// <summary>
        /// Construct and return an edge for a given query and target node
        /// </summary>
        /// <returns>connected edges</returns>
        public IEdge Connect(INode source, INode target, IVFBondMatcher matcher)
        {
            NodeBuilder sourceImpl = (NodeBuilder)source;
            NodeBuilder targetImpl = (NodeBuilder)target;
            EdgeBuilder edge       = new EdgeBuilder(sourceImpl, targetImpl, matcher);

            sourceImpl.AddNeighbor(targetImpl);
            targetImpl.AddNeighbor(sourceImpl);

            sourceImpl.AddEdge(edge);
            targetImpl.AddEdge(edge);

            edgesList.Add(edge);
            return(edge);
        }
Exemple #2
0
 public void AddEdge(EdgeBuilder edge)
 {
     edgesList.Add(edge);
 }