Interface ImportRepository<D extends com.broadleafcommerce.data.tracking.core.Identifiable>

All Superinterfaces:
org.springframework.data.repository.CrudRepository<D,String>, CustomizedImportRepository<D>, com.broadleafcommerce.common.extension.DomainTypeAware, com.broadleafcommerce.data.tracking.core.service.MappableRsqlFilterExecutor<D>, com.broadleafcommerce.common.messaging.notification.NotificationStateRepository, org.springframework.data.repository.PagingAndSortingRepository<D,String>, org.springframework.data.repository.Repository<D,String>
All Known Subinterfaces:
JpaImportRepository<D>

@NoRepositoryBean public interface ImportRepository<D extends com.broadleafcommerce.data.tracking.core.Identifiable> extends org.springframework.data.repository.PagingAndSortingRepository<D,String>, com.broadleafcommerce.data.tracking.core.service.MappableRsqlFilterExecutor<D>, CustomizedImportRepository<D>, com.broadleafcommerce.common.messaging.notification.NotificationStateRepository
Author:
Phillip Verheyden (phillipuniverse)
  • Method Details

    • findByStatusAndLastUpdatedBefore

      List<D> findByStatusAndLastUpdatedBefore(String status, Instant cutoff)
      Finds the imports whose Import.status equals the given status and whose Import.lastUpdated is before the given cutoff.
      Parameters:
      status - the results will be filtered to only include those imports whose Import.status equals this value
      cutoff - the results will be filtered to only include those imports whose Import.lastUpdated is before this value
      Returns:
      the imports which have one of the given statuses and have a Import.lastUpdated before the given cutoff
    • findByStatusAndLastUpdatedBeforeAndTenantId

      List<D> findByStatusAndLastUpdatedBeforeAndTenantId(String status, Instant cutoff, String tenantId)
      Finds the imports whose Import.status equals the given status and whose Import.lastUpdated is before the given cutoff, within the specified tenant.
      Parameters:
      status - the results will be filtered to only include those imports whose Import.status equals this value
      cutoff - the results will be filtered to only include those imports whose Import.lastUpdated is before this value
      tenantId - the tenant id that this import was initiated from
      Returns:
      the imports which have one of the given statuses and have a Import.lastUpdated before the given cutoff
    • findByAuthorAndApplicationIdAndTenantId

      @Deprecated org.springframework.data.domain.Page<D> findByAuthorAndApplicationIdAndTenantId(String author, @Nullable String applicationId, String tenantId, cz.jirutka.rsql.parser.ast.Node filters, org.springframework.data.domain.Pageable pageable)
      Finds the imports with the given Import.author, and Import.applicationId.
      Parameters:
      author - the Import.author to filter results by
      applicationId - the Import.applicationId to filter results by. Note that if this is null, only imports with null application IDs will be returned.
      tenantId - the Import.tenantId to filter results by
      filters - additional filters to apply, must not be null
      pageable - information about which page of results to return from the database
      Returns:
      the imports matching the given criteria
    • findAllByLastUpdatedBefore

      List<D> findAllByLastUpdatedBefore(Instant beforeDate)
      Read all imports whose Import.getLastUpdated() occurs before the provided time
      Parameters:
      beforeDate - the time for which to get all imports older than
      Returns:
      all imports whose Import.getLastUpdated() occurs before the provided time
    • deleteByIdIn

      Long deleteByIdIn(List<String> importIds)
      Delete the imports that match the corresponding ids
      Parameters:
      importIds - the list of import ids to delete against
      Returns:
      the number of imports deleted