新增支持 SQLite,感谢 afumu 的贡献 #757
Add SQLite support:https://github.com/Tencent/APIJSON/pull/757
This commit is contained in:
commit
19417a4e7e
@ -1301,6 +1301,14 @@ public abstract class AbstractSQLConfig<T extends Object> implements SQLConfig<T
|
||||
return DATABASE_MQ.equals(db) || isKafka(db);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isSQLite() {
|
||||
return isSQLite(getSQLDatabase());
|
||||
}
|
||||
public static boolean isSQLite(String db) {
|
||||
return DATABASE_SQLITE.equals(db);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getQuote() {
|
||||
if(isElasticsearch()) {
|
||||
|
@ -41,6 +41,7 @@ public interface SQLConfig<T extends Object> {
|
||||
String DATABASE_MONGODB = "MONGODB"; // https://www.mongodb.com/docs/atlas/data-federation/query/query-with-sql
|
||||
String DATABASE_KAFKA = "KAFKA"; // https://github.com/APIJSON/APIJSON-Demo/tree/master/APIJSON-Java-Server/APIJSONDemo-MultiDataSource-Kafka
|
||||
String DATABASE_MQ = "MQ"; //
|
||||
String DATABASE_SQLITE = "SQLITE"; // https://www.sqlite.org
|
||||
|
||||
String SCHEMA_INFORMATION = "information_schema"; //MySQL, PostgreSQL, SQL Server 都有的系统模式
|
||||
String SCHEMA_SYS = "sys"; //SQL Server 系统模式
|
||||
@ -91,6 +92,7 @@ public interface SQLConfig<T extends Object> {
|
||||
boolean isMongoDB();
|
||||
boolean isKafka();
|
||||
boolean isMQ();
|
||||
boolean isSQLite();
|
||||
|
||||
|
||||
// 暂时只兼容以上几种
|
||||
|
Loading…
Reference in New Issue
Block a user