public class ChecksumHistoryDAO extends DAOSupport
This is the data access for the checksum history information. All update,insert and delete database operations should go through this class for checksum history operations.
| Constructor and Description |
|---|
ChecksumHistoryDAO() |
| Modifier and Type | Method and Description |
|---|---|
protected int |
deleteHistoryByDateAndCode(Date retentionDate,
String result,
Connection conn)
Delete the history records from the database.
|
protected int |
deleteHistoryForBitstreamInfo(int id,
Connection conn)
Deletes the bitstream from the bitstream_history table if it exist.
|
void |
insertHistory(BitstreamInfo info)
Inserts results of checksum check into checksum_history table for a given
bitstream.
|
int |
prune(Map<String,Long> interests)
Prune the history records from the database.
|
protected void |
updateMissingBitstreams(Connection conn) |
cleanup, cleanup, cleanup, cleanuppublic void insertHistory(BitstreamInfo info)
info - the BitstreamInfo representing a checksum check.IllegalArgumentException - if the BitstreamInfo is null.protected int deleteHistoryForBitstreamInfo(int id,
Connection conn)
id - the bitstream id.protected void updateMissingBitstreams(Connection conn) throws SQLException
conn - SQLExceptionprotected int deleteHistoryByDateAndCode(Date retentionDate, String result, Connection conn) throws SQLException
retentionDate - any records older than this data are deleted.result - result code records must have for them to be deleted.conn - database connection.SQLException - if database error occurs.Copyright © 2014 DuraSpace. All Rights Reserved.