This project is a simple JSON editor that allows users to remove specific fields from a JSON file. The project is built using Java and Maven.
JsonEditor/
├── pom.xml
├── README.md
├── output/ (Note: This folder was created later)
├── src/
│ ├── main/
│ │ ├── java/
│ │ │ └── jsoneditor/
│ │ │ ├── JsonEditor.java
│ │ │ └── utils/
│ │ │ ├── FileUtil.java
│ │ │ └── JsonProcessor.java
│ │ ├── resources/
│ │ │ └── exampleWordList.json
│ ├── test/
│ │ └── java/
-
Build the project using Maven:
mvn clean install
-
Run the
JsonEditor
class: -
When prompted, enter the path to the JSON file (e.g.,
src/main/resources/exampleWordList.json
). -
The program will display the structure of the JSON file with numbered fields. Enter the numbers of the fields you want to remove, one by one. Type
done
when you are finished. -
The edited JSON file will be saved in the
output
directory with a timestamped filename.
Example Program Output:
Lütfen dosya yolunu girin:
src/main/resources/exampleWordList.json
1- words
2- words[].id
3- words[].ENG
4- words[].TR
Kaldırmak istediğiniz alanların numaralarını girin (bitirmek için 'done' yazın):
2
done
JSON dosyası başarıyla düzenlendi: output/json-20250304221419.json