Extending JRuby

Extending JRuby

In the same manner that Matz Ruby has C extensions, JRuby has Java extensions. Even though JRuby lets you use existing Java classes directly from Ruby you may still want to write a pure Java extension. This could be to have a higher performing ruby class or to make an existing Java class library more ‘ruby-esque’. My use case was to provide a seamless API for the Hitimes gem across all ruby engines. This talk will cover the facets of building Java extensions for JRuby and the burgeoning support for existing C extensions.