Interface QAEventsDAO

All Superinterfaces:
GenericDAO<QAEventProcessed>
All Known Implementing Classes:
QAEventsDAOImpl

public interface QAEventsDAO extends GenericDAO<QAEventProcessed>
DAO that handle processed QA Events.
Author:
Andrea Bollini (andrea.bollini at 4science.it)
  • Method Details

    • findAll

      List<QAEventProcessed> findAll(Context context) throws SQLException
      Returns all the stored QAEventProcessed entities.
      Parameters:
      context - the DSpace context
      Returns:
      the found entities
      Throws:
      SQLException - if an SQL error occurs
    • findByItem

      List<QAEventProcessed> findByItem(Context context, Item item) throws SQLException
      Returns the stored QAEventProcessed entities by item.
      Parameters:
      context - the DSpace context
      item - the item to search for
      Returns:
      the found entities
      Throws:
      SQLException - if an SQL error occurs
    • findByEPerson

      List<QAEventProcessed> findByEPerson(Context context, EPerson ePerson) throws SQLException
      Returns the stored QAEventProcessed entities by eperson.
      Parameters:
      context - the DSpace context
      ePerson - the ePerson to search for
      Returns:
      the found entities
      Throws:
      SQLException - if an SQL error occurs
    • searchByEventId

      List<QAEventProcessed> searchByEventId(Context context, String eventId, Integer start, Integer size) throws SQLException
      Search a page of quality assurance broker events by notification ID.
      Parameters:
      context - the DSpace context
      eventId - the event id
      start - the start index
      size - the size to be applied
      Returns:
      the processed events
      Throws:
      SQLException - if an SQL error occurs
    • isEventStored

      boolean isEventStored(Context context, String checksum) throws SQLException
      Check if an event with the given checksum is already stored.
      Parameters:
      context - the DSpace context
      checksum - the checksum to search for
      Returns:
      true if the given checksum is related to an already stored event, false otherwise
      Throws:
      SQLException - if an SQL error occurs
    • storeEvent

      boolean storeEvent(Context context, String checksum, EPerson eperson, Item item)
      Store an event related to the given checksum.
      Parameters:
      context - the DSpace context
      checksum - the checksum of the event to be store
      eperson - the eperson who handle the event
      item - the item related to the event
      Returns:
      true if the creation is completed with success, false otherwise