recurser
recurser

Reputation: 105

What would this Java construct equate to in JRuby?

I'm in the process of porting some Java processing code to ruby-processing, and I'm stumped by this Java construct:

new GLTexture[]{tex2, tex4, tex8, tex16}

tex2, tex4 etc are all instances of GLTexture.

It obviously maps those arguments to the GLTexture constructor somehow, but I can't see any constructors that don't require a processing.core.PApplet instance. Google is not much help as it's quite difficult to search for punctuation []{...}.

What would the equivalent of this construct be in JRuby?

Upvotes: 0

Views: 85

Answers (1)

Mainguy
Mainguy

Reputation: 1659

In ruby, this would just be [tex2, tex4, tex8, tex16]

Upvotes: 2

Related Questions