public class UriResolverManager extends Object
| Modifier and Type | Field and Description |
|---|---|
static org.slf4j.Logger |
logger |
static int |
RESET_DELAY
Time to reload Runtime Resource Configuration
|
static int |
RESET_TIME
Time to reload Runtime Resource Configuration
|
| Constructor and Description |
|---|
UriResolverManager()
Instantiates a new uri resolver manager.
|
UriResolverManager(String applicationType)
Instance a UriResolverManager
Precondition: set the scope provider
ScopeProvider.instance.get()
The scope is used to look up the generic resource UriResolverMapReader#URI_RESOLVER_MAP available in the infrastructure to map ApplicationType with its Resolver |
| Modifier and Type | Method and Description |
|---|---|
void |
cancelTimerUriResolverReader()
Cancel timer uri resolver reader.
|
int |
countReaders()
Count readers.
|
List<ServiceParameter> |
discoveryServiceParameters(Resolver resolver)
Discovery service parameters.
|
Set<String> |
getApplicationTypes()
Gets the application types.
|
Map<String,Resolver> |
getCapabilities()
Gets the capabilities.
|
String |
getLink(Map<String,String> parameters,
boolean shortLink)
Gets the link.
|
String |
getLink(String applicationType,
Map<String,String> parameters,
boolean shortLink)
Gets the link.
|
Resolver |
getResolver(String applicationType)
Gets the resolver.
|
void |
invalidUriResolverReader()
Invalid uri resolver reader.
|
void |
lockReader()
Lock reader.
|
void |
releaseReader()
Release reader.
|
void |
setApplicationType(String applicationType) |
void |
setTimerUriResolverReader(long delay,
long period)
Sets the timer uri resolver reader.
|
public static int RESET_DELAY
public static int RESET_TIME
public static final org.slf4j.Logger logger
public UriResolverManager()
throws UriResolverMapException,
IllegalArgumentException
ScopeProvider.instance.get()
The scope is used to look up the generic resource UriResolverMapReader#URI_RESOLVER_MAP available in the infrastructure to map ApplicationType with its ResolverUriResolverMapException - the uri resolver map exceptionIllegalArgumentException - the illegal argument exceptionpublic UriResolverManager(String applicationType) throws UriResolverMapException, IllegalArgumentException
ScopeProvider.instance.get()
The scope is used to look up the generic resource UriResolverMapReader#URI_RESOLVER_MAP available in the infrastructure to map ApplicationType with its ResolverapplicationType - a (valid) key Application Type getApplicationTypes()UriResolverMapException - the uri resolver map exceptionIllegalArgumentException - the illegal argument exceptionpublic void lockReader()
public void releaseReader()
public int countReaders()
public void setApplicationType(String applicationType) throws IllegalArgumentException
applicationType - the applicationType to setIllegalArgumentExceptionpublic String getLink(String applicationType, Map<String,String> parameters, boolean shortLink) throws IllegalArgumentException, UriResolverMapException
applicationType - the application typeparameters - the map of the parameters sent as HTTP query stringshortLink - if true the link is shorted otherwise noneIllegalArgumentException - the illegal argument exceptionUriResolverMapException - the uri resolver map exceptionpublic String getLink(Map<String,String> parameters, boolean shortLink) throws IllegalArgumentException, UriResolverMapException
parameters - the map of the parameters sent as HTTP query stringshortLink - if true the link is shorted otherwise noneIllegalArgumentException - the illegal argument exceptionUriResolverMapException - the uri resolver map exceptionpublic Set<String> getApplicationTypes()
public List<ServiceParameter> discoveryServiceParameters(Resolver resolver) throws IllegalArgumentException, Exception
resolver - the resolverIllegalArgumentException - the illegal argument exceptionException - the exceptionpublic Resolver getResolver(String applicationType)
applicationType - the application typepublic Map<String,Resolver> getCapabilities()
public void setTimerUriResolverReader(long delay,
long period)
delay - the delayperiod - the periodpublic void cancelTimerUriResolverReader()
public void invalidUriResolverReader()
Copyright © 2015. All Rights Reserved.