Interface TermsRepository
- All Superinterfaces:
org.springframework.data.repository.CrudRepository<TermsOfService, Long>, org.springframework.data.jpa.repository.JpaRepository<TermsOfService, Long>, org.springframework.data.repository.ListCrudRepository<TermsOfService, Long>, org.springframework.data.repository.ListPagingAndSortingRepository<TermsOfService, Long>, org.springframework.data.repository.PagingAndSortingRepository<TermsOfService, Long>, org.springframework.data.repository.query.QueryByExampleExecutor<TermsOfService>, org.springframework.data.repository.Repository<TermsOfService, Long>
@Repository
public interface TermsRepository
extends org.springframework.data.jpa.repository.JpaRepository<TermsOfService, Long>
Repositório para Termos de Serviço.
Propósito: Gerenciar a persistência e recuperação de contratos legais da plataforma.
-
Method Summary
Modifier and TypeMethodDescriptionBusca o termo de serviço atualmente ativo.findByVersion(String version) Busca um termo de serviço por versão específica.Methods inherited from interface org.springframework.data.repository.CrudRepository
count, delete, deleteAll, deleteAll, deleteAllById, deleteById, existsById, findById, saveMethods inherited from interface org.springframework.data.jpa.repository.JpaRepository
deleteAllByIdInBatch, deleteAllInBatch, deleteAllInBatch, deleteInBatch, findAll, findAll, flush, getById, getOne, getReferenceById, saveAllAndFlush, saveAndFlushMethods inherited from interface org.springframework.data.repository.ListCrudRepository
findAll, findAllById, saveAllMethods inherited from interface org.springframework.data.repository.ListPagingAndSortingRepository
findAllMethods inherited from interface org.springframework.data.repository.PagingAndSortingRepository
findAllMethods inherited from interface org.springframework.data.repository.query.QueryByExampleExecutor
count, exists, findAll, findBy, findOne
-
Method Details
-
findByIsActiveTrue
Optional<TermsOfService> findByIsActiveTrue()Busca o termo de serviço atualmente ativo.- Returns:
- O termo ativo, se existir.
-
findByVersion
Busca um termo de serviço por versão específica.- Parameters:
version- A versão (ex: "v1.0").- Returns:
- O termo, se existir.
-