You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

42 lines
754 B

package com.wyz.demo.dao;
import com.wyz.demo.po.UserPO;
import java.util.List;
public interface UserRepository {
// 添加用户
public void addUser(UserPO user);
/**
* 判断用户名是否存在
* 根据 username 获取用户
* @return
*/
public UserPO getUserByUsername(String username);
/**
* 根据 username 获取 用户id
* @Param username
* @return id
*/
public int getIdByUsername(String username);
/**
* 根据 用户id 获取 username
* @Param id
* @return username
*/
public String getUsernameById(int id);
// 查找用户: 根据id 获取 用户
public UserPO getUserById(int id);
}