com.infoviz.datamodel.table
Class IVTableModelFactory
java.lang.Object
com.infoviz.datamodel.table.IVTableModelFactory
- public class IVTableModelFactory
- extends java.lang.Object
This class provides methods to create IVTableModel from
different commonly used table formats.
$Id$
$Revision$
$Author$
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
IVTableModelFactory
public IVTableModelFactory()
fromDelimitedInputStream
public static IVTableModel fromDelimitedInputStream(java.io.InputStream in,
java.lang.String delimiter,
IVTableDefinition td)
throws java.io.IOException,
java.lang.IllegalAccessException,
java.lang.reflect.InvocationTargetException,
java.lang.NoSuchMethodException
- creates IVTableModel by reading lines from a InputStream.
Each line in the input stream should have the column values
separated by the supplied delimiter. The order and type of
column values should match the supplied IVTableDefinition.
Values of type String, Integer, Double, BigDecimal, and Date
are automatically parsed from the strings but for other types
the corresponding class must have a CustomClass fromString(String s) method.
- Parameters:
in
- delimiter
- td
-
- Returns:
- a model
- Throws:
java.lang.NoSuchMethodException
- fromString method is not supplied for a custom class
java.lang.reflect.InvocationTargetException
- fromString method is not static
java.io.IOException
- problem reading in
java.lang.NumberFormatException
- The column value is not valid for the corresponding column type
java.lang.IllegalAccessException