Rebuild code and add default filter.
This commit is contained in:
22
burp/file/RemoveContent.java
Normal file
22
burp/file/RemoveContent.java
Normal file
@@ -0,0 +1,22 @@
|
||||
package burp.file;
|
||||
|
||||
import javax.swing.JOptionPane;
|
||||
|
||||
import org.json.JSONObject;
|
||||
|
||||
public class RemoveContent {
|
||||
WriteFile w = new WriteFile();
|
||||
ReadFile r = new ReadFile();
|
||||
/*
|
||||
* 删除某文件内容
|
||||
*/
|
||||
public void removeFileContent(String key, String configFilePath) {
|
||||
String jsonStr = r.readFileContent(configFilePath);
|
||||
JSONObject jsonObj = new JSONObject(jsonStr);
|
||||
jsonObj.remove(key);
|
||||
|
||||
if (w.writeFileContent(configFilePath, jsonObj.toString())) {
|
||||
JOptionPane.showMessageDialog(null, "Delete Successfully!", "Info", JOptionPane.INFORMATION_MESSAGE);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user