Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Example of a JRuby extension written in Java
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
spec
src/main
.gitignore
README.md
pom.xml
test.rb

README.md

Example of a JRuby extension in Java.

Build

$ mvn package

Execution

$ jruby test.rb

This script prints out the 10 first terms of the Fibonacci sequence. To use the JRuby extension:

require 'fibonacci'

seq = Com::Weblogism::Myjrubyext::Fibonacci.new
puts seq.fib(8)
Something went wrong with that request. Please try again.