A JSON class generator.
Requires php cli 5.3 or higher.
Usage:
php generator.php <file|url> <template Java|Php|Csharp> <initial classname> <outputdir>
If you, like me, enjoy strongly typed classes when working with JSON.
This little utility will generate the boilerplate code for you, from a JSON file or URL.
It's not perfect, but it will get you 95% of the way 95% of the time ;)
Currently supported language templates:
- Java
- PHP
- C#
Custom templates are easy to make. Just have a look at one of the template scripts, and customize it or create a new one.
If you do create a new template, or simply have suggestions for a better standard template, then go ahead and make a pull request, and I'll throw it in there :)
Enjoy.