Re: Extending BaseAdapter?

45 views
Skip to first unread message

donV

unread,
May 8, 2013, 3:02:43 AM5/8/13
to rub...@googlegroups.com
Hi Mark!

We solved this on #ruboto, but I'll explain it here for reference later.

The problem is a general JRuby problem, not Ruboto specific.  When you inherit from a Java class, JRuby must call the constructor of the Java super class.  If your "initialize" method does not include a call to "super", JRuby calls the Java super class constructor using the same arguments as your initialize method.

In your case the Java super class constructor takes no arguments, and your initialize method takes two arguments.  The problem is solved by calling "super()", with no arguments, inside your initialize method.

This was tested and works.
Reply all
Reply to author
Forward
0 new messages