Interface UserRepository

  • All Superinterfaces:
    org.springframework.data.repository.CrudRepository<User,​java.lang.Long>, org.springframework.data.repository.Repository<User,​java.lang.Long>

    public interface UserRepository
    extends org.springframework.data.repository.CrudRepository<User,​java.lang.Long>
    CRUD repository connecting User model to the rest of the application
    • Method Detail

      • findByUsernameIgnoreCase

        User findByUsernameIgnoreCase​(java.lang.String username)
        Find a user by username
        Parameters:
        username -
        Returns:
        User object with the matching username
      • findByPrimaryemailIgnoreCase

        User findByPrimaryemailIgnoreCase​(java.lang.String email)
        Find a user by email address
        Parameters:
        email -
        Returns:
        User object with the matching email address
      • findByUsernameContainingIgnoreCase

        java.util.List<User> findByUsernameContainingIgnoreCase​(java.lang.String username)
        Find all users whose username contains a given case insensitive substring
        Parameters:
        username -
        Returns:
        List of users whose name contains the given substring
      • findByLastnameContainingIgnoreCase

        java.util.List<User> findByLastnameContainingIgnoreCase​(java.lang.String lastname)
        Find all users whose last name contains a given case insensitive substring
        Parameters:
        lastname -
        Returns:
        List of users whose last name contains the given substring