org.mactor.framework.data
Class DataTable

java.lang.Object
  extended by org.mactor.framework.data.DataTable

public class DataTable
extends java.lang.Object


Nested Class Summary
static class DataTable.DataRow
           
 
Constructor Summary
DataTable()
           
 
Method Summary
 void addColumn(java.lang.String column)
           
 void addRow(java.util.List<java.lang.String> cellValues)
           
 void addRow(java.lang.String[] cellValues)
           
 java.lang.String getColumn(int index)
           
 int getColumnCount()
           
 int getRowCount()
           
 java.util.Map<java.lang.String,java.lang.String> getRowData(int rowIndex)
           
 java.lang.String getValue(int row, int column)
           
 java.lang.String getValue(int row, java.lang.String columnName)
           
 void setColumns(java.util.List<java.lang.String> columns)
           
 java.lang.String toString()
           
 void writeAsCsv(java.io.Writer out)
           
 void writeAsHtml(java.io.Writer out)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DataTable

public DataTable()
Method Detail

setColumns

public void setColumns(java.util.List<java.lang.String> columns)

addColumn

public void addColumn(java.lang.String column)

getColumnCount

public int getColumnCount()

getColumn

public java.lang.String getColumn(int index)

getRowData

public java.util.Map<java.lang.String,java.lang.String> getRowData(int rowIndex)

addRow

public void addRow(java.util.List<java.lang.String> cellValues)

addRow

public void addRow(java.lang.String[] cellValues)

getRowCount

public int getRowCount()

getValue

public java.lang.String getValue(int row,
                                 java.lang.String columnName)

getValue

public java.lang.String getValue(int row,
                                 int column)

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

writeAsHtml

public void writeAsHtml(java.io.Writer out)
                 throws java.io.IOException
Throws:
java.io.IOException

writeAsCsv

public void writeAsCsv(java.io.Writer out)
                throws java.io.IOException
Throws:
java.io.IOException


Copyright © 2008. All Rights Reserved.