Methods Summary |
---|
public void | close()Closes the database connection.
try {
// XXX test is not necessary once we assert not null in constructor
if (conn_ != null) {
conn_.commit();
// Close the connection
conn_.close();
}
} catch (SQLException e) {
if (logger.isLoggable(Logger.FINE))
logger.fine("Exception in cleanup", e); // NOI18N
}
|
public void | flush()Commits the database connection.
try {
// XXX test is not necessary once we assert not null in constructor
if (conn_ != null) {
conn_.commit();
}
} catch (SQLException e) {
if (logger.isLoggable(Logger.FINE))
logger.fine("Exception in cleanup", e); // NOI18N
}
|
public void | setConnection(java.sql.Connection conn)
conn_ = conn;
|
public void | write(int b)This method is not supported in DatabaseOutputStream because it
doesn't make sense to write a single int to a database stream. So
always throws UnsupportedOperationException.
throw new UnsupportedOperationException();
|
public void | write(java.lang.String stmt)Executes the given statement in the database.
PreparedStatement pstmt = conn_.prepareStatement(stmt);
pstmt.execute();
|