public class StylesheetSource extends XmlDocumentSource
Note that changes to the stylesheet sources are not picked up, so the driver must be shut down and restarted in order to get changed stylesheets.
Constructor and Description |
---|
StylesheetSource(java.lang.String dnBase,
java.io.File pathBase)
Construct a StylesheetSource with the passed bases.
|
Modifier and Type | Method and Description |
---|---|
com.novell.xsl.Stylesheet |
getStylesheet(java.lang.String path)
Find and parse an XSLT stylesheet in the directory or
file system.
|
void |
releaseStylesheet(com.novell.xsl.Stylesheet stylesheet)
Call when finished using a Stylesheet returned by getStylesheet().
|
getXmlDocument
getFile, getFile, resolveFilename
public StylesheetSource(java.lang.String dnBase, java.io.File pathBase)
pathBase
- Base location for files in file system.dnBase
- Base location for objects in directory.public com.novell.xsl.Stylesheet getStylesheet(java.lang.String path) throws java.io.IOException
The returned stylesheet may be used without further synchronization by the calling thread. releaseStylesheet() must be called when the calling thread is finished using the Stylesheet so that the Stylesheet can be reused by a different thread.
path
- Path to XSLT stylesheet.java.io.IOException
- If data not found, is invalid XML or XSLT.releaseStylesheet(com.novell.xsl.Stylesheet)
public void releaseStylesheet(com.novell.xsl.Stylesheet stylesheet)
Calling this method marks the passed Stylesheet as not-in-use so that other threads may use it.
stylesheet
- Stylesheet returned from getStylesheet().getStylesheet(java.lang.String)