Coercion for Jruby and java types