Interface LanguageRepository

  • All Superinterfaces:
    org.springframework.data.repository.CrudRepository<Language,​Long>, org.springframework.data.jpa.repository.JpaRepository<Language,​Long>, org.springframework.data.repository.PagingAndSortingRepository<Language,​Long>, org.springframework.data.repository.query.QueryByExampleExecutor<Language>, org.springframework.data.repository.Repository<Language,​Long>

    @Repository
    public interface LanguageRepository
    extends org.springframework.data.jpa.repository.JpaRepository<Language,​Long>
    Class represent repository which is responsible for languages db operations
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      Set<Language> findAllByOrderByName()
      Gets all languages ordered by name
      Optional<Language> findByCode​(String code)
      Finds language by its code
      • Methods inherited from interface org.springframework.data.repository.CrudRepository

        count, delete, deleteAll, deleteAll, deleteAllById, deleteById, existsById, findById, save
      • Methods inherited from interface org.springframework.data.jpa.repository.JpaRepository

        deleteAllByIdInBatch, deleteAllInBatch, deleteAllInBatch, deleteInBatch, findAll, findAll, findAll, findAll, findAllById, flush, getById, getOne, saveAll, saveAllAndFlush, saveAndFlush
      • Methods inherited from interface org.springframework.data.repository.PagingAndSortingRepository

        findAll
      • Methods inherited from interface org.springframework.data.repository.query.QueryByExampleExecutor

        count, exists, findAll, findBy, findOne
    • Method Detail

      • findAllByOrderByName

        Set<Language> findAllByOrderByName()
        Gets all languages ordered by name
        Returns:
        all languages ordered
      • findByCode

        Optional<Language> findByCode​(String code)
        Finds language by its code
        Parameters:
        code - language code
        Returns:
        found language