Some work on services
This commit is contained in:
parent
fc093b3ab8
commit
8532b681ca
14 changed files with 152 additions and 131 deletions
|
|
@ -8,9 +8,9 @@ import java.io.File;
|
|||
|
||||
public class WAConstants {
|
||||
|
||||
public static final String DB_FILE_NAME = "webadmin.db";
|
||||
public static final String DB_FILE = "webadmin.db";
|
||||
public static final String DB_DEFAULT_FILE = "webadmin_default.db";
|
||||
public static final String DB_TABLE_PREFIX = "wa";
|
||||
public static DBConnection db;
|
||||
|
||||
public static final String WA_ROOT_PATH_LINUX = "/";
|
||||
public static final String WA_ROOT_PATH_WINDOWS = "C:\\webadmin\\";
|
||||
|
|
@ -35,15 +35,6 @@ public class WAConstants {
|
|||
else {
|
||||
configPath = null;
|
||||
}
|
||||
|
||||
if(configPath != null){
|
||||
try {
|
||||
db = new DBConnection(DBConnection.DBMS.SQLite, configPath.getAbsolutePath() + DB_FILE_NAME);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
System.exit(1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
|
@ -51,7 +42,4 @@ public class WAConstants {
|
|||
return new File(configPath, name);
|
||||
}
|
||||
|
||||
public static DBConnection getDB(){
|
||||
return db;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue