public abstract class ProportionalListReportByHtml extends FileOutputThread implements ProportionalListReport
Modifier and Type | Field and Description |
---|---|
static int |
HEADER_LINE_FIRST |
static int |
HEADER_LINE_LAST |
static int |
HEADER_LINE_MIDDLE |
static int |
HEADER_LINE_ONE_AND_ONLY |
protected HtmlFile |
out |
outputPath, writer
sessionResources
threadController
threadDoneListeners
ALIGN_CENTER, ALIGN_LEFT, ALIGN_RIGHT
GROUP_TERMINATION_ALLOWED_WITHOUT_CONFIRMATION, GROUP_TERMINATION_NOT_ALLOWED, GROUP_TERMINATION_REQUIRES_CONFIRMATION
Constructor and Description |
---|
ProportionalListReportByHtml(SessionResources sessionResources,
java.lang.String fileName,
java.lang.String title,
java.lang.String generator)
Constructs a new proportional list report
|
ProportionalListReportByHtml(SessionResources sessionResources,
java.lang.String fileName,
java.lang.String title,
java.lang.String generator,
boolean createOut)
Constructs a new proportional list report
|
Modifier and Type | Method and Description |
---|---|
protected void |
beginHtml()
Begins the HTML instruction set.
|
protected void |
beginHtml(boolean printOnLoad)
Begins the HTML instruction set.
|
protected void |
beginTable()
Starts a table in for proportional usage.
|
protected void |
beginTableNormal()
Starts a table in standard format / non-proportional usage.
|
protected void |
endHtml()
Ends the HTML instruction set.
|
protected void |
endTable()
Ends the current table.
|
java.lang.String |
getFileName() |
protected java.lang.String |
getFormattedDate(DataObject dataObject,
java.lang.String columnName)
Returns a database table date in a formatted way.
|
protected java.lang.String |
getFormattedDate(java.sql.Date date)
Formats a date and returns it.
|
protected void |
outputHead(int headerLineType,
java.lang.String[] columnHeaders,
int[] proportion)
Writes the head of the list.
|
protected void |
outputHead(int headerLineType,
java.lang.String[] columnHeaders,
int[] proportion,
int[] alignment)
Writes the head of the list with the default proportion.
|
protected void |
outputHead(java.lang.String[] columnHeaders)
Writes the head of the list with the default proportion.
|
protected void |
outputHead(java.lang.String[] columnHeaders,
int[] proportion)
Writes the head of the list with the default proportion.
|
protected void |
outputHead(java.lang.String[] columnHeaders,
int[] proportion,
int[] alignment)
Writes the head of the list with the default proportion (single head line).
|
protected void |
outputParameter(java.lang.String label,
java.lang.String value) |
protected void |
outputSubHeaders(java.lang.String[] columnHeaders,
int[] proportion)
Outputs sub column headers.
|
protected void |
outputSubHeaders(java.lang.String[] columnHeaders,
int[] proportion,
int[] alignment)
Outputs sub column headers.
|
protected void |
outputTitle(java.lang.String title)
Writes the title of the list.
|
protected void |
presentInBrowser()
Presents the created file in the browser.
|
protected void |
println(java.lang.String[] values)
Outputs one data row of the list in default proportion.
|
protected void |
println(java.lang.String[] values,
int[] proportion)
Outputs one data row of the list.
|
protected void |
println(java.lang.String[] values,
int[] proportion,
int[] alignment)
Outputs one data row of the list in default proportion.
|
protected void |
println(java.util.Vector<java.lang.Object> values) |
protected void |
println(java.util.Vector<java.lang.Object> values,
int[] proportion) |
protected void |
printSpaceLine()
Prints a space line in a table / an empty row.
|
protected void |
setAlignment(int columnIndex,
int alignType)
Sets the alignment of a specific column.
|
void |
setColumnSpace(int i)
Sets the number of columns to be used to divide data columns.
|
void |
setDefaultProportion(int[] defaultProportion)
Sets the column default proportion to influence column width.
|
void |
setLeftMargin(int i)
Sets the left margin.
|
void |
setRightMargin(int i)
Sets the right margin.
|
void |
setTableWidth(int i)
Sets the table width in %.
|
getOutputPath, setOutputFolder, writeTo
getSessionResources, isTerminationRequested, isToRun, requiresUserConfirmationToTerminate, runCore, setTerminationRequiresUserConfirmation, start, terminate
free, register, register, run, runPartAfterCore, setStatusInformation, setThreadController
addThreadDoneListener, fireThreadDone, fireThreadDone, getEventMessage, getFinalState, idle, logDebug, logError, logError, logInfo, setEventErrorMessage, setEventMessage, setFinalState
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, stop, stop, suspend, toString, yield
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
addThreadDoneListener, runCore, setThreadController, start
getName
runCore
public static final int HEADER_LINE_ONE_AND_ONLY
public static final int HEADER_LINE_FIRST
public static final int HEADER_LINE_MIDDLE
public static final int HEADER_LINE_LAST
protected HtmlFile out
public ProportionalListReportByHtml(SessionResources sessionResources, java.lang.String fileName, java.lang.String title, java.lang.String generator) throws java.io.IOException
sessionResources
- the session resources to usefileName
- the name of the output filetitle
- the title of the reportgenerator
- the report's generator identificationjava.io.IOException
public ProportionalListReportByHtml(SessionResources sessionResources, java.lang.String fileName, java.lang.String title, java.lang.String generator, boolean createOut) throws java.io.IOException
sessionResources
- the session resources to usefileName
- the name of the output filetitle
- the title of the reportgenerator
- the report's generator identificationcreateOut
- whether or not output is to create right nowjava.io.IOException
public java.lang.String getFileName()
getFileName
in interface FileDetermination
public void setColumnSpace(int i)
i
- the number of columns to be used to divide data columnspublic void setLeftMargin(int i)
i
- the new left marginpublic void setRightMargin(int i)
i
- the new right marginpublic void setTableWidth(int i)
i
- the new table width in %public void setDefaultProportion(int[] defaultProportion)
setDefaultProportion
in interface ProportionalListReport
defaultProportion
- the proportion usually to be usedprotected void setAlignment(int columnIndex, int alignType)
columnIndex
- the index of the regarded columnalignType
- the align type of the specified columnProportionalListReport.ALIGN_LEFT
,
ProportionalListReport.ALIGN_CENTER
,
ProportionalListReport.ALIGN_RIGHT
protected void beginHtml()
protected void beginHtml(boolean printOnLoad)
printOnLoad
- whether body tag should include onLoad="print()"protected void outputTitle(java.lang.String title)
title
- the title of the listprotected void outputParameter(java.lang.String label, java.lang.String value)
protected void outputHead(java.lang.String[] columnHeaders)
columnHeaders
- the column headerssetDefaultProportion(int[])
protected void outputHead(java.lang.String[] columnHeaders, int[] proportion, int[] alignment)
columnHeaders
- the column headersproportion
- the used proportion for this table headeralignment
- the alignment of the table headerprotected void outputHead(int headerLineType, java.lang.String[] columnHeaders, int[] proportion, int[] alignment)
headerLineType
- see HEADER_LINE_*columnHeaders
- the column headersproportion
- the used proportion for this table headeralignment
- the alignment of the table headerHEADER_LINE_ONE_AND_ONLY
,
HEADER_LINE_FIRST
,
HEADER_LINE_MIDDLE
,
HEADER_LINE_LAST
protected void outputHead(java.lang.String[] columnHeaders, int[] proportion)
columnHeaders
- the column headersproportion
- the column proportion to be usedprotected void outputHead(int headerLineType, java.lang.String[] columnHeaders, int[] proportion)
headerLineType
- the header line typecolumnHeaders
- the column headersproportion
- the column proportion to be usedHEADER_LINE_ONE_AND_ONLY
,
HEADER_LINE_FIRST
,
HEADER_LINE_MIDDLE
,
HEADER_LINE_LAST
protected void outputSubHeaders(java.lang.String[] columnHeaders, int[] proportion, int[] alignment)
columnHeaders
- the column headersproportion
- the column proportion to be usedalignment
- the alignment of these row cellsprotected void outputSubHeaders(java.lang.String[] columnHeaders, int[] proportion)
columnHeaders
- the column headersproportion
- the column proportion to be usedprotected void printSpaceLine()
protected void println(java.lang.String[] values)
values
- the row valuesprotected void println(java.lang.String[] values, int[] proportion, int[] alignment)
values
- the row valuesproportion
- the column proportion to be usedalignment
- the alignment of these row cellsprotected void println(java.lang.String[] values, int[] proportion)
values
- the row valuesproportion
- the column proportion to be usedprotected void println(java.util.Vector<java.lang.Object> values)
protected void println(java.util.Vector<java.lang.Object> values, int[] proportion)
protected void beginTableNormal()
protected void beginTable()
protected void endTable()
protected java.lang.String getFormattedDate(DataObject dataObject, java.lang.String columnName)
dataObject
- the DataObject used to access the tablecolumnName
- the name of the column containing the date valueprotected java.lang.String getFormattedDate(java.sql.Date date)
the
- date to be formattedprotected void endHtml()
protected void presentInBrowser()
Copyright 1998-2023 Christoph Mueller, Kaerntner Str. 56, D-70469 Stuttgart, Germany, https://www.perpus.de