public interface DbBatchOperator<K>
Modifier and Type | Method and Description |
---|---|
int[] |
batchDelete(Bean[] beans) |
void |
batchDelete(Bean[] beans,
int batchSize) |
int[] |
batchDelete(Collection<Bean> beans) |
void |
batchDelete(Collection<Bean> beans,
int batchSize) |
Bean[] |
batchInsert(Bean[] beans) |
Bean[] |
batchInsert(Bean[] beans,
int batchSize)
可以分批次进行批处理操作
|
Bean[] |
batchInsert(Collection<Bean> beans) |
Bean[] |
batchInsert(Collection<Bean> beans,
int batchSize) |
int[] |
batchUpdate(Bean[] beans) |
void |
batchUpdate(Bean[] beans,
int batchSize) |
int[] |
batchUpdate(Collection<Bean> beans) |
void |
batchUpdate(Collection<Bean> beans,
int batchSize) |
int[] |
deleteBean(Bean[] beans) |
int[] |
deleteById(Collection<K> beanIds,
String beanType) |
int[] |
deleteById(K[] beanIds,
String beanType) |
int[] |
executeBatch(List<String> sqls)
批量执行sql语句
|
int[] |
executeBatchByList(String sql,
List<List<Object>> parameters) |
int[] |
executeBatchByList(String sql,
List<List<Object>> parameters,
int[] columnTypes) |
int[] |
executeBatchByMap(String sql,
List<Map<String,Object>> parameters) |
Bean[] |
getBeans(Bean bean) |
Bean[] |
getBeansById(Collection<K> beanIds,
String beanType) |
Bean[] |
getBeansById(K[] beanIds,
String beanTyoe) |
Bean[] |
insertBean(Bean[] beans)
处理的bean类型可以不一样,非批处理实现方式
|
int[] |
updateBean(Bean[] beans) |
Bean[] batchInsert(Bean[] beans) throws TinyDbException
TinyDbException
Bean[] batchInsert(Bean[] beans, int batchSize) throws TinyDbException
beans
- 批处理的所有记录batchSize
- 一次批处理最大数量TinyDbException
int[] batchUpdate(Bean[] beans) throws TinyDbException
TinyDbException
void batchUpdate(Bean[] beans, int batchSize) throws TinyDbException
TinyDbException
int[] batchDelete(Bean[] beans) throws TinyDbException
TinyDbException
void batchDelete(Bean[] beans, int batchSize) throws TinyDbException
TinyDbException
int[] deleteById(K[] beanIds, String beanType) throws TinyDbException
TinyDbException
Bean[] getBeansById(K[] beanIds, String beanTyoe) throws TinyDbException
TinyDbException
Bean[] getBeans(Bean bean) throws TinyDbException
TinyDbException
Bean[] batchInsert(Collection<Bean> beans) throws TinyDbException
TinyDbException
Bean[] batchInsert(Collection<Bean> beans, int batchSize) throws TinyDbException
TinyDbException
int[] batchUpdate(Collection<Bean> beans) throws TinyDbException
TinyDbException
void batchUpdate(Collection<Bean> beans, int batchSize) throws TinyDbException
TinyDbException
int[] batchDelete(Collection<Bean> beans) throws TinyDbException
TinyDbException
void batchDelete(Collection<Bean> beans, int batchSize) throws TinyDbException
TinyDbException
int[] deleteById(Collection<K> beanIds, String beanType) throws TinyDbException
TinyDbException
Bean[] getBeansById(Collection<K> beanIds, String beanType) throws TinyDbException
TinyDbException
Bean[] insertBean(Bean[] beans) throws TinyDbException
beans
- TinyDbException
int[] updateBean(Bean[] beans) throws TinyDbException
TinyDbException
int[] deleteBean(Bean[] beans) throws TinyDbException
TinyDbException
int[] executeBatch(List<String> sqls) throws TinyDbException
sqls
- TinyDbException
int[] executeBatchByList(String sql, List<List<Object>> parameters) throws TinyDbException
TinyDbException
int[] executeBatchByList(String sql, List<List<Object>> parameters, int[] columnTypes) throws TinyDbException
TinyDbException
int[] executeBatchByMap(String sql, List<Map<String,Object>> parameters) throws TinyDbException
TinyDbException
Copyright © 2006–2018 TinyGroup. All rights reserved.