T - public interface BaseService<T>
extends com.baomidou.mybatisplus.extension.service.IService<T>
| 限定符和类型 | 方法和说明 |
|---|---|
T |
alwaysGetById(Serializable id)
根据 ID 查询
|
List<T> |
alwaysListBatchIds(Collection<? extends Serializable> idList)
查询(根据ID 批量查询)
|
Long |
alwaysSelectCount(com.baomidou.mybatisplus.core.conditions.Wrapper<T> queryWrapper)
根据 Wrapper 条件,查询总记录数
|
List<T> |
alwaysSelectList(com.baomidou.mybatisplus.core.conditions.Wrapper<T> queryWrapper)
根据 entity 条件,查询全部记录
|
default T |
alwaysSelectOne(com.baomidou.mybatisplus.core.conditions.Wrapper<T> queryWrapper)
根据 entity 条件,查询一条记录
|
T |
alwaysSelectOne(com.baomidou.mybatisplus.core.conditions.Wrapper<T> queryWrapper,
boolean throwEx)
根据 entity 条件,查询一条记录
|
boolean |
alwaysUpdate(com.baomidou.mybatisplus.core.conditions.Wrapper<T> updateWrapper)
根据 whereEntity 条件,更新记录(但是不包含逻辑删除)
|
boolean |
alwaysUpdateSomeColumnById(T entity)
根据 ID 更新固定的那几个字段(但是不包含逻辑删除)
|
count, count, getBaseMapper, getById, getEntityClass, getMap, getObj, getOne, getOne, ktQuery, ktUpdate, lambdaQuery, lambdaQuery, lambdaUpdate, list, list, listByIds, listByMap, listMaps, listMaps, listObjs, listObjs, listObjs, listObjs, page, page, pageMaps, pageMaps, query, remove, removeBatchByIds, removeBatchByIds, removeBatchByIds, removeBatchByIds, removeById, removeById, removeById, removeByIds, removeByIds, removeByMap, save, saveBatch, saveBatch, saveOrUpdate, saveOrUpdate, saveOrUpdateBatch, saveOrUpdateBatch, update, update, update, updateBatchById, updateBatchById, updateByIdboolean alwaysUpdateSomeColumnById(T entity)
entity - 实体boolean alwaysUpdate(com.baomidou.mybatisplus.core.conditions.Wrapper<T> updateWrapper)
updateWrapper - 实体对象封装操作类(可以为 null,里面的 entity 用于生成 where 语句)T alwaysGetById(Serializable id)
id - 主键IDList<T> alwaysListBatchIds(Collection<? extends Serializable> idList)
idList - 主键ID列表(不能为 null 以及 empty)default T alwaysSelectOne(com.baomidou.mybatisplus.core.conditions.Wrapper<T> queryWrapper)
queryWrapper - 实体对象封装操作类(可以为 null)T alwaysSelectOne(@Param(value="ew") com.baomidou.mybatisplus.core.conditions.Wrapper<T> queryWrapper, boolean throwEx)
queryWrapper - 实体对象封装操作类(可以为 null)throwEx - true抛异常 false不抛Long alwaysSelectCount(@Param(value="ew") com.baomidou.mybatisplus.core.conditions.Wrapper<T> queryWrapper)
queryWrapper - 实体对象封装操作类(可以为 null)Copyright © 2023. All rights reserved.