public abstract class AbstractHandlerMapping extends ApplicationObjectSupport implements HandlerMapping, Ordered
HandlerMapping
implementations.logger
BEST_MATCHING_PATTERN_ATTRIBUTE, MATRIX_VARIABLES_ATTRIBUTE, PATH_WITHIN_HANDLER_MAPPING_ATTRIBUTE, PRODUCIBLE_MEDIA_TYPES_ATTRIBUTE, URI_TEMPLATE_VARIABLES_ATTRIBUTE
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
Constructor and Description |
---|
AbstractHandlerMapping() |
Modifier and Type | Method and Description |
---|---|
int |
getOrder()
Get the order value of this object.
|
HttpRequestPathHelper |
getPathHelper()
Return the
HttpRequestPathHelper implementation to use for
resolution of lookup paths. |
PathMatcher |
getPathMatcher()
Return the PathMatcher implementation to use for matching URL paths
against registered URL patterns.
|
void |
setOrder(int order)
Specify the order value for this HandlerMapping bean.
|
void |
setPathHelper(HttpRequestPathHelper pathHelper)
Set the
HttpRequestPathHelper to use for resolution of lookup
paths. |
void |
setPathMatcher(PathMatcher pathMatcher)
Set the PathMatcher implementation to use for matching URL paths
against registered URL patterns.
|
void |
setUrlDecode(boolean urlDecode)
Set if the path should be URL-decoded.
|
getApplicationContext, getMessageSourceAccessor, initApplicationContext, initApplicationContext, isContextRequired, requiredContextClass, setApplicationContext
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getHandler
public final void setOrder(int order)
Default value is Integer.MAX_VALUE
, meaning that it's non-ordered.
Ordered.getOrder()
public final int getOrder()
Ordered
Higher values are interpreted as lower priority. As a consequence,
the object with the lowest value has the highest priority (somewhat
analogous to Servlet load-on-startup
values).
Same order values will result in arbitrary sort positions for the affected objects.
getOrder
in interface Ordered
Ordered.HIGHEST_PRECEDENCE
,
Ordered.LOWEST_PRECEDENCE
public void setUrlDecode(boolean urlDecode)
public void setPathHelper(HttpRequestPathHelper pathHelper)
HttpRequestPathHelper
to use for resolution of lookup
paths. Use this to override the default implementation with a custom
subclass or to share common path helper settings across multiple
HandlerMappings.public HttpRequestPathHelper getPathHelper()
HttpRequestPathHelper
implementation to use for
resolution of lookup paths.public void setPathMatcher(PathMatcher pathMatcher)
AntPathMatcher
public PathMatcher getPathMatcher()