Interface ChecksumHistoryDAO

All Superinterfaces:
GenericDAO<ChecksumHistory>
All Known Implementing Classes:
ChecksumHistoryDAOImpl

public interface ChecksumHistoryDAO extends GenericDAO<ChecksumHistory>
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 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

      void deleteByBitstream(Context context, Bitstream bitstream) throws SQLException
      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