Esempio n. 1
0
 private static void parseSave(ConfigUpdater o) throws IOException {
   if (_path != null) {
     File file = new File(_path);
     if (!file.isDirectory() && file.canWrite()) {
       FileWriter fr = new FileWriter(file);
       ProxyFilter.saveConfig(fr);
       o.sendSave("Saved current config to " + _path + " successfully");
       fr.close();
     } else {
       throw new IOException("Bad config file specified");
     }
   } else {
     throw new IOException("File path not specified");
   }
 }