public static uint AddEdge(this RoutingNetwork network, uint vertex1, uint vertex2, EdgeData data, IEnumerable <ICoordinate> shape)
 {
     if (shape == null)
     {
         return(network.AddEdge(vertex1, vertex2, data, (ShapeBase)null));
     }
     return(network.AddEdge(vertex1, vertex2, data, (ShapeBase) new ShapeEnumerable(shape)));
 }
        public static void MergeVertices(this RoutingNetwork network, uint vertex1, uint vertex2)
        {
            List <RoutingEdge> routingEdgeList = new List <RoutingEdge>((IEnumerable <RoutingEdge>)network.GetEdgeEnumerator(vertex2));

            network.RemoveEdges(vertex2);
            for (int index = 0; index < routingEdgeList.Count; ++index)
            {
                if (!routingEdgeList[index].DataInverted)
                {
                    int num1 = (int)network.AddEdge(vertex1, routingEdgeList[index].To, routingEdgeList[index].Data, routingEdgeList[index].Shape);
                }
                else
                {
                    int num2 = (int)network.AddEdge(routingEdgeList[index].To, vertex1, routingEdgeList[index].Data, routingEdgeList[index].Shape);
                }
            }
        }
 public static uint AddEdge(this RoutingNetwork network, uint vertex1, uint vertex2, ushort profile, uint metaId, float distance, IEnumerable <ICoordinate> shape)
 {
     return(network.AddEdge(vertex1, vertex2, new EdgeData()
     {
         Distance = distance,
         MetaId = metaId,
         Profile = profile
     }, (ShapeBase) new ShapeEnumerable(shape)));
 }
 public static uint AddEdge(this RoutingNetwork network, uint vertex1, uint vertex2, EdgeData data, params ICoordinate[] shape)
 {
     return(network.AddEdge(vertex1, vertex2, data, (ShapeBase) new ShapeEnumerable((IEnumerable <ICoordinate>)shape)));
 }