|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface IFileImporter
This interface describes an importer for a file type.
| Method Summary | |
|---|---|
boolean |
close()
Closes the file. |
JComponent |
getConfigurationPanel()
This method returns the panel that is used to configure the importer. |
Date |
getDate(int column)
Returns the given column as a date |
Integer |
getInt(int column)
Returns the given column as an integer |
Long |
getLong(int column)
Returns the given column as a long |
String[][] |
getPreview(int noOfLines)
Returns a preview of the importer's data in string format |
int |
getRows()
Returns the number of rows in the file. |
String |
getString(int column)
Returns the given column as a string |
boolean |
next()
Moves the file pointer to the next row. |
boolean |
open()
Opens the file. |
boolean |
reset()
Resets the file pointer to the first row. |
| Method Detail |
|---|
boolean open()
throws IOException
true on success, false otherwise
IOException - If an I/O error occurs, this exception is thrown
boolean close()
throws IOException
true on success, false otherwise
IOException - If an I/O error occurs, this exception is thrown
String[][] getPreview(int noOfLines)
throws IOException
noOfLines - The lines to return
IOException - If an error reading the import file occurred.
int getRows()
throws IOException
IOException - If an I/O error occurs, this exception is thrown
boolean reset()
throws IOException
true on success, false otherwise
IOException - If an I/O error occurs, this exception is thrown
boolean next()
throws IOException
true on success, false otherwise
IOException - If an I/O error occurs, this exception is thrown
String getString(int column)
throws IOException
column - The column number to retrieve
IOException - If an I/O error occurs, this exception is thrown
Long getLong(int column)
throws IOException,
UnsupportedFormatException
column - The column number to retrieve
IOException - If an I/O error occurs, this exception is thrown
UnsupportedFormatException - If the column cannot be converted to a
long
Integer getInt(int column)
throws IOException,
UnsupportedFormatException
column - The column number to retrieve
IOException - If an I/O error occurs, this exception is thrown
UnsupportedFormatException - If the column cannot be converted to an
integer
Date getDate(int column)
throws IOException,
UnsupportedFormatException
column - The column number to retrieve
IOException - If an I/O error occurs, this exception is thrown
UnsupportedFormatException - If the column cannot be converted to a
dateJComponent getConfigurationPanel()
null to
signal, that no configuration is possible and no dialog should be shown.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||