public class DifferencesPDFPresenter extends ExportFilePresenter
getExportStream()
method.ExportFilePresenter.HasPrintRange
BasePresenter.ERROR_SOURCE
PAINT_BOTH, PAINT_LEFT, PAINT_RIGHT
LOGGER, MAX_FILENAME_LENGTH
Modifier | Constructor and Description |
---|---|
|
DifferencesPDFPresenter(java.io.File rootFolder)
Creates the presenter
|
|
DifferencesPDFPresenter(java.io.File target,
boolean isFolder)
Creates the presenter
|
|
DifferencesPDFPresenter(java.io.OutputStream customStream)
Creates the presenter.
|
protected |
DifferencesPDFPresenter()
Shortcut to better support spawn for extended classes
|
Modifier and Type | Method and Description |
---|---|
protected java.io.OutputStream |
getExportStream()
Opens an returns an output stream for the result of the current
BasePresenter.getModel() . |
protected java.lang.String |
getExtension()
Get the extension of the target file
|
java.lang.String |
getExtensionName()
Returns the UNIQUE name of the extension.
|
void |
onComparisonDone()
Creates the actual result PDF Called to indicate that a comparison has finished.
|
void |
setPagelayout(int pageWidth,
int pageHeight,
int marginLeft,
int marginTop,
int marginRight,
int marginBottom)
Set the desired pageLayout for the pdf to render.
|
BasePresenter |
spawn(boolean spawnWithParent)
Creates another presenter of the the same type as the current one.
|
applyPrintRange, configure, setExportOnlyOnDifferences, setModel, setPrintRange
createAndSetupPrintPainter, setAddHeaderFooter, setBackgroundColor, setColorprovider, setOverlapAlpha, setPaintOverlap, setPaintSides, setScaleToFitPageHeight
canInformUserOnErrors, createExportFilename, detachFromModel, executeImmediately, getDefaultExportName, getLastPresenterException, getModel, getParent, getPresenterExceptions, onClear, onDataUpdate, onError, onFilterChange, onFinish, onInit, onProgressUpdate, setParent
public DifferencesPDFPresenter(java.io.File rootFolder)
rootFolder
- the folder to store the comparison results to.java.lang.IllegalStateException
- in case there is no 'reporting' plugin availablepublic DifferencesPDFPresenter(java.io.File target, boolean isFolder)
target
- the folder or file to store the comparison results to.isFolder
- if the target is a folder or a filejava.lang.IllegalStateException
- in case there is no 'reporting' plugin availablepublic DifferencesPDFPresenter(java.io.OutputStream customStream)
customStream
- the stream to export to.protected DifferencesPDFPresenter() throws java.lang.IllegalStateException
java.lang.IllegalStateException
- thrown if there is no active 'reporting' plugin availablepublic java.lang.String getExtensionName()
public BasePresenter spawn(boolean spawnWithParent)
spawn
in class BasePresenter
spawnWithParent
- if true, the presenter is allowed to keep a reference to it's parent to create a summary on onFinish()protected java.io.OutputStream getExportStream() throws java.io.IOException
BasePresenter.getModel()
. The caller of this method
will close the stream itself!getExportStream
in class ExportFilePresenter
java.io.IOException
- thrown in case the stream could not be createdpublic void onComparisonDone() throws java.lang.Exception
onComparisonDone
in class BasePresenter
java.lang.Exception
- thrown in case the processing of the finish step failsprotected java.lang.String getExtension()
getExtension
in class ExportFilePresenter
public void setPagelayout(int pageWidth, int pageHeight, int marginLeft, int marginTop, int marginRight, int marginBottom)
pageWidth
- the desired with in px, including margins.pageHeight
- the desired height in px, including margins.marginLeft
- margins to apply on the left side in px.marginTop
- margins to apply on top of the page in px.marginRight
- margins to apply on the right side in px.marginBottom
- margins to apply on the bottom side in px.Copyright © 2010-2022 by i-net software GmbH