com.gitee.summer9102.develop.mysql.config.select.SelectByPrimaryKeyForUpdateMapper Maven / Gradle / Ivy
package com.gitee.summer9102.develop.mysql.config.select;
import com.gitee.summer9102.develop.mysql.config.provider.SelectCustomProvider;
import org.apache.ibatis.annotations.SelectProvider;
import tk.mybatis.mapper.annotation.RegisterMapper;
@RegisterMapper
public interface SelectByPrimaryKeyForUpdateMapper {
/**
* 根据主键字段进行查询,方法参数必须包含完整的主键属性,查询条件使用等号
* 并使用数据库的行锁
*
* @param key
* @return
*/
@SelectProvider(type = SelectCustomProvider.class, method = "dynamicSQL")
T selectByPrimaryKeyForUpdate(Object key);
}