Application 删除 restoreConfig 方法
This commit is contained in:
@@ -741,17 +741,6 @@ public final class Application {
|
|||||||
//------------------------------------------------------------------------
|
//------------------------------------------------------------------------
|
||||||
}
|
}
|
||||||
|
|
||||||
public void restoreConfig() throws IOException {
|
|
||||||
if (!"file".equals(this.confPath.getScheme())) return;
|
|
||||||
synchronized (this) {
|
|
||||||
File confFile = new File(this.confPath.toString(), "application.xml");
|
|
||||||
confFile.renameTo(new File(this.confPath.toString(), "application_" + String.format("%1$tY%1$tm%1$td%1$tH%1$tM%1$tS", System.currentTimeMillis()) + ".xml"));
|
|
||||||
final PrintStream ps = new PrintStream(new FileOutputStream(confFile));
|
|
||||||
ps.append(config.toXML("application"));
|
|
||||||
ps.close();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private void startSelfServer() throws Exception {
|
private void startSelfServer() throws Exception {
|
||||||
final Application application = this;
|
final Application application = this;
|
||||||
new Thread() {
|
new Thread() {
|
||||||
|
|||||||
Reference in New Issue
Block a user