Java library that processes JSON endpoints (Resource)

Sort:
NichtGut

I created a Java library that has useful methods that convert JSON data provided by the chess.com API endpoints into basic Java objects like Integers and Strings. This may prove useful to anyone that wanted to do something with the API data but wants to skip the whole JSON processing mess. 

 

For example, you can get a user´s rating in just one line of code with the library:

 

    int rating = UserJs.getBlitz("Nichtgut"); 

 

https://github.com/AntonioBohne/Chess.comJSON-JavaAPI

 

You can download all the necessary files from there. Hopefully this helps someone (that isn´t me lol). 

MGleason

Thanks!  I'm sure a lot of people will find that useful.

 

However, you've put the code online, but you haven't put any kind of open-source license on it to give people legal permission to use it in their projects.  Your thread here would presumably count as written permission for those who find this thread, but others may stumble across your code on Github.

 

What I did for PGN Spy, when I wanted to make it open source, was put a LICENSE file in the folder with the MIT license: https://github.com/MGleason1/PGN-Spy/blob/master/LICENSE

Then I put that license in a comment at the top of each code file: https://github.com/MGleason1/PGN-Spy/blob/master/PGN%20Spy/Analysis.cpp

 

I chose the MIT license because it's the least restrictive.  It allows people to do whatever they want with it, including if someone wants to use it in a proprietary application.

The GNU Public License is also popular, but code released under GPL can only be used in another project released under GPL, which means it can't be used in a proprietary application; if you want to distribute a project you need to make it open source.

There are other options, of course: https://choosealicense.com/

NichtGut

Thanks, I forgot to add one. No one respects licenses on the internet so I did not really think much about it haha. I chose GPL so my creation sons stay open source too.

MGleason

Yeah, there are a lot of people who ignore licenses online, but for those who want to do things right, it's nice to give them a way to do so.

skelos

Actually, some people (companies) who haven't respected licenses have been "persuaded" to make their code open source after being caught.

I've worked at companies who were very cautious about using open source code for that reason. I've also met people who like @NichtGut suggests don't care. sad.png

MGleason

Yes, my employer is careful about licenses.  There have occasionally been open source libraries we determined we could not use because the licensing restrictions would have forced us to choose between building a separate open source utility that would act as a wrapper for the library or else making our proprietary project open source.  Neither option was appealing, so we either developed our own in-house solution, found an alternative library, or made do without.

NichtGut

My employer also 

wait i dont have an employer sad.png