mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-07-21 15:09:48 +08:00
fix code
This commit is contained in:
@@ -49,7 +49,17 @@ public class SettingConfigParser implements ConfigParser {
|
||||
* @return SettingConfigParser
|
||||
*/
|
||||
public static SettingConfigParser of() {
|
||||
return new SettingConfigParser(null);
|
||||
return of(null);
|
||||
}
|
||||
|
||||
/**
|
||||
* 创建默认配置解析器
|
||||
*
|
||||
* @param setting 配置文件
|
||||
* @return SettingConfigParser
|
||||
*/
|
||||
public static SettingConfigParser of(final Setting setting) {
|
||||
return new SettingConfigParser(setting);
|
||||
}
|
||||
|
||||
private final Setting setting;
|
||||
@@ -128,7 +138,7 @@ public class SettingConfigParser implements ConfigParser {
|
||||
|
||||
// SQL日志
|
||||
final SqlLogFilter sqlLogFilter = getSqlLogFilter(setting);
|
||||
if(null != sqlLogFilter){
|
||||
if (null != sqlLogFilter) {
|
||||
dbConfig.addSqlFilter(sqlLogFilter);
|
||||
}
|
||||
|
||||
@@ -173,7 +183,7 @@ public class SettingConfigParser implements ConfigParser {
|
||||
private static SqlLogFilter getSqlLogFilter(final Setting setting) {
|
||||
// 初始化SQL显示
|
||||
final boolean isShowSql = Convert.toBoolean(setting.remove(DSKeys.KEY_SHOW_SQL), false);
|
||||
if(!isShowSql){
|
||||
if (!isShowSql) {
|
||||
return null;
|
||||
}
|
||||
|
||||
|
@@ -16,7 +16,6 @@ import org.dromara.hutool.core.io.IoUtil;
|
||||
import org.dromara.hutool.core.lang.Singleton;
|
||||
import org.dromara.hutool.core.map.MapUtil;
|
||||
import org.dromara.hutool.core.map.SafeConcurrentHashMap;
|
||||
import org.dromara.hutool.core.spi.SpiUtil;
|
||||
import org.dromara.hutool.core.text.StrUtil;
|
||||
import org.dromara.hutool.db.config.ConfigParser;
|
||||
import org.dromara.hutool.db.config.DbConfig;
|
||||
|
@@ -12,10 +12,10 @@
|
||||
|
||||
package org.dromara.hutool.db.sql;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
import org.dromara.hutool.core.text.StrUtil;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* SQL排序对象
|
||||
* @author Looly
|
||||
@@ -30,6 +30,9 @@ public class Order implements Serializable{
|
||||
private Direction direction;
|
||||
|
||||
//---------------------------------------------------------- Constructor start
|
||||
/**
|
||||
* 构造
|
||||
*/
|
||||
public Order() {
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user