All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.infusers.core.user.UserRepository Maven / Gradle / Ivy

package com.infusers.core.user;

import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.domain.Specification;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;

public interface UserRepository extends JpaRepository , JpaSpecificationExecutor{
		
  Page findById(Long id, Pageable pageable);
  Page findByIdAndUsername(Long id, String username, Pageable pageable);
  Page findByUsername(String username, Pageable pageable);
  APIUser findByUsername(String username);

  Page findAll(Specification spec, Pageable pageable);
  Page findAllByUsername(String username, Specification spec, Pageable pageable);	  
  
//  @Query("SELECT u FROM APIUser u WHERE u.username = :username")
//  public APIUser findByUsername(@Param("username") String username);
  
  @Query("SELECT u FROM APIUser u WHERE u.verificationCode = ?1")
  public APIUser findByVerificationCode(String code);  
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy