T
- The type of registered objects.RequestRouter
for
request routing.@Contract(threading=SAFE) @Deprecated public class UriRegexMatcher<T> extends Object implements LookupRegistry<T>
The insertion order is in maintained in that map such that the lookup tests each regex until there is a match. This class can be used to resolve an object matching a particular request URI.
Constructor and Description |
---|
UriRegexMatcher()
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
T |
lookup(String path)
Deprecated.
Looks up an object matching the given request path.
|
void |
register(String regex,
T obj)
Deprecated.
Registers the given object for URIs matching the given regex.
|
String |
toString()
Deprecated.
|
void |
unregister(String regex)
Deprecated.
Removes registered object, if exists, for the given regex.
|
public void register(String regex, T obj)
register
in interface LookupRegistry<T>
regex
- the regex to register the handler for.obj
- the object.public void unregister(String regex)
unregister
in interface LookupRegistry<T>
regex
- the regex to unregister.public T lookup(String path)
lookup
in interface LookupRegistry<T>
path
- the request pathnull
if no match is found.Copyright © 2005–2021 The Apache Software Foundation. All rights reserved.