Package org.dspace.checker.dao
Interface ChecksumHistoryDAO
- All Superinterfaces:
GenericDAO<ChecksumHistory>
- All Known Implementing Classes:
ChecksumHistoryDAOImpl
Database Access Object interface class for the ChecksumHistory object.
The implementation of this class is responsible for all database calls for the ChecksumHistory object and is
autowired by spring
This class should only be accessed from a single service and should never be exposed outside of the API
- Author:
- kevinvandevelde at atmire.com
-
Method Summary
Modifier and TypeMethodDescriptionvoiddeleteByBitstream(Context context, Bitstream bitstream) Delete all ChecksumHistory rows for the given Bitstream.intdeleteByDateAndCode(Context context, Instant retentionDate, ChecksumResultCode checksumResultCode) Delete all ChecksumHistory rows with retention date before the given and the specified result code.
-
Method Details
-
deleteByDateAndCode
int deleteByDateAndCode(Context context, Instant retentionDate, ChecksumResultCode checksumResultCode) throws SQLException Delete all ChecksumHistory rows with retention date before the given and the specified result code.- Parameters:
context- The relevant DSpace Context.retentionDate- row must be older than this to be deleted.checksumResultCode- row must have this result to be deleted.- Returns:
- number of rows deleted.
- Throws:
SQLException- if database error
-
deleteByBitstream
Delete all ChecksumHistory rows for the given Bitstream.- Parameters:
context- The relevant DSpace Context.bitstream- which bitstream's checksums to delete- Throws:
SQLException- if database error
-