Updated Python and Java binding.