public static Route getRoute( String method, String path, String action, String params, String headers, String sourceFile, int line) { Route route = new Route(); route.method = method; route.path = path.replace("//", "/"); route.action = action; route.routesFile = sourceFile; route.routesFileLine = line; route.addFormat(headers); route.addParams(params); route.compute(); if (Logger.isTraceEnabled()) { Logger.trace( "Adding [" + route.toString() + "] with params [" + params + "] and headers [" + headers + "]"); } return route; }