pl.edu.agh.cast.importer.base.logging
Class ImportLoggerPatternLayout
java.lang.Object
org.apache.log4j.Layout
org.apache.log4j.PatternLayout
pl.edu.agh.cast.importer.base.logging.ImportLoggerPatternLayout
- All Implemented Interfaces:
- org.apache.log4j.spi.OptionHandler
public class ImportLoggerPatternLayout
- extends org.apache.log4j.PatternLayout
The layout for the logger files, containing the import process logs, implementing the basic
PatternLayout
. Overrides the getHeader()
method.
- Author:
- AGH CAST Team
Fields inherited from class org.apache.log4j.PatternLayout |
BUF_SIZE, DEFAULT_CONVERSION_PATTERN, MAX_CAPACITY, TTCC_CONVERSION_PATTERN |
Fields inherited from class org.apache.log4j.Layout |
LINE_SEP, LINE_SEP_LEN |
Methods inherited from class org.apache.log4j.PatternLayout |
activateOptions, createPatternParser, format, getConversionPattern, ignoresThrowable, setConversionPattern |
Methods inherited from class org.apache.log4j.Layout |
getContentType |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ImportLoggerPatternLayout
public ImportLoggerPatternLayout(String pattern,
String importedFilePath,
String templateName,
String sheetName)
- The default constructor.
- Parameters:
pattern
- the logging patternimportedFilePath
- the path to the imported filetemplateName
- the template name used by the import operationsheetName
- the name of the sheet for data with multiple sheets
ImportLoggerPatternLayout
public ImportLoggerPatternLayout(String importedFilePath,
String templateName)
- The constructor for data with single data sheet.
- Parameters:
importedFilePath
- the path to the imported filetemplateName
- the template name used by the import operation
getHeader
public String getHeader()
-
- Overrides:
getHeader
in class org.apache.log4j.Layout
- See Also:
Layout.getHeader()
getFooter
public String getFooter()
-
- Overrides:
getFooter
in class org.apache.log4j.Layout
- See Also:
Layout.getFooter()
setFooterData
public void setFooterData(int rowsImported,
int rowsNotImported,
int rowsRemoved,
int errors,
String dataSet)
- Sets the data for the logger footer.
- Parameters:
rowsImported
- the number of rows importedrowsNotImported
- the number of rows not importedrowsRemoved
- the number of rows removederrors
- the number of errorsdataSet
- the data set name
Copyright © 2007-2009 IISG AGH-UST Krakow, Poland. All Rights Reserved.