Class AbstractPdfProcletWithFilenameOutput
- java.lang.Object
-
- adams.core.logging.LoggingObject
-
- adams.core.logging.CustomLoggingLevelObject
-
- adams.core.option.AbstractOptionHandler
-
- adams.flow.transformer.pdfproclet.AbstractPdfProclet
-
- adams.flow.transformer.pdfproclet.AbstractPdfProcletWithFilenameOutput
-
- All Implemented Interfaces:
Destroyable
,GlobalInfoSupporter
,LoggingLevelHandler
,LoggingSupporter
,OptionHandler
,SizeOfHandler
,PdfProclet
,PdfProcletWithFilenameOutput
,Serializable
- Direct Known Subclasses:
AbstractPdfProcletWithPageBreaks
public abstract class AbstractPdfProcletWithFilenameOutput extends AbstractPdfProclet implements PdfProcletWithFilenameOutput
Abstract ancestor for processors that can add the filename as well.- Version:
- $Revision$
- Author:
- fracpete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected boolean
m_AddFilename
add the filename as header.protected Color
m_ColorFilename
the color for the filename header.protected PdfFont
m_FontFilename
the font for the filename header.-
Fields inherited from class adams.flow.transformer.pdfproclet.AbstractPdfProclet
m_RegExpFilename, MATCH_ALL_EXTENSION
-
Fields inherited from class adams.core.option.AbstractOptionHandler
m_OptionManager
-
Fields inherited from class adams.core.logging.LoggingObject
m_Logger, m_LoggingIsEnabled, m_LoggingLevel
-
-
Constructor Summary
Constructors Constructor Description AbstractPdfProcletWithFilenameOutput()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected boolean
addFilename(PDFGenerator generator, File file)
Adds the filename to the page as header, if necessary.String
addFilenameTipText()
Returns the tip text for this property.String
colorFilenameTipText()
Returns the tip text for this property.void
defineOptions()
Adds options to the internal list of options.String
fontFilenameTipText()
Returns the tip text for this property.boolean
getAddFilename()
Returns whether to output the filename as well.Color
getColorFilename()
Returns the color to use for adding the filename header.PdfFont
getFontFilename()
Returns the font to use for adding the filename header.void
setAddFilename(boolean value)
Sets whether to output the filename as well.void
setColorFilename(Color value)
Sets the color to use for adding the filename header.void
setFontFilename(PdfFont value)
Sets the font to use for adding the filename header.-
Methods inherited from class adams.flow.transformer.pdfproclet.AbstractPdfProclet
addColumnTextAt, addElement, canProcess, canProcess, doProcess, doProcess, getExtensions, getRegExpFilename, postProcess, postProcess, preProcess, preProcess, process, process, regExpFilenameTipText, setRegExpFilename
-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, destroy, finishInit, getDefaultLoggingLevel, getOptionManager, globalInfo, initialize, loggingLevelTipText, newOptionManager, reset, setLoggingLevel, toCommandLine, toString
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface adams.core.Destroyable
destroy
-
Methods inherited from interface adams.core.logging.LoggingLevelHandler
getLoggingLevel
-
Methods inherited from interface adams.core.option.OptionHandler
cleanUpOptions, getOptionManager, toCommandLine
-
Methods inherited from interface adams.flow.transformer.pdfproclet.PdfProclet
canProcess, canProcess, getExtensions, getRegExpFilename, process, process, regExpFilenameTipText, setRegExpFilename
-
-
-
-
Method Detail
-
defineOptions
public void defineOptions()
Adds options to the internal list of options.- Specified by:
defineOptions
in interfaceOptionHandler
- Overrides:
defineOptions
in classAbstractPdfProclet
-
setAddFilename
public void setAddFilename(boolean value)
Sets whether to output the filename as well.- Specified by:
setAddFilename
in interfacePdfProcletWithFilenameOutput
- Parameters:
value
- if true then the filename gets added as well
-
getAddFilename
public boolean getAddFilename()
Returns whether to output the filename as well.- Specified by:
getAddFilename
in interfacePdfProcletWithFilenameOutput
- Returns:
- true if the filename gets added as well
-
addFilenameTipText
public String addFilenameTipText()
Returns the tip text for this property.- Specified by:
addFilenameTipText
in interfacePdfProcletWithFilenameOutput
- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setFontFilename
public void setFontFilename(PdfFont value)
Sets the font to use for adding the filename header.- Specified by:
setFontFilename
in interfacePdfProcletWithFilenameOutput
- Parameters:
value
- the font
-
getFontFilename
public PdfFont getFontFilename()
Returns the font to use for adding the filename header.- Specified by:
getFontFilename
in interfacePdfProcletWithFilenameOutput
- Returns:
- the font
-
fontFilenameTipText
public String fontFilenameTipText()
Returns the tip text for this property.- Specified by:
fontFilenameTipText
in interfacePdfProcletWithFilenameOutput
- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
setColorFilename
public void setColorFilename(Color value)
Sets the color to use for adding the filename header.- Specified by:
setColorFilename
in interfacePdfProcletWithFilenameOutput
- Parameters:
value
- the color
-
getColorFilename
public Color getColorFilename()
Returns the color to use for adding the filename header.- Specified by:
getColorFilename
in interfacePdfProcletWithFilenameOutput
- Returns:
- the color
-
colorFilenameTipText
public String colorFilenameTipText()
Returns the tip text for this property.- Specified by:
colorFilenameTipText
in interfacePdfProcletWithFilenameOutput
- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
addFilename
protected boolean addFilename(PDFGenerator generator, File file) throws Exception
Adds the filename to the page as header, if necessary.- Parameters:
generator
- the contextfile
- the plain text file- Returns:
- true if successfully added
- Throws:
Exception
- if something goes wrong
-
-