|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectlumis.portal.xslcache.XslCacheManager
public class XslCacheManager
Manages the cache for XSLs.
Nested Class Summary | |
---|---|
static class |
XslCacheManager.LumisTransformer
Transformer delegate that store, besides the own transformer, a boolean indicating whether the owned transformer has ELs or not. |
Field Summary | |
---|---|
static String |
TOKEN_CLOSE_BRACKET
|
static String |
TOKEN_OPEN_BRACKET
|
Constructor Summary | |
---|---|
XslCacheManager()
|
Method Summary | |
---|---|
void |
add(SessionConfig sessionConfig,
XslCacheConfig xslCacheConfig,
ITransaction transaction)
Add a cache of the XSL. |
void |
clearXslCache(ITransaction transaction)
Clears all XSL cache. |
void |
clearXslCache(SessionConfig sessionConfig,
String fileName,
ITransaction transaction)
Clear the cache for the specified xsl file. |
void |
clearXslConfigCache(SessionConfig sessionConfig,
ITransaction transaction)
Clear the XslConfigCache. |
void |
clearXslConfigCache(SessionConfig sessionConfig,
String fileName,
ITransaction transaction)
Clear the XslConfigCache. |
Transformer |
createTransformer(String resourcePath)
Creates a transformer for a XSL in the specified path. |
Transformer |
createTransformer(String resourcePath,
List<? extends ITheme> themes)
Creates a transformer for a XSL in the specified path, with the given themes applied. |
Transformer |
createTransformer(String xslStringDocument,
String resourcePath)
Creates a transformer for a specified XSL document string. |
Transformer |
createTransformer(String xslStringDocument,
String resourcePath,
List<? extends ITheme> themes)
Creates a transformer for a specified XSL document string. |
void |
delete(SessionConfig sessionConfig,
String fileName,
ITransaction transaction)
Delete de cache of the XSL. |
XslCacheConfig |
get(SessionConfig sessionConfig,
String fileName,
ITransaction transaction)
Get the XslCacheConfig. |
boolean |
getDefaultCache()
Get the default cache. |
Transformer |
getTransformer(SessionConfig sessionConfig,
String fileName,
ITransaction transaction)
Get a Transformer. |
Transformer |
getTransformer(SessionConfig sessionConfig,
String xslPath,
List<? extends ITheme> themes,
ITransaction transaction)
Returns a transformer for a XSL in the specified path, with the given themes applied. |
boolean |
isXslCached(String fileName)
Verify if the xsl file is cached. |
void |
setDefaultCache(boolean enable)
Set the default cache. |
void |
update(SessionConfig sessionConfig,
XslCacheConfig xslCacheConfig,
ITransaction transaction)
Update the cache of the XSL. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String TOKEN_OPEN_BRACKET
public static final String TOKEN_CLOSE_BRACKET
Constructor Detail |
---|
public XslCacheManager()
Method Detail |
---|
public void setDefaultCache(boolean enable)
IXslCacheManager
setDefaultCache
in interface IXslCacheManager
public boolean getDefaultCache()
IXslCacheManager
getDefaultCache
in interface IXslCacheManager
public void add(SessionConfig sessionConfig, XslCacheConfig xslCacheConfig, ITransaction transaction) throws PortalException, ManagerException
IXslCacheManager
add
in interface IXslCacheManager
PortalException
ManagerException
public void delete(SessionConfig sessionConfig, String fileName, ITransaction transaction) throws PortalException, ManagerException
IXslCacheManager
delete
in interface IXslCacheManager
PortalException
ManagerException
public void update(SessionConfig sessionConfig, XslCacheConfig xslCacheConfig, ITransaction transaction) throws PortalException, ManagerException
IXslCacheManager
update
in interface IXslCacheManager
PortalException
ManagerException
public XslCacheConfig get(SessionConfig sessionConfig, String fileName, ITransaction transaction) throws PortalException, ManagerException
IXslCacheManager
get
in interface IXslCacheManager
PortalException
ManagerException
public void clearXslConfigCache(SessionConfig sessionConfig, String fileName, ITransaction transaction) throws PortalException, ManagerException
IXslCacheManager
clearXslConfigCache
in interface IXslCacheManager
PortalException
ManagerException
public void clearXslConfigCache(SessionConfig sessionConfig, ITransaction transaction) throws PortalException, ManagerException
IXslCacheManager
clearXslConfigCache
in interface IXslCacheManager
PortalException
ManagerException
public Transformer getTransformer(SessionConfig sessionConfig, String fileName, ITransaction transaction) throws PortalException, ManagerException
IXslCacheManager
getTransformer
in interface IXslCacheManager
PortalException
ManagerException
public Transformer getTransformer(SessionConfig sessionConfig, String xslPath, List<? extends ITheme> themes, ITransaction transaction) throws PortalException
IXslCacheManager
getTransformer
in interface IXslCacheManager
sessionConfig
- user session information.xslPath
- the classpath relative resource path where the
XSL is present.themes
- a list with the themes,in the same order they are applied.transaction
- the transaction for persistence access.
PortalException
- if the transformer could not be created.public Transformer createTransformer(String resourcePath) throws PortalException
IXslCacheManager
createTransformer
in interface IXslCacheManager
resourcePath
- the relative classpath resource path where the
document is present.
PortalException
- if the transformer could not be created.IXslCacheManager.createTransformer(String, List)
public Transformer createTransformer(String resourcePath, List<? extends ITheme> themes) throws PortalException
IXslCacheManager
createTransformer
in interface IXslCacheManager
resourcePath
- the relative classpath resource path where the
document is present.themes
- a list with the themes,in the same order they are applied.
PortalException
- if the transformer could not be created.public Transformer createTransformer(String xslStringDocument, String resourcePath) throws PortalException
IXslCacheManager
createTransformer
in interface IXslCacheManager
xslStringDocument
- the XSL document as a string.resourcePath
- the relative classpath resource path where the
document is considered to exist, for URI resolution purposes.
PortalException
- if the transformer could not be created.public Transformer createTransformer(String xslStringDocument, String resourcePath, List<? extends ITheme> themes) throws PortalException
IXslCacheManager
createTransformer
in interface IXslCacheManager
xslStringDocument
- the XSL document as a string.resourcePath
- the relative classpath resource path where the
document is considered to exist, for URI resolution purposes.themes
- the applied themes.
PortalException
- if the transformer could not be created.public void clearXslCache(SessionConfig sessionConfig, String fileName, ITransaction transaction) throws PortalException, ManagerException
IXslCacheManager
clearXslCache
in interface IXslCacheManager
sessionConfig
- the user session information.fileName
- the xsl file path.transaction
- the transaction for persistence access.
PortalException
ManagerException
public void clearXslCache(ITransaction transaction) throws PortalException
IXslCacheManager
clearXslCache
in interface IXslCacheManager
transaction
- the transaction for persistence access. If null,
the cache is just cleared, else it is cleared as a transactional
operation as specified in PortalCache.clear(ITransaction)
.
PortalException
public boolean isXslCached(String fileName)
IXslCacheManager
isXslCached
in interface IXslCacheManager
fileName
- the xsl file path.
true
if any variant of the xsl is being cached,
or false
otherwise.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |