Package com.complexible.common.timer
Class TableData
- java.lang.Object
-
- com.complexible.common.timer.TableData
-
public class TableData extends java.lang.Object
Create a table data structure that has a list of column names and list of data rows. The only function of this class is to print the data in a table format. Data can be given at once by the constructor or can be added incrementally with the addRow function.- Since:
- 2.0
- Version:
- 2.0
- Author:
- Evren Sirin
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(java.util.List row)
int
getColCount()
int
getRowCount()
void
print(java.io.OutputStream writer)
void
print(java.io.PrintWriter out)
void
print(java.io.Writer writer)
void
setAlignment(boolean[] rightAligned)
void
setrightAligned(int colIndex, boolean rightAligned)
void
sort(int col)
void
sort(int col, java.util.Comparator c)
void
sort(java.lang.String colName)
java.lang.String
toString()
-
-
-
Method Detail
-
setAlignment
public void setAlignment(boolean[] rightAligned)
-
setrightAligned
public void setrightAligned(int colIndex, boolean rightAligned)
-
add
public void add(java.util.List row)
-
print
public void print(java.io.OutputStream writer)
-
print
public void print(java.io.PrintWriter out)
-
print
public void print(java.io.Writer writer)
-
getRowCount
public int getRowCount()
-
getColCount
public int getColCount()
-
sort
public void sort(java.lang.String colName)
-
sort
public void sort(int col)
-
sort
public void sort(int col, java.util.Comparator c)
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-