|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectde.dfki.mycbr.io.DataBaseImporter
public class DataBaseImporter
class to import a casebase from a postgres database
| Nested Class Summary | |
|---|---|
static class |
DataBaseImporter.DataBaseImporterError
|
| Constructor Summary | |
|---|---|
DataBaseImporter(int id,
Project project,
Concept concept,
java.lang.String dbmapping)
Constructor for DataBaseImporter |
|
| Method Summary | |
|---|---|
void |
addMissingValues()
method to add values from the table to an attributes allowed values Only for used |
void |
checkData()
method to check if the read data is valid |
boolean |
connectToDatabase(int id)
Establish a connection to a given postgreSQL Database |
void |
doImport()
maps the read data to cases |
int |
getCurrentNumberOfCases()
|
java.lang.String |
getSeperatorMultiple()
|
java.lang.String |
getTableName()
Returns the TableName which should be used for import |
int |
getTotalNumberOfCases()
|
boolean |
isImporting()
|
boolean |
readData(java.lang.String table,
java.lang.String[] filtercolumns,
java.lang.String[] filtervalues)
Reads the Data from the table of a given database |
void |
readMetaDataFromDatabase(java.lang.String table)
Method to get the columnNames of the table from which the data is read |
void |
readMetaDataFromXML()
Method to get the mapping for columns and attributes from an xml file |
void |
setSeperatorMultiple(java.lang.String seperator)
|
void |
setTableName(java.lang.String tablename)
Sets the tablename which should be used for import |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DataBaseImporter(int id,
Project project,
Concept concept,
java.lang.String dbmapping)
id - of the database to use for the CaseBaseproject - used for the CaseBaseconcept - used for the CaseBase| Method Detail |
|---|
public boolean connectToDatabase(int id)
public boolean readData(java.lang.String table,
java.lang.String[] filtercolumns,
java.lang.String[] filtervalues)
table - the name of the table to read the data fromfiltercolumns - an array with the names of the columns for a where clausefiltervalues - an array with the values of the columns for a where clause
public void readMetaDataFromDatabase(java.lang.String table)
public void readMetaDataFromXML()
public void addMissingValues()
public void checkData()
public void doImport()
public java.lang.String getTableName()
public void setTableName(java.lang.String tablename)
tablename - public int getTotalNumberOfCases()
public int getCurrentNumberOfCases()
public java.lang.String getSeperatorMultiple()
public void setSeperatorMultiple(java.lang.String seperator)
public boolean isImporting()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||