uba.db.impl.filesystem
Class FileSystemTable

java.lang.Object
  extended by uba.db.table.TableBehavior
      extended by uba.db.impl.filesystem.FileSystemTable
All Implemented Interfaces:
Table

public class FileSystemTable
extends TableBehavior

Version:
$Revision: 1.4 $

Field Summary
static java.lang.String DATA_FILE_SUFFIX
           
static java.lang.String SCHEMA_FILE_SUFFIX
           
 
Constructor Summary
protected FileSystemTable(TableSchema tableSchema, java.io.File dataFile)
           
 
Method Summary
static java.io.File createDataFile(java.io.File directory, TableSchema tableSchema)
           
static FileSystemTable createFrom(java.io.File schemaFile)
           
static FileSystemTable createNew(java.io.File directory, TableSchema tableSchema)
           
 java.io.File dataFile()
           
static java.io.File dataFileFor(java.io.File directory, TableSchema tableSchema)
           
protected  void insertRow(Row row)
          Las sub-clases deben implementar este método para insertar una fila en la tabla.
 TableReader reader()
          Retorna una instancia concreta de TableReaderpara acceder a la información de esta tabla.
 java.io.File schemaFile()
           
 
Methods inherited from class uba.db.table.TableBehavior
columnNamed, columns, indexOfColumnNamed, insert, name, numberOfColumns
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DATA_FILE_SUFFIX

public static final java.lang.String DATA_FILE_SUFFIX
See Also:
Constant Field Values

SCHEMA_FILE_SUFFIX

public static final java.lang.String SCHEMA_FILE_SUFFIX
See Also:
Constant Field Values
Constructor Detail

FileSystemTable

protected FileSystemTable(TableSchema tableSchema,
                          java.io.File dataFile)
                   throws java.io.FileNotFoundException
Throws:
java.io.FileNotFoundException
Method Detail

reader

public TableReader reader()
                   throws TableReaderCreationException
Description copied from interface: Table
Retorna una instancia concreta de TableReaderpara acceder a la información de esta tabla.

Returns:
una instancia de TableReader.
Throws:
TableReaderCreationException
See Also:
Table.reader()

insertRow

protected void insertRow(Row row)
                  throws InsertException
Description copied from class: TableBehavior
Las sub-clases deben implementar este método para insertar una fila en la tabla.

Specified by:
insertRow in class TableBehavior
Parameters:
row - fila a insertar.
Throws:
InsertException
See Also:
TableBehavior.insertRow(uba.db.table.Row)

dataFile

public java.io.File dataFile()

createNew

public static FileSystemTable createNew(java.io.File directory,
                                        TableSchema tableSchema)
                                 throws java.io.IOException
Throws:
java.io.IOException

createFrom

public static FileSystemTable createFrom(java.io.File schemaFile)
                                  throws java.io.IOException,
                                         java.lang.ClassNotFoundException
Throws:
java.io.IOException
java.lang.ClassNotFoundException

createDataFile

public static java.io.File createDataFile(java.io.File directory,
                                          TableSchema tableSchema)
                                   throws java.io.IOException
Throws:
java.io.IOException

dataFileFor

public static java.io.File dataFileFor(java.io.File directory,
                                       TableSchema tableSchema)

schemaFile

public java.io.File schemaFile()


Copyright © -2005 . All Rights Reserved.