Fixed PMD issues, added license, fixed formatting