Class LaunchRepositoryCustomImpl

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.Integer countLaunches​(java.lang.Long projectId, java.lang.String mode)
      Counts launches with mode for specified project
      java.lang.Integer countLaunches​(java.lang.Long projectId, java.lang.String mode, java.time.LocalDateTime from)
      Counts launches with mode for specified project from provided date
      java.util.Map<java.lang.String,​java.lang.Integer> countLaunchesGroupedByOwner​(java.lang.Long projectId, java.lang.String mode, java.time.LocalDateTime from)
      Counts quantity of launches with mode per user for specified project.
      org.springframework.data.domain.Page<Launch> findAllLatestByFilter​(Filter filter, org.springframework.data.domain.Pageable pageable)  
      java.util.List<Launch> findByFilter​(Queryable filter)
      Executes query built for given filter
      org.springframework.data.domain.Page<Launch> findByFilter​(Queryable filter, org.springframework.data.domain.Pageable pageable)
      Executes query built for given filter and maps result for given page
      java.util.Optional<Launch> findLastRun​(java.lang.Long projectId, java.lang.String mode)
      Finds the last valid launch in project
      java.util.Optional<Launch> findLatestByFilter​(Filter filter)  
      java.util.List<java.lang.Long> findLaunchIdsByProjectId​(java.lang.Long projectId)
      Finds launch ids of project with provided id
      java.util.List<java.lang.String> getLaunchNamesByModeExcludedByStatus​(java.lang.Long projectId, java.lang.String value, LaunchModeEnum mode, StatusEnum status)
      Retrieves names of the launches by provided 'projectId', 'mode', 'value' as a part of the name and statuses that are not equal to the provided 'status'
      java.util.List<java.lang.String> getOwnerNames​(java.lang.Long projectId, java.lang.String value, java.lang.String mode)  
      java.util.Map<java.lang.String,​java.lang.String> getStatuses​(java.lang.Long projectId, java.lang.Long[] ids)  
      boolean hasItemsInStatuses​(java.lang.Long launchId, java.util.List<JStatusEnum> statuses)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • LaunchRepositoryCustomImpl

        public LaunchRepositoryCustomImpl()
    • Method Detail

      • findByFilter

        public org.springframework.data.domain.Page<Launch> findByFilter​(Queryable filter,
                                                                         org.springframework.data.domain.Pageable pageable)
        Description copied from interface: FilterableRepository
        Executes query built for given filter and maps result for given page
        Specified by:
        findByFilter in interface FilterableRepository<Launch>
        Parameters:
        filter - Filter to build a query
        pageable - Pageable
        Returns:
        List of mapped entries found
      • getOwnerNames

        public java.util.List<java.lang.String> getOwnerNames​(java.lang.Long projectId,
                                                              java.lang.String value,
                                                              java.lang.String mode)
        Specified by:
        getOwnerNames in interface LaunchRepositoryCustom
      • getStatuses

        public java.util.Map<java.lang.String,​java.lang.String> getStatuses​(java.lang.Long projectId,
                                                                                  java.lang.Long[] ids)
        Specified by:
        getStatuses in interface LaunchRepositoryCustom
      • findLaunchIdsByProjectId

        public java.util.List<java.lang.Long> findLaunchIdsByProjectId​(java.lang.Long projectId)
        Description copied from interface: LaunchRepositoryCustom
        Finds launch ids of project with provided id
        Specified by:
        findLaunchIdsByProjectId in interface LaunchRepositoryCustom
        Parameters:
        projectId - - Project id
        Returns:
        List of ids
      • findLastRun

        public java.util.Optional<Launch> findLastRun​(java.lang.Long projectId,
                                                      java.lang.String mode)
        Description copied from interface: LaunchRepositoryCustom
        Finds the last valid launch in project
        Specified by:
        findLastRun in interface LaunchRepositoryCustom
        Parameters:
        projectId - Project id
        mode - Launch mode
        Returns:
        Optional of Launch
      • countLaunches

        public java.lang.Integer countLaunches​(java.lang.Long projectId,
                                               java.lang.String mode,
                                               java.time.LocalDateTime from)
        Description copied from interface: LaunchRepositoryCustom
        Counts launches with mode for specified project from provided date
        Specified by:
        countLaunches in interface LaunchRepositoryCustom
        Parameters:
        projectId - Project id
        mode - Launch mode
        from - From Date to count
        Returns:
        Launches count
      • countLaunchesGroupedByOwner

        public java.util.Map<java.lang.String,​java.lang.Integer> countLaunchesGroupedByOwner​(java.lang.Long projectId,
                                                                                                   java.lang.String mode,
                                                                                                   java.time.LocalDateTime from)
        Description copied from interface: LaunchRepositoryCustom
        Counts quantity of launches with mode per user for specified project.
        Specified by:
        countLaunchesGroupedByOwner in interface LaunchRepositoryCustom
        Parameters:
        projectId - Project id
        mode - Launch mode
        from - From Date to count
        Returns:
        Map of username and launches count