|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Basic interface for database managers.
Method Summary | |
java.util.Map |
addRow(java.lang.String tableName,
java.util.Map ids,
java.util.Map fields)
Adds a new row. |
void |
close()
Releases a database and JDBC resources immediately instead of waiting for them to be automatically released. |
void |
deleteRow(java.lang.String tableName,
java.util.Map ids,
java.util.Map fields)
Deletes an existed record. |
void |
flush()
Flushes this database connection. |
void |
open(java.lang.String driver,
java.lang.String url,
java.lang.String user,
java.lang.String password)
Attempts to establish a connection to the given database URL. |
void |
updateRow(java.lang.String tableName,
java.util.Map ids,
java.util.Map fields)
Updates an existed record. |
Method Detail |
public java.util.Map addRow(java.lang.String tableName, java.util.Map ids, java.util.Map fields) throws DBManagerException
ids
- the list of primary keys (name/value pairs)fields
- the list of fields (name/value pairs)tableName
- the name of the tableDBManagerException
- if a database access error occurspublic void updateRow(java.lang.String tableName, java.util.Map ids, java.util.Map fields) throws DBManagerException
ids
- the list of primary keys (name/value pairs)fields
- the list of fields (name/value pairs)tableName
- the name of the tableDBManagerException
- if a database access error occurspublic void deleteRow(java.lang.String tableName, java.util.Map ids, java.util.Map fields) throws DBManagerException
ids
- the list of primary keys (name/value pairs)fields
- the list of fields (name/value pairs)tableName
- the name of the tableDBManagerException
- if a database access error occurspublic void close() throws DBManagerException
DBManagerException
- if a database access error occurspublic void open(java.lang.String driver, java.lang.String url, java.lang.String user, java.lang.String password) throws DBManagerException
driver
- the new JDBC Driverurl
- a database url of the form jdbc:subprotocol:subnameuser
- the database user on whose behalf the connection is being madepassword
- the user's passwordDBManagerException
- if a database access error occurspublic void flush() throws DBManagerException
DBManagerException
- if a database access error occurs
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright 2002 Sergey Yakovlev, All Rights Reserved.