NAME Database

This class encapsulates a Database.

This package is part of the DBMDatabase manpage. For more information on the database see the DBMDatabase::Overview.

Copyright &copy 1997 Curtis E. Dyreson. All rights reserved. Please be aware of the DBMDatabase::Licence and DBMDatabase::Version.


DESCRIPTION

The database supports only tables of persistent associative arrays, so it is a really simple database! In our implementation the database itself is a directory, and the tables within it are jdbm files. The name of the directory is passed to the Database constructor. Individual tables in the database are dbm files. See also DBMDatabase::Table and DBMDatabase::Tuple.


METHODS


new(string $databaseName)

This constructor just stores the name of the database as the directory. It does not open any files, nor check to make sure the directory exists.


createTable(string $tableName)

Creates a DBMDatabase::Table. A table is a database relation.


createNewTable(string $tableName)

Creates a new DBMDatabase::Table (will delete all entries from an existing table). A table is a database relation.


close()

Close the database making sure that the open tables have been flushed.