(String[] args)
| 18 | */ |
| 19 | public class test { |
| 20 | public static void main(String[] args) { |
| 21 | // File f = new File("/Users/f0ng/BURP/BurpUnlimited/autoDecoder/target/autoDecoder.properties"); |
| 22 | // String encodemethod = FileGetValue(f,"encodemethod").trim();; // encodemethod |
| 23 | // System.out.println(encodemethod.trim()); |
| 24 | // System.out.println("2"); |
| 25 | // System.out.println(encodemethod.trim().equals("2")); |
| 26 | // 读取reqp数组 |
| 27 | |
| 28 | String jsonStr = FileGetValue(new File( "autoDecoder.properties" ),"reqp"); |
| 29 | System.out.println(jsonStr); |
| 30 | JSONObject json = JSON.parseObject(jsonStr); |
| 31 | JSONArray reqpArray = json.getJSONArray("reqp"); |
| 32 | |
| 33 | Object[][] data11199 = new Object[reqpArray.size()][]; |
| 34 | // 遍历reqp数组中的每个对象 |
| 35 | for (int i = 0; i < reqpArray.size(); i++) { |
| 36 | JSONObject reqpObj = reqpArray.getJSONObject(i); |
| 37 | |
| 38 | // 读取每个对象的属性值 |
| 39 | String Enable = reqpObj.getString("Enable"); |
| 40 | String item = reqpObj.getString("Item"); |
| 41 | String match = reqpObj.getString("Match"); |
| 42 | String replace = reqpObj.getString("Replace"); |
| 43 | String type = reqpObj.getString("Type"); |
| 44 | String comment = reqpObj.getString("Comment"); |
| 45 | |
| 46 | data11199[i] = new Object[]{Enable,item,match,replace,type,comment}; |
| 47 | // 打印读取到的属性值 |
| 48 | System.out.println("Enable: " + Enable); |
| 49 | System.out.println("Item: " + item); |
| 50 | System.out.println("Replace: " + replace); |
| 51 | System.out.println("Comment: " + comment); |
| 52 | System.out.println("Type: " + type); |
| 53 | System.out.println("Match: " + match); |
| 54 | } |
| 55 | System.out.println(Arrays.deepToString(data11199)); |
| 56 | |
| 57 | Object[][] data1119 = { |
| 58 | {true, "Response body", "Connection: .*", "Replace 22222", "Regex", "Comment 2"}, |
| 59 | {true, "Response body", "<center><h1>30(.*)ound", "ngi</@auto>nx", "Extract", "Comment 444444"} |
| 60 | }; |
| 61 | data1119[0] = new Object[] {"aaaa"}; |
| 62 | System.out.println(Arrays.deepToString(data1119)); |
| 63 | } |
| 64 | } |
nothing calls this directly
no test coverage detected