Class ConfigurableSupportedContextResourceUri
- java.lang.Object
-
- org.ametys.plugins.core.ui.resources.css.ConfigurableSupportedContextResourceUri
-
- All Implemented Interfaces:
SupportedContextResourceUri
,Configurable
public class ConfigurableSupportedContextResourceUri extends Object implements SupportedContextResourceUri, Configurable
Default configurable implementation forSupportedContextResourceUri
. Can be configured to map contexts with URIs
-
-
Field Summary
Fields Modifier and Type Field Description private Map<String,String>
_supportedContext
-
Constructor Summary
Constructors Constructor Description ConfigurableSupportedContextResourceUri()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
configure(Configuration configuration)
String
resolve(String uri)
Resolve the uri with the context protocol.String
resolvePath(String path)
Resolve the context path into a context uri
-
-
-
Field Detail
-
_supportedContext
private Map<String,String> _supportedContext
-
-
Constructor Detail
-
ConfigurableSupportedContextResourceUri
public ConfigurableSupportedContextResourceUri()
-
-
Method Detail
-
configure
public void configure(Configuration configuration) throws ConfigurationException
- Specified by:
configure
in interfaceConfigurable
- Throws:
ConfigurationException
-
resolve
public String resolve(String uri)
Description copied from interface:SupportedContextResourceUri
Resolve the uri with the context protocol.- Specified by:
resolve
in interfaceSupportedContextResourceUri
- Parameters:
uri
- The URI- Returns:
- The resolved uri, or null if the protocol is not supported
-
resolvePath
public String resolvePath(String path)
Description copied from interface:SupportedContextResourceUri
Resolve the context path into a context uri- Specified by:
resolvePath
in interfaceSupportedContextResourceUri
- Parameters:
path
- The path- Returns:
- The uri, or null if the context path is not supported
-
-