Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/akayibrahim/jsontopojo
Auto creating POJO from JSON.
https://github.com/akayibrahim/jsontopojo
generator json json-schema maven maven-plugin
Last synced: about 4 hours ago
JSON representation
Auto creating POJO from JSON.
- Host: GitHub
- URL: https://github.com/akayibrahim/jsontopojo
- Owner: akayibrahim
- Created: 2019-12-07T21:24:48.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2022-05-20T21:18:27.000Z (over 2 years ago)
- Last Synced: 2023-08-11T07:45:41.299Z (about 1 year ago)
- Topics: generator, json, json-schema, maven, maven-plugin
- Language: Java
- Homepage:
- Size: 121 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# JSON TO POJO Maven Plugin
#### This Maven Plugin is for creating POJO's automatically from json.
##### Follow steps:
1. Add below build tag to pom.xml of your project
```xml
io.github.akayibrahim
jsontopojo
1.5
{
"employee": {
"name": "sonoo",
"salary": 56000,
"married": true
}
}
io.githup.akayibrahim.testing
EmployeeTesting
true
Pre
Post
false
create
```
2. Run mvn clean install. Once the build is complete, navigate to the project root folder and you should see POJO's file.Maven Repo Link => https://repo.maven.apache.org/maven2/io/github/akayibrahim/
NOTE : All data in json should not be null or empty. Tool generate TODO comment for null fields, so you can fix it. Please search TODO comment after generate POJO's.
NOTE : For using lombok, you have to add lombok dependency to your pom.xml.
```xml
org.projectlombok
lombok
1.18.10
```
NOTE 2 : For using jackson, you have to add jackson dependency to your pom.xml. it is necessary for "throwForDuplicateObjectName" key.
```xml
com.fasterxml.jackson.core
jackson-annotations
2.10.1
```
Thanks to https://github.com/giordamauro/json-to-pojo/