Environment for
DeveLoping
KDD-Applications
Supported by Index-Structures

de.lmu.ifi.dbs.elki.database.connection
Class MultipleFileBasedDatabaseConnection<O extends DatabaseObject>

java.lang.Object
  extended by de.lmu.ifi.dbs.elki.logging.AbstractLoggable
      extended by de.lmu.ifi.dbs.elki.database.connection.AbstractDatabaseConnection<MultiRepresentedObject<O>>
          extended by de.lmu.ifi.dbs.elki.database.connection.MultipleFileBasedDatabaseConnection<O>
Type Parameters:
O - the type of DatabaseObject to be provided by the implementing class as element of the supplied database
All Implemented Interfaces:
DatabaseConnection<MultiRepresentedObject<O>>, Parameterizable

public class MultipleFileBasedDatabaseConnection<O extends DatabaseObject>
extends AbstractDatabaseConnection<MultiRepresentedObject<O>>

Provides a database connection based on multiple files and parsers to be set.

Author:
Elke Achtert

Field Summary
static OptionID INPUT_ID
          OptionID for INPUT_PARAM
private  FileListParameter INPUT_PARAM
          Parameter that specifies the names of the input files to be parsed.
private  List<InputStream> inputStreams
          The input files to parse from as specified by INPUT_PARAM.
private  List<Parser<O>> parsers
          Holds the instances of the parsers specified by PARSERS_PARAM.
static OptionID PARSERS_ID
          OptionID for PARSERS_PARAM
private  ClassListParameter<Parser<O>> PARSERS_PARAM
          Optional parameter to specify the parsers to provide a database, must extend Parser.
 
Fields inherited from class de.lmu.ifi.dbs.elki.database.connection.AbstractDatabaseConnection
CLASS_LABEL_CLASS_ID, CLASS_LABEL_INDEX_ID, classLabelIndex, database, DATABASE_ID, EXTERNAL_ID_INDEX_ID, LABEL_CONCATENATION
 
Fields inherited from class de.lmu.ifi.dbs.elki.logging.AbstractLoggable
debug, logger
 
Constructor Summary
MultipleFileBasedDatabaseConnection(Parameterization config)
          Constructor, adhering to Parameterizable
 
Method Summary
 Database<MultiRepresentedObject<O>> getDatabase(Normalization<MultiRepresentedObject<O>> normalization)
          Returns a Database according to parameter settings.
 
Methods inherited from class de.lmu.ifi.dbs.elki.database.connection.AbstractDatabaseConnection
normalizeAndTransformLabels
 
Methods inherited from class de.lmu.ifi.dbs.elki.logging.AbstractLoggable
debugFine, debugFiner, debugFinest, exception, progress, verbose, warning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PARSERS_ID

public static final OptionID PARSERS_ID
OptionID for PARSERS_PARAM


PARSERS_PARAM

private final ClassListParameter<Parser<O extends DatabaseObject>> PARSERS_PARAM
Optional parameter to specify the parsers to provide a database, must extend Parser. If this parameter is not set, DoubleVectorLabelParser is used as parser for all input files.

Key: -multipledbc.parsers


parsers

private List<Parser<O extends DatabaseObject>> parsers
Holds the instances of the parsers specified by PARSERS_PARAM.


INPUT_ID

public static final OptionID INPUT_ID
OptionID for INPUT_PARAM


INPUT_PARAM

private final FileListParameter INPUT_PARAM
Parameter that specifies the names of the input files to be parsed.

Key: -multipledbc.in


inputStreams

private List<InputStream> inputStreams
The input files to parse from as specified by INPUT_PARAM.

Constructor Detail

MultipleFileBasedDatabaseConnection

public MultipleFileBasedDatabaseConnection(Parameterization config)
Constructor, adhering to Parameterizable

Parameters:
config - Parameterization
Method Detail

getDatabase

public Database<MultiRepresentedObject<O>> getDatabase(Normalization<MultiRepresentedObject<O>> normalization)
Description copied from interface: DatabaseConnection
Returns a Database according to parameter settings.

Parameters:
normalization - Normalization to perform a normalization if this action is supported. May remain null.
Returns:
a Database according to parameter settings

Release 0.3 (2010-03-31_1612)