public static Result <Route> TryBuild(RouterDb db, Profile profile, Func <ushort, Factor> getFactor, RouterPoint source, RouterPoint target, Path path)
        {
            List <uint> uintList = new List <uint>();

            path.AddToList(uintList);
            return(FastRouteBuilder.TryBuild(db, profile, getFactor, source, target, uintList));
        }
        public static Result <Route> TryBuild(RouterDb db, Profile profile, Func <ushort, Factor> getFactor, RouterPoint source, RouterPoint target, List <uint> path)
        {
            FastRouteBuilder fastRouteBuilder = new FastRouteBuilder(db, profile, getFactor, source, target, path);

            fastRouteBuilder.Run();
            if (fastRouteBuilder.HasSucceeded)
            {
                return(new Result <Route>(fastRouteBuilder.Route));
            }
            return(new Result <Route>(string.Format("Failed to build route: {0}", (object)fastRouteBuilder.ErrorMessage)));
        }
 public static Route Build(RouterDb db, Profile profile, Func <ushort, Factor> getFactor, RouterPoint source, RouterPoint target, List <uint> path)
 {
     return(FastRouteBuilder.TryBuild(db, profile, getFactor, source, target, path).Value);
 }