Interface StylesheetWriter
-
public interface StylesheetWriter
If aSyntaxHighlighterAdapter
also implements this interface it will be called while rendering to write a stylesheet to disc.This only happens if the output is written to file and the attributes
:linkcss
and:copycss
are set.This API is experimental and might change in an incompatible way in a minor version update!
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
isWriteStylesheet(Document doc)
Has to returntrue
if Asciidoctor should callwriteStylesheet(Document, File)
.void
writeStylesheet(Document doc, java.io.File toDir)
Allows to write additional stylesheets to disk while rendering a document.
-
-
-
Method Detail
-
isWriteStylesheet
boolean isWriteStylesheet(Document doc)
Has to returntrue
if Asciidoctor should callwriteStylesheet(Document, File)
.- Parameters:
doc
- The current document that is rendered.- Returns:
true
ifwriteStylesheet(Document, File)
should be called.
-
writeStylesheet
void writeStylesheet(Document doc, java.io.File toDir)
Allows to write additional stylesheets to disk while rendering a document. References to this stylesheet should be added bySyntaxHighlighterAdapter.getDocinfo(LocationType, Document, Map)
.- Parameters:
doc
- The current document to be rendered.toDir
- The file representing the absolute path to the directory where the stylesheet should be written.
-
-