Package ca.spatial.table
Class SummarizeTable
java.lang.Object
java.util.Observable
ca.spatial.table.SummarizeTable
Prepare a summary of the contents of a table.
The summary is displayed in HTML format and show columns names,
data types, widths and column contents. If the number of unique values
in a column is less than the uniqueSize parameter then these will
also be listed.
as = AttributeStore.openOrReuse("attributes.dbf"); new SummarizeTable(as, 20).execute().print("summary.html");
-
Constructor Summary
ConstructorsConstructorDescriptionSummarizeTable(AttributeStore as, int uniqueSize)
Create the SummarizeTable object and prepare to summarize. -
Method Summary
Modifier and TypeMethodDescriptionexecute()
Process records and summarize.format()
Get the summary infomration as an HTML string.int
getDec(int column)
getName(int column)
int
getSuggestedDec(int column)
int
getSuggestedWidth(int column)
int
int
getWidth(int column)
void
static void
void
Print the summary information to the named file.setUniqueLimit(int limit)
void
Methods inherited from class java.util.Observable
addObserver, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers
-
Constructor Details
-
SummarizeTable
Create the SummarizeTable object and prepare to summarize.- Parameters:
as
- A reference to the table to be summarizeduniqueSize
- The maximum number of unique values to keep track of before reporting too many values to list.
-
-
Method Details
-
setUniqueLimit
-
getUniqueLimit
public int getUniqueLimit() -
interrupt
public void interrupt() -
getName
-
getWidth
public int getWidth(int column) -
getDec
public int getDec(int column) -
getSuggestedWidth
public int getSuggestedWidth(int column) -
getSuggestedDec
public int getSuggestedDec(int column) -
execute
Process records and summarize. -
format
Get the summary infomration as an HTML string. -
print
Print the summary information to the named file.- Throws:
IOException
-
show
-
main
-