yangys
2024-03-30 871c0fce344b24c8046ec01173eca79b9e60c1d7
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
package com.qianwen.core.mp.service;
 
import java.util.Collection;
import com.qianwen.core.mp.base.BaseService;
import org.springframework.transaction.annotation.Transactional;
 
/* loaded from: blade-starter-mybatis-9.3.0.0-SNAPSHOT.jar:org/springblade/core/mp/service/BladeService.class */
public interface BladeService<T> extends BaseService<T> {
    boolean saveIgnore(T entity);
 
    boolean saveReplace(T entity);
 
    boolean saveIgnoreBatch(Collection<T> entityList, int batchSize);
 
    boolean saveReplaceBatch(Collection<T> entityList, int batchSize);
 
    @Transactional(rollbackFor = {Exception.class})
    default boolean saveIgnoreBatch(Collection<T> entityList) {
        return saveIgnoreBatch(entityList, 1000);
    }
 
    @Transactional(rollbackFor = {Exception.class})
    default boolean saveReplaceBatch(Collection<T> entityList) {
        return saveReplaceBatch(entityList, 1000);
    }
}