|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eel.kitchen.jsonschema.uri.URIHandlerFactory
public final class URIHandlerFactory
Factory providing URIHandler instances
This looks at the scheme of the URI to determine what handler is returned. You can register handlers for any scheme of you choice, but if you do so, remember about interoperability!
| Constructor Summary | |
|---|---|
URIHandlerFactory()
Constructor. |
|
| Method Summary | |
|---|---|
URIHandler |
getHandler(URI uri)
Get a handler for the given URI |
void |
registerHandler(String scheme,
URIHandler handler)
Register a handler for a new scheme |
void |
unregisterHandler(String scheme)
Unregister a handler for a given scheme |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public URIHandlerFactory()
HTTPURIHandler, certainly the mostly used one -- which is why it is
already provided
| Method Detail |
|---|
public void registerHandler(String scheme,
URIHandler handler)
scheme - the schemehandler - the handler
IllegalArgumentException - the scheme is invalid,
a handler is already registered for that scheme, or the handler is nullpublic void unregisterHandler(String scheme)
scheme - the victimpublic URIHandler getHandler(URI uri)
The URI must be absolute here.
uri - the URI
IllegalArgumentException - the URI is not absolute,
or the scheme of this URI is not registered
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||