public abstract class AbstractInsertLambda<R,T,P> extends BasicLambda<R,T,P> implements InsertExecute<R,T>
| 限定符和类型 | 字段和说明 |
|---|---|
protected List<String> |
insertColumns |
protected List<ColumnMapping> |
insertProperties |
protected DuplicateKeyStrategy |
insertStrategy |
protected List<Object[]> |
insertValues |
protected List<ColumnMapping> |
primaryKeyProperties |
protected List<String> |
primaryKeys |
dbType| 构造器和说明 |
|---|
AbstractInsertLambda(Class<?> exampleType,
TableMapping<?> tableMapping,
LambdaTemplate jdbcTemplate) |
| 限定符和类型 | 方法和说明 |
|---|---|
R |
applyEntity(List<T> entityList)
批量插入记录
|
R |
applyMap(List<Map<String,Object>> entityList)
批量插入记录
|
protected BatchBoundSql |
buildBatchBoundSql(String batchSql) |
protected BoundSql |
buildBoundSql(SqlDialect dialect) |
protected String |
defaultDialectInsert(boolean useQualifier,
String schema,
String table,
List<String> columns,
SqlDialect dialect) |
protected BoundSql |
dialectInsert(SqlDialect dialect) |
int[] |
executeGetResult()
执行插入,并返回所有结果
|
protected List<ColumnMapping> |
getInsertProperties() |
protected List<ColumnMapping> |
getPrimaryKeyColumns() |
R |
onDuplicateStrategy(DuplicateKeyStrategy insertStrategy)
insert 策略,默认策略是
DuplicateKeyStrategy.Into |
buildColumnByLambda, buildColumnByProperty, dialect, exampleIsMap, exampleType, getBoundSql, getBoundSql, getJdbcTemplate, getPropertyName, getSelf, getTableMapping, isQualifier, setDialect, useQualifierclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitapplyEntity, applyMap, executeSumResultgetBoundSql, getBoundSqlprotected final List<ColumnMapping> insertProperties
protected final List<ColumnMapping> primaryKeyProperties
protected DuplicateKeyStrategy insertStrategy
public AbstractInsertLambda(Class<?> exampleType, TableMapping<?> tableMapping, LambdaTemplate jdbcTemplate)
protected List<ColumnMapping> getInsertProperties()
protected List<ColumnMapping> getPrimaryKeyColumns()
public R onDuplicateStrategy(DuplicateKeyStrategy insertStrategy)
InsertExecuteDuplicateKeyStrategy.IntoonDuplicateStrategy 在接口中 InsertExecute<R,T>public R applyEntity(List<T> entityList)
InsertExecuteapplyEntity 在接口中 InsertExecute<R,T>public R applyMap(List<Map<String,Object>> entityList)
InsertExecuteapplyMap 在接口中 InsertExecute<R,T>public int[] executeGetResult()
throws SQLException
InsertExecuteexecuteGetResult 在接口中 InsertExecute<R,T>SQLExceptionprotected BoundSql buildBoundSql(SqlDialect dialect)
buildBoundSql 在类中 BasicLambda<R,T,P>protected BoundSql dialectInsert(SqlDialect dialect)
protected BatchBoundSql buildBatchBoundSql(String batchSql)
Copyright © 2021–2022. All rights reserved.