public class InMemoryUriRegistry extends Object implements UriRegistry
UriRegistry
implementation.Constructor and Description |
---|
InMemoryUriRegistry() |
Modifier and Type | Method and Description |
---|---|
URI |
find(String key)
Return a
URI for a string key. |
Map<String,URI> |
findAll()
Return all registered
URI s. |
void |
register(String key,
URI uri)
Register a
URI with a string key. |
void |
unregister(String key)
Remove the registration for a string key.
|
public URI find(String key)
UriRegistry
URI
for a string key.find
in interface UriRegistry
key
- the key for the URIURI
for the given keypublic Map<String,URI> findAll()
UriRegistry
URI
s.findAll
in interface UriRegistry
URI
s.public void register(String key, URI uri)
UriRegistry
URI
with a string key. Existing
registrations will be overwritten.register
in interface UriRegistry
key
- the key for the URIuri
- the URI
to associate with the keypublic void unregister(String key)
UriRegistry
unregister
in interface UriRegistry
key
- the key for the URI
to unregisterCopyright © 2018 Pivotal Software, Inc.. All rights reserved.