Class Hierarchy    Previous  Next  Index

Interface COM.cloudscape.database.Database


public interface Database
Copyright © 1998-2000, Informix Software, Inc. All rights reserved.

The Database interface provides control over a database (that is, the stored data and the files the data are stored in), operations on the database such as backup and recovery, and all other things that are associated with the database itself.

For examples on how to call these methods see the comments in the COM.cloudscape.database.Factory class.

Previous releases of this class included methods that threw COM.cloudscape.database.DatabaseException. This DatabaseException class has been removed and now methods throw java.sql.SQLException.

Cloudscape reserves the right to change, rename, or remove this interface at any time.

See Also:
Factory

Variable Index

 o RPD_ALIAS
 
 o RPD_BASE_CONGLOMERATE
 
 o RPD_CONSTRAINT
 
 o RPD_FILE
 
 o RPD_FOREIGN_KEY
 
 o RPD_INDEX
 
 o RPD_STATEMENT
 
 o RPD_TABLE
 
 o RPD_TARGET_DB_PROPERTY
 
 o RPD_TO_ALIAS
 
 o RPD_TO_CONSTRAINT
 
 o RPD_TO_FOREIGN_KEY
 
 o RPD_TO_INDEX
 
 o RPD_TO_MODIFY_COLUMNS
 
 o RPD_TO_STATEMENT
 
 o RPD_TO_TRIGGER
 
 o RPD_TO_VIEW
 
 o RPD_TO_WORK_UNIT
 
 o RPD_TRIGGER
 
 o RPD_UNKNOWN
 
 o RPD_VIEW
 

Method Index

 o backup(File)
Backup the database to a backup directory.
 o backup(String)
Backup the database to a backup directory.
 o checkpoint()
Checkpoints the database, that is, flushes all dirty data to disk.
 o deleteError(UUID)
Delete the error with the specified UUID from SYSERRORS.
 o deleteErrors(UUID, Timestamp)
Delete selected errors from SYSERRORS.
 o dropAllJDBCMetaDataSPSes()
Delete all stored prepared statements that were created for JDBC MetaData queries.
 o freeze()
Freeze the database temporarily so a backup can be taken.
 o getId()
Return the UUID of this database.
 o getLocale()
Get the Locale for this database.
 o isReadOnly()
Tells whether the Database is configured as read-only, or the Database was started in read-only mode.
 o unfreeze()
Unfreeze the database after a backup has been taken.

Field Detail

 o RPD_UNKNOWN
public static final int RPD_UNKNOWN
 o RPD_TABLE
public static final int RPD_TABLE
 o RPD_VIEW
public static final int RPD_VIEW
 o RPD_BASE_CONGLOMERATE
public static final int RPD_BASE_CONGLOMERATE
 o RPD_INDEX
public static final int RPD_INDEX
 o RPD_CONSTRAINT
public static final int RPD_CONSTRAINT
 o RPD_FOREIGN_KEY
public static final int RPD_FOREIGN_KEY
 o RPD_ALIAS
public static final int RPD_ALIAS
 o RPD_STATEMENT
public static final int RPD_STATEMENT
 o RPD_TARGET_DB_PROPERTY
public static final int RPD_TARGET_DB_PROPERTY
 o RPD_FILE
public static final int RPD_FILE
 o RPD_TRIGGER
public static final int RPD_TRIGGER
 o RPD_TO_ALIAS
public static final int RPD_TO_ALIAS
 o RPD_TO_WORK_UNIT
public static final int RPD_TO_WORK_UNIT
 o RPD_TO_INDEX
public static final int RPD_TO_INDEX
 o RPD_TO_MODIFY_COLUMNS
public static final int RPD_TO_MODIFY_COLUMNS
 o RPD_TO_CONSTRAINT
public static final int RPD_TO_CONSTRAINT
 o RPD_TO_FOREIGN_KEY
public static final int RPD_TO_FOREIGN_KEY
 o RPD_TO_VIEW
public static final int RPD_TO_VIEW
 o RPD_TO_STATEMENT
public static final int RPD_TO_STATEMENT
 o RPD_TO_TRIGGER
public static final int RPD_TO_TRIGGER

Method Detail

 o isReadOnly
public boolean isReadOnly()
          Tells whether the Database is configured as read-only, or the Database was started in read-only mode.
Returns:
TRUE means the Database is read-only, FALSE means it is not read-only.
 o deleteError
public boolean deleteError(UUID errorId) throws java.sql.SQLException
          Delete the error with the specified UUID from SYSERRORS.
Throws:
java.sql.SQLException - thrown if the deletion fails.
 o deleteErrors
public int deleteErrors(UUID errorDbId,
                        java.sql.Timestamp until) throws java.sql.SQLException
          Delete selected errors from SYSERRORS.
Parameters:
errorDbId - Delete errors for this database. null means delete errors for all databases.
until - Delete errors that occurred until this time. null means delete errors that occurred any time.
Throws:
java.sql.SQLException - thrown if the deletion fails.
 o dropAllJDBCMetaDataSPSes
public void dropAllJDBCMetaDataSPSes() throws java.sql.SQLException
          Delete all stored prepared statements that were created for JDBC MetaData queries.
Throws:
java.sql.SQLException - thrown on error deleting the stored prepared statements, most likely a deadlock or timeout.
 o backup
public void backup(java.lang.String backupDir) throws java.sql.SQLException
          Backup the database to a backup directory. See on line documentation for more detail about how to use this feature.
Parameters:
backupDir - the directory name where the database backup should go. This directory will be created if not it does not exist.
Throws:
java.sql.SQLException - Thrown on error
 o backup
public void backup(java.io.File backupDir) throws java.sql.SQLException
          Backup the database to a backup directory. See on line documentation for more detail about how to use this feature.
Parameters:
backupDir - the directory where the database backup should go. This directory will be created if not it does not exist.
Throws:
java.sql.SQLException - Thrown on error
 o freeze
public void freeze() throws java.sql.SQLException
          Freeze the database temporarily so a backup can be taken.

Please see cloudscape on line documentation on backup and restore.

Throws:
java.sql.SQLException - Thrown on error
 o unfreeze
public void unfreeze() throws java.sql.SQLException
          Unfreeze the database after a backup has been taken.

Please see cloudscape on line documentation on backup and restore.

Throws:
java.sql.SQLException - Thrown on error
 o checkpoint
public void checkpoint() throws java.sql.SQLException
          Checkpoints the database, that is, flushes all dirty data to disk. Records a checkpoint in the transaction log, if there is a log.
Returns:
Nothing
Throws:
java.sql.SQLException - Thrown on error
 o getLocale
public java.util.Locale getLocale()
          Get the Locale for this database. This method may return null for target databases that have not been refreshed since they were upgraded to version 3.5.
 o getId
public UUID getId()
          Return the UUID of this database.

  Class Hierarchy    Previous  Next  Index