public IEnumerable <RootPath> FindPaths(ulong targetObj, int maxResults, int maxLocalRoots, int maxDepth, bool runInParallel) { RootPathFinder pathFinder; if (runInParallel) { pathFinder = new ParallelBreadthFirstRootPathFinder(this, targetObj); } else { pathFinder = new BreadthFirstRootPathFinder(this, targetObj); } pathFinder.MaxResults = maxResults; pathFinder.MaxLocalRoots = maxLocalRoots; pathFinder.MaxDepth = maxDepth; pathFinder.FindPaths(); return(pathFinder.Paths); }
public IEnumerable<RootPath> FindPaths(ulong targetObj, int maxResults, int maxLocalRoots, int maxDepth, bool runInParallel) { RootPathFinder pathFinder; if (runInParallel) { pathFinder = new ParallelBreadthFirstRootPathFinder(this, targetObj); } else { pathFinder = new BreadthFirstRootPathFinder(this, targetObj); } pathFinder.MaxResults = maxResults; pathFinder.MaxLocalRoots = maxLocalRoots; pathFinder.MaxDepth = maxDepth; pathFinder.FindPaths(); return pathFinder.Paths; }