public class SimpleRouteMatcher extends java.lang.Object implements RouteMatcher
Modifier and Type | Class and Description |
---|---|
private static class |
SimpleRouteMatcher.RouteEntry |
Modifier and Type | Field and Description |
---|---|
private static Logger |
LOG |
private java.util.List<SimpleRouteMatcher.RouteEntry> |
routes |
ROOT, SINGLE_QUOTE
Constructor and Description |
---|
SimpleRouteMatcher() |
Modifier and Type | Method and Description |
---|---|
private void |
addRoute(HttpMethod method,
java.lang.String url,
java.lang.String acceptedType,
java.lang.Object target) |
void |
clearRoutes() |
RouteMatch |
findTargetForRequestedRoute(HttpMethod httpMethod,
java.lang.String path,
java.lang.String acceptType) |
private java.util.List<SimpleRouteMatcher.RouteEntry> |
findTargetsForRequestedRoute(HttpMethod httpMethod,
java.lang.String path) |
java.util.List<RouteMatch> |
findTargetsForRequestedRoute(HttpMethod httpMethod,
java.lang.String path,
java.lang.String acceptType) |
private SimpleRouteMatcher.RouteEntry |
findTargetWithGivenAcceptType(java.util.List<SimpleRouteMatcher.RouteEntry> routeMatchs,
java.lang.String acceptType) |
private java.util.Map<java.lang.String,SimpleRouteMatcher.RouteEntry> |
getAcceptedMimeTypes(java.util.List<SimpleRouteMatcher.RouteEntry> routes) |
void |
parseValidateAddRoute(java.lang.String route,
java.lang.String acceptType,
java.lang.Object target) |
private boolean |
routeWithGivenAcceptType(java.lang.String bestMatch) |
private static final Logger LOG
private java.util.List<SimpleRouteMatcher.RouteEntry> routes
private void addRoute(HttpMethod method, java.lang.String url, java.lang.String acceptedType, java.lang.Object target)
public void clearRoutes()
clearRoutes
in interface RouteMatcher
public RouteMatch findTargetForRequestedRoute(HttpMethod httpMethod, java.lang.String path, java.lang.String acceptType)
findTargetForRequestedRoute
in interface RouteMatcher
private java.util.List<SimpleRouteMatcher.RouteEntry> findTargetsForRequestedRoute(HttpMethod httpMethod, java.lang.String path)
public java.util.List<RouteMatch> findTargetsForRequestedRoute(HttpMethod httpMethod, java.lang.String path, java.lang.String acceptType)
findTargetsForRequestedRoute
in interface RouteMatcher
private SimpleRouteMatcher.RouteEntry findTargetWithGivenAcceptType(java.util.List<SimpleRouteMatcher.RouteEntry> routeMatchs, java.lang.String acceptType)
private java.util.Map<java.lang.String,SimpleRouteMatcher.RouteEntry> getAcceptedMimeTypes(java.util.List<SimpleRouteMatcher.RouteEntry> routes)
public void parseValidateAddRoute(java.lang.String route, java.lang.String acceptType, java.lang.Object target)
parseValidateAddRoute
in interface RouteMatcher
private boolean routeWithGivenAcceptType(java.lang.String bestMatch)