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 booleanm_AddFilenameadd the filename as header.protected Colorm_ColorFilenamethe color for the filename header.protected PdfFontm_FontFilenamethe 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 booleanaddFilename(PDFGenerator generator, File file)Adds the filename to the page as header, if necessary.StringaddFilenameTipText()Returns the tip text for this property.StringcolorFilenameTipText()Returns the tip text for this property.voiddefineOptions()Adds options to the internal list of options.StringfontFilenameTipText()Returns the tip text for this property.booleangetAddFilename()Returns whether to output the filename as well.ColorgetColorFilename()Returns the color to use for adding the filename header.PdfFontgetFontFilename()Returns the font to use for adding the filename header.voidsetAddFilename(boolean value)Sets whether to output the filename as well.voidsetColorFilename(Color value)Sets the color to use for adding the filename header.voidsetFontFilename(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:
defineOptionsin interfaceOptionHandler- Overrides:
defineOptionsin classAbstractPdfProclet
-
setAddFilename
public void setAddFilename(boolean value)
Sets whether to output the filename as well.- Specified by:
setAddFilenamein 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:
getAddFilenamein interfacePdfProcletWithFilenameOutput- Returns:
- true if the filename gets added as well
-
addFilenameTipText
public String addFilenameTipText()
Returns the tip text for this property.- Specified by:
addFilenameTipTextin 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:
setFontFilenamein interfacePdfProcletWithFilenameOutput- Parameters:
value- the font
-
getFontFilename
public PdfFont getFontFilename()
Returns the font to use for adding the filename header.- Specified by:
getFontFilenamein interfacePdfProcletWithFilenameOutput- Returns:
- the font
-
fontFilenameTipText
public String fontFilenameTipText()
Returns the tip text for this property.- Specified by:
fontFilenameTipTextin 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:
setColorFilenamein interfacePdfProcletWithFilenameOutput- Parameters:
value- the color
-
getColorFilename
public Color getColorFilename()
Returns the color to use for adding the filename header.- Specified by:
getColorFilenamein interfacePdfProcletWithFilenameOutput- Returns:
- the color
-
colorFilenameTipText
public String colorFilenameTipText()
Returns the tip text for this property.- Specified by:
colorFilenameTipTextin 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
-
-