Introduce gradle build

- change to java standard [directroy layout](http://maven.apache.org/guides/introduction/introduction-to-the-standard-directory-layout.html) (used by gradle and maven)
- add gradle
- minor format fixes