Package io.github.jbastgen.stemma.app.ai
Class CoworkExport
java.lang.Object
io.github.jbastgen.stemma.app.ai.CoworkExport
Takes the results of the Cowork view out of the application: as formatted text for the clipboard (HTML for mails and word processors,
the Markdown as plain text), and as a PDF. The PDF is drawn the way the results look, always in the light theme, in A4 pages that break
between blocks where they can; see
PdfDocument for what that means for the text in the file. Needs the JavaFX thread.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordA question and the answer to it (Markdown). -
Method Summary
Modifier and TypeMethodDescriptionstatic javafx.scene.input.ClipboardContentclipboard(List<CoworkExport.Entry> entries) HTML and plain text: with one entry just its answer, with several each answer after its question.static PdfDocumentpdf(String repoName, List<CoworkExport.Entry> entries) The results as a document that is ready to be written withPdfDocument.toBytes().
-
Method Details
-
clipboard
HTML and plain text: with one entry just its answer, with several each answer after its question. The plain text is the Markdown itself, so a text editor gets something readable too. -
pdf
The results as a document that is ready to be written withPdfDocument.toBytes().- Throws:
IOException
-