matchRoute method
Matches a route by its path.
Implementation
RouteTreeResult? matchRoute(String path) {
final matchResult = matcher.matchRoute(path);
if (matchResult != null) {
final route = tree[matchResult.node.originalPath];
return RouteTreeResult(route: route, matchResult: matchResult);
}
return null;
}