| 程序包 | 说明 |
|---|---|
| com.github.yulichang.kt | |
| com.github.yulichang.toolkit |
| 限定符和类型 | 方法和说明 |
|---|---|
KtLambdaWrapper<T> |
KtLambdaWrapper.distinct()
sql去重
select distinct
|
KtLambdaWrapper<T> |
KtLambdaWrapper.getChildren() |
protected KtLambdaWrapper<T> |
KtLambdaWrapper.instance()
用于生成嵌套 sql
故 sqlSelect 不向下传递
|
protected KtLambdaWrapper<T> |
KtLambdaWrapper.instance(Integer index,
String keyWord,
Class<?> joinClass,
String tableName) |
protected KtLambdaWrapper<T> |
KtLambdaWrapper.instanceEmpty() |
KtLambdaWrapper<T> |
KtLambdaWrapper.select(kotlin.reflect.KProperty<?>... columns)
设置查询字段
|
KtLambdaWrapper<T> |
KtLambdaWrapper.selectAll(Class<?> clazz) |
KtLambdaWrapper<T> |
KtLambdaWrapper.selectSub(Class<?> clazz,
java.util.function.Consumer<KtLambdaWrapper<?>> consumer,
kotlin.reflect.KProperty<?> alias)
子查询
|
KtLambdaWrapper<T> |
KtLambdaWrapper.selectSub(Class<?> clazz,
String st,
java.util.function.Consumer<KtLambdaWrapper<?>> consumer,
kotlin.reflect.KProperty<?> alias)
子查询
|
<U> KtLambdaWrapper<T> |
KtLambdaWrapper.union(Class<U> clazz,
java.util.function.Consumer<KtLambdaWrapper<U>> consumer)
union
例: wrapper.union(UserDO.class, union -> union.selectAll(UserDO.class))
|
KtLambdaWrapper<T> |
KtLambdaWrapper.union(KtLambdaWrapper<?>... wrappers)
已过时。
union 不支持子查询
|
<U> KtLambdaWrapper<T> |
KtLambdaWrapper.unionAll(Class<U> clazz,
java.util.function.Consumer<KtLambdaWrapper<U>> consumer)
union
例: wrapper.unionAll(UserDO.class, union -> union.selectAll(UserDO.class))
|
KtLambdaWrapper<T> |
KtLambdaWrapper.unionAll(KtLambdaWrapper<?>... wrappers)
已过时。
union 不支持子查询
|
| 限定符和类型 | 方法和说明 |
|---|---|
KtLambdaWrapper<T> |
KtLambdaWrapper.union(KtLambdaWrapper<?>... wrappers)
已过时。
union 不支持子查询
|
KtLambdaWrapper<T> |
KtLambdaWrapper.unionAll(KtLambdaWrapper<?>... wrappers)
已过时。
union 不支持子查询
|
| 限定符和类型 | 方法和说明 |
|---|---|
KtLambdaWrapper<T> |
KtLambdaWrapper.selectSub(Class<?> clazz,
java.util.function.Consumer<KtLambdaWrapper<?>> consumer,
kotlin.reflect.KProperty<?> alias)
子查询
|
KtLambdaWrapper<T> |
KtLambdaWrapper.selectSub(Class<?> clazz,
String st,
java.util.function.Consumer<KtLambdaWrapper<?>> consumer,
kotlin.reflect.KProperty<?> alias)
子查询
|
<U> KtLambdaWrapper<T> |
KtLambdaWrapper.union(Class<U> clazz,
java.util.function.Consumer<KtLambdaWrapper<U>> consumer)
union
例: wrapper.union(UserDO.class, union -> union.selectAll(UserDO.class))
|
<U> KtLambdaWrapper<T> |
KtLambdaWrapper.unionAll(Class<U> clazz,
java.util.function.Consumer<KtLambdaWrapper<U>> consumer)
union
例: wrapper.unionAll(UserDO.class, union -> union.selectAll(UserDO.class))
|
| 限定符和类型 | 方法和说明 |
|---|---|
static <T> KtLambdaWrapper<T> |
KtWrappers.query(Class<T> clazz)
KtWrappers.kt(User.class)
|
static <T> KtLambdaWrapper<T> |
KtWrappers.query(String alias,
Class<T> clazz)
KtWrappers.kt("t", User.class)
|
static <T> KtLambdaWrapper<T> |
KtWrappers.query(String alias,
T entity)
KtWrappers.kt("t", user)
|
static <T> KtLambdaWrapper<T> |
KtWrappers.query(T entity)
KtWrappers.kt(user)
|
| 限定符和类型 | 方法和说明 |
|---|---|
static String |
KtWrapperUtils.buildSubSqlByWrapper(Class<?> clazz,
KtLambdaWrapper<?> wrapper,
String alias) |
static String |
KtWrapperUtils.buildUnionSqlByWrapper(Class<?> clazz,
KtLambdaWrapper<?> wrapper) |
Copyright © 2023. All rights reserved.