public class CommonContextWebResourceURIGenerator extends Object implements WebResourceURIGenerator
WebResourceURIGenerator that expects having one or more
WebResourceURIGenerator instances packed into a Collection, registered as
ServletContext attribute. The key of the attribute is the full name of
WebResourceURIGenerator interface.| Constructor and Description |
|---|
CommonContextWebResourceURIGenerator(javax.servlet.ServletContext context) |
| Modifier and Type | Method and Description |
|---|---|
Optional<String> |
generateURI(String lib,
String file,
Optional<String> versionRange)
Resolves the URI of a
WebResource that can be inserted into an output (HTML, e-mail,
etc). |
public CommonContextWebResourceURIGenerator(javax.servlet.ServletContext context)
public Optional<String> generateURI(String lib, String file, Optional<String> versionRange)
WebResourceURIGeneratorWebResource that can be inserted into an output (HTML, e-mail,
etc).generateURI in interface WebResourceURIGeneratorlib - The library of the WebResource.file - The file name of the WebResource.WebResource or Optional.empty()
if the URI cannot be resolved.Copyright © 2011–2017 Everit Kft.. All rights reserved.