Interface UserRepository

All Superinterfaces:
org.springframework.data.repository.CrudRepository<User,String>, org.springframework.data.jpa.repository.JpaRepository<User,String>, org.springframework.data.repository.ListCrudRepository<User,String>, org.springframework.data.repository.ListPagingAndSortingRepository<User,String>, org.springframework.data.repository.PagingAndSortingRepository<User,String>, org.springframework.data.repository.query.QueryByExampleExecutor<User>, org.springframework.data.repository.Repository<User,String>

public interface UserRepository extends org.springframework.data.jpa.repository.JpaRepository<User,String>
Repository interface for accessing User entities. Provides methods for retrieving user data from the database.
Since:
1.0.0
Version:
1.0.0, 06/23/2025
Author:
Fernando Cruz Cavina
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    Finds a user by their email address.

    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, flush, getById, getOne, getReferenceById, saveAllAndFlush, saveAndFlush

    Methods inherited from interface org.springframework.data.repository.ListCrudRepository

    findAll, findAllById, saveAll

    Methods inherited from interface org.springframework.data.repository.ListPagingAndSortingRepository

    findAll

    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 Details

    • findByEmail

      Optional<User> findByEmail(String email)
      Finds a user by their email address.
      Parameters:
      email - the email to search for
      Returns:
      an Optional containing the user, if found