Main Page | Class Hierarchy | Class List | Class Members

kddml.Core.DataSources.DataBaseFactory Class Reference

Inheritance diagram for kddml.Core.DataSources.DataBaseFactory:

kddml.Core.DataSources.InternalTableExternalFactory kddml.Core.DataSources.InternalTableResourceFactory kddml.Core.KDDMLObjectResourceFactory kddml.Core.KDDMLObjectFactory List of all members.

Public Member Functions

 DataBaseFactory (File f, String sql_query, JDBCConnection connection) throws KDDMLCoreException
 DataBaseFactory (File f, File sql_query_path, JDBCConnection connection) throws KDDMLCoreException
void setEmptyResultAdmitted (boolean empty_table_admitted)

Protected Member Functions

Instance nextInstance (Instances schema) throws InternalTableException
int getNumberOfAttributes ()
Attribute getAttribute (int i) throws KDDMLCoreException
String getRelationName ()

Detailed Description

A factory class that creates a table from a database.

Title: KDDML

Description: Knowledge Discovery in Database Environment

Copyright: Copyright (c) 2003-2005

Company: Universita' di Pisa - Dipartimento di Informatica

Author:
Andrea Romei (romei@di.unipi.it)
Version:
2.0.16


Constructor & Destructor Documentation

kddml.Core.DataSources.DataBaseFactory.DataBaseFactory File  f,
String  sql_query,
JDBCConnection  connection
throws KDDMLCoreException
 

Constructor given the physical file containing the object, the sql SELECT query as string and the DBMS connection parameters.

Parameters:
f File the file containing the reference to the physical object.
sql_query String the SQL SELECT query
connection JDBCConnection the parameters of the connection.
Exceptions:
KDDMLCoreException if an error occurs.

kddml.Core.DataSources.DataBaseFactory.DataBaseFactory File  f,
File  sql_query_path,
JDBCConnection  connection
throws KDDMLCoreException
 

Constructor given the physical file containing the object, the sql SELECT query as file and the DBMS connection parameters.

Parameters:
f File the file containing the reference to the physical object.
sql_query_path File the SQL SELECT query as file
connection JDBCConnection the parameters of the connection.
Exceptions:
KDDMLCoreException if an error occurs.


Member Function Documentation

void kddml.Core.DataSources.DataBaseFactory.setEmptyResultAdmitted boolean  empty_table_admitted  ) 
 

Validate empty results. Empty tables can be obtained from not-SELECT queries, for example using UPDATE SQL statements.

Parameters:
empty_table_admitted boolean if false, no empty results are admitted.

Instance kddml.Core.DataSources.DataBaseFactory.nextInstance Instances  schema  )  throws InternalTableException [protected, virtual]
 

Returns the next instance from the input resource. Returns null if no more instances are available.

Parameters:
schema Instances the data schema of the instances.
Exceptions:
InternalTableException if an error occurs.
Returns:
Instance

Implements kddml.Core.DataSources.InternalTableExternalFactory.

int kddml.Core.DataSources.DataBaseFactory.getNumberOfAttributes  )  [protected, virtual]
 

Returns the number of attributes of the table.

Returns:
int a positive integer.

Implements kddml.Core.DataSources.InternalTableExternalFactory.

Attribute kddml.Core.DataSources.DataBaseFactory.getAttribute int  i  )  throws KDDMLCoreException [protected, virtual]
 

Returns the i-th attribute belonging to the data schema. Attribute number starts from 0.

Parameters:
i int a positive integer from 0 to (number of attributes - 1).
Returns:
Attribute the attribute as instance of weka.core.Attribute.
Exceptions:
KDDMLCoreException 

Implements kddml.Core.DataSources.InternalTableExternalFactory.

String kddml.Core.DataSources.DataBaseFactory.getRelationName  )  [protected, virtual]
 

Returns the relation name of this table.

Returns:
String

Implements kddml.Core.DataSources.InternalTableExternalFactory.


Generated on Thu Feb 23 13:04:43 2006 for kddml by  doxygen 1.4.3