Forum: JRuby instanciating a java.util.Set

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
71c85a662af0764df3a77cc00db166c9?d=identicon&s=25 Raphael Bauduin (Guest)
on 2008-10-06 18:29
(Received via mailing list)
Hi,

I'm using a Java library from Jruby, and I need to pass a
java.util.Set as an argument to a method. But how can construct such a
set?
I'm not even sure which implementation of this interface I should
choose.
I saw org.jruby.RubyArray implements this interface. Is that the way to
go?

Thanks

Raphaƫl

--
Web database: http://www.myowndb.com
Free Software Developers Meeting: http://www.fosdem.org

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email
Ede2aa10c6462f1d825143879be59e38?d=identicon&s=25 Charles Oliver Nutter (Guest)
on 2008-10-06 19:49
(Received via mailing list)
Raphael Bauduin wrote:
> Hi,
>
> I'm using a Java library from Jruby, and I need to pass a
> java.util.Set as an argument to a method. But how can construct such a
> set?
> I'm not even sure which implementation of this interface I should choose.
> I saw org.jruby.RubyArray implements this interface. Is that the way to go?

Why not just use Java's Set implementations?

java.util.HashSet.new

- Charlie

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email
71c85a662af0764df3a77cc00db166c9?d=identicon&s=25 Raphael Bauduin (Guest)
on 2008-10-06 20:04
(Received via mailing list)
On Mon, Oct 6, 2008 at 7:28 PM, Charles Oliver Nutter
<charles.nutter@sun.com> wrote:
>
> Why not just use Java's Set implementations?
>
> java.util.HashSet.new

It works fine. Thanks!

Raph

>
> - Charlie
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>   http://xircles.codehaus.org/manage_email
>
>
>



--
Web database: http://www.myowndb.com
Free Software Developers Meeting: http://www.fosdem.org

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email
This topic is locked and can not be replied to.