Getting JRuby to work in RubyMine

Posted by John Baker on Stack Overflow See other posts from Stack Overflow or by John Baker
Published on 2010-05-04T00:31:43Z Indexed on 2010/05/04 0:38 UTC
Read the original article Hit count: 647

Filed under:
|
|

I setup the proper SDK because all my ruby code will compile but RubyMine complains that it can't find the any of my java classes? Is this a flaw or is there a way to get it to recognizewhere the classes are?

Here is my code, I have underlined all the things its complaining about

require 'java'

include_class 'java.awt.event.ActionListener'
include_class 'javax.swing.JButton'
include_class 'javax.swing.JFrame'

class ClickAction
  include ActionListener

  def action_performed(event)
    puts "Button got clicked."
  end
end

Is there a way around this because I'd love to buy RubyMine if it's able to inform me of what Java classes and methods I can pick from. Thanks

© Stack Overflow or respective owner

Related posts about jruby

Related posts about ruby