Class FIXGRIDHtmlExporter
java.lang.Object
org.eclnt.jsfserver.elements.util.FIXGRIDHtmlExporter
- All Implemented Interfaces:
IFIXGRIDHtmlExporter
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected String
protected String
protected String
protected String
protected String
protected String
protected String
addTable()
protected void
closeHtmlTable
(StringBuffer html) protected void
exportBodyBegin
(StringBuffer html, FIXGRIDBinding fixgrid) protected void
exportBodyCol
(StringBuffer html, FIXGRIDBinding fixgrid, org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo ci, List<String> row, int rowCounter, int colCounter) protected void
exportBodyEnd
(StringBuffer html, FIXGRIDBinding fixgrid) protected void
exportBodyRows
(StringBuffer html, FIXGRIDBinding fixgrid, List<org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo> columns, List<List<String>> data) protected void
exportFooterRow
(StringBuffer html, FIXGRIDBinding fixgrid, List<org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo> columns, List<String> row, int rowCounter) protected void
exportFooterRows
(StringBuffer html, FIXGRIDBinding fixgrid, List<org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo> columns) exportGridToHtml
(FIXGRIDBinding fixgrid, List<org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo> columns, List<List<String>> data, boolean selctedItemsOnly) protected void
exportHeaderRow
(StringBuffer html, FIXGRIDBinding fixgrid, List<org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo> columns, List<String> row, int rowCounter) protected void
exportHeaderRows
(StringBuffer html, FIXGRIDBinding fixgrid, List<org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo> columns) protected void
exportTitle
(StringBuffer html, FIXGRIDBinding fixgrid, List<org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo> columns, List<List<String>> data) protected String
findAlignmentForDataCell
(int rowIndex, String dataCellValue, org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo column) protected String
findAlignmentForHeaderCell
(int rowIndex, String dataCellValue, org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo column) protected String
findBackgroundColorForFooterCell
(int rowCounter, String string, org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo columnInfo) protected String
findBackgroundColorForHeaderCell
(int rowCounter, String string, org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo columnInfo) protected String
findBackgroundtForDataCell
(int i, String string, org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo columnInfo) protected String
findCellValue
(FIXGRIDBinding fixgrid, int rowCounter, int colCounter, List<String> row, org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo ci) Central value for retrieving the value of a cell.protected String
findStyleForBodyCol
(FIXGRIDBinding fixgrid, org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo ci, List<String> row, int rowCounter, int colCounter) protected String
findStyleForFooterCol
(FIXGRIDBinding fixgrid, List<org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo> columns, List<String> row, int rowCounter, int colCounter) protected String
findStyleForHeaderCol
(FIXGRIDBinding fixgrid, List<org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo> columns, List<String> row, int rowCounter, int colCounter) protected String
findTextColorForDataCell
(int i, String string, org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo columnInfo) protected String
findTextColorForFooterCell
(int rowCounter, String string, org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo columnInfo) protected String
findTextColorForHeaderCell
(int rowCounter, String string, org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo columnInfo) Resource path of the template that is used for building the "basic HTML page" into which the table content is placed.protected void
openHtmlTable
(StringBuffer html) readFooterRows
(FIXGRIDBinding fixgrid) readHeaderRows
(FIXGRIDBinding fixgrid) protected String
protected String
void
setGridTitle
(String gridTitle) Setting of title text that is printed before the grid.void
setStyleClassDataCell
(String styleClassDataCell) void
setStyleClassDataTable
(String styleClassDataTable) void
setStyleClassFooterCell
(String styleClassFooterCell) void
setStyleClassHeaderCell
(String styleClassHeaderCell) void
setTemplatePath
(String templateName)
-
Constructor Details
-
FIXGRIDHtmlExporter
public FIXGRIDHtmlExporter()
-
-
Method Details
-
getGridTitle
-
setGridTitle
Description copied from interface:IFIXGRIDHtmlExporter
Setting of title text that is printed before the grid.- Specified by:
setGridTitle
in interfaceIFIXGRIDHtmlExporter
-
getStyleClassDataTable
-
setStyleClassDataTable
-
getStyleClassDataCell
-
setStyleClassDataCell
-
getStyleClassHeaderCell
-
setStyleClassHeaderCell
-
getTemplatePath
Resource path of the template that is used for building the "basic HTML page" into which the table content is placed. The template is loaded by the class loader. -
setTemplatePath
-
exportGridToHtml
public String exportGridToHtml(FIXGRIDBinding fixgrid, List<org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo> columns, List<List<String>> data, boolean selctedItemsOnly) - Specified by:
exportGridToHtml
in interfaceIFIXGRIDHtmlExporter
-
readTemplate
-
exportBodyRows
protected void exportBodyRows(StringBuffer html, FIXGRIDBinding fixgrid, List<org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo> columns, List<List<String>> data) -
exportBodyBegin
-
exportBodyEnd
-
exportBodyCol
protected void exportBodyCol(StringBuffer html, FIXGRIDBinding fixgrid, org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo ci, List<String> row, int rowCounter, int colCounter) -
findStyleForBodyCol
protected String findStyleForBodyCol(FIXGRIDBinding fixgrid, org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo ci, List<String> row, int rowCounter, int colCounter) -
findCellValue
protected String findCellValue(FIXGRIDBinding fixgrid, int rowCounter, int colCounter, List<String> row, org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo ci) Central value for retrieving the value of a cell. By default the value of the exported String information is used. You may override this method in order to embed own HTML text content.
Please pay attention: String values must be ensured to only contain sanitized information (in order to e.g. prevent injection of JavaScript code. The methodsanitizeCellContentString(String)
is tranferring all "dangerous" characters into there HTML-representations. Use this method, too, for sanitzing content that you may pass in your version of this method - or, in case of really passing complex HTML content: ensure that this content is sanitized in some different way. -
openHtmlTable
-
closeHtmlTable
-
exportHeaderRows
protected void exportHeaderRows(StringBuffer html, FIXGRIDBinding fixgrid, List<org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo> columns) -
exportHeaderRow
protected void exportHeaderRow(StringBuffer html, FIXGRIDBinding fixgrid, List<org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo> columns, List<String> row, int rowCounter) -
findStyleForHeaderCol
protected String findStyleForHeaderCol(FIXGRIDBinding fixgrid, List<org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo> columns, List<String> row, int rowCounter, int colCounter) -
readHeaderRows
-
exportTitle
protected void exportTitle(StringBuffer html, FIXGRIDBinding fixgrid, List<org.eclnt.jsfserver.elements.impl.FIXGRIDComponent.ColumnInfo> columns, List<List<String>> data) -
sanitizeCellContentString
-
findAlignmentForHeaderCell
-
findAlignmentForDataCell
-
findTextColorForDataCell
-
findBackgroundtForDataCell
-
findTextColorForHeaderCell
-
findBackgroundColorForHeaderCell
-
addTable
-
addBodyTr
-
addBodyTd
-
addHeaderTr
-
addHeaderTh
-