Add java bindings

Add supporting code and tests to be able to install thrift with java bindings