jruby

Jruby

Jruby

Website — http://jruby.org/

Code:

ravi.rb

require “java”

stringHello= “Raveendran in Ruby”
stringDate = java.util.Date.new

puts “#{stringHello.to_s}”
puts “Now in Java –> Date := #{stringDate.to_s}”

Run the JRuby code:

Go to command promt>jruby ravi.rb

Output:

C:\raveendran\jruby_examples>jruby ravi.rb
Raveendran in Ruby
Now in Java –> Date := Thu Sep 10 17:03:30 GMT+05:30 2009

C:\raveendran\jruby_examples>

Any issues in installation of JRuby  in windows mnachine then just post a comemnt here.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s