Skip to main content
1 vote
1 answer
157 views

I'm converting a project written with JRuby 1.7 in mind to JRuby 9.4. One of the files starts like this: if RUBY_PLATFORM == 'java' require 'java' import java.lang.management.ManagementFactory ...
user1934428's user avatar
  • 22.9k
2 votes
1 answer
341 views

Recently I've cobbled together a small project to play with JRuby and its interactions with Java. Here's the Github gist. LogicProcessor.java: package me.artsolopov.jrp; import javax.swing.*; import ...
art-solopov's user avatar
  • 4,802
2 votes
1 answer
344 views

Working on a legacy JRuby app (1.6.8) running under Java 11, I traced a peculiar error a test case: "require 'java'; puts java::util::regex::Pattern.class" errors ArgumentError: wrong number of ...
SRobertJames's user avatar
  • 9,437
7 votes
1 answer
401 views

It so happened that I need to unit-test this Ruby script. It's a Sinatra-based web application that uses several gems. I have more experience in Java than in Ruby, time is very important (and ...
Glory to Russia's user avatar
0 votes
2 answers
98 views

I'm doing a fuzzy match test between an input string and some previously entered strings. The test is performed live while typing. I already have a shockingly accurate algorithm in place called ...
Cjoerg's user avatar
  • 1,335
7 votes
0 answers
207 views

(Crossposting note: This question has also been posted at the JRuby mailing list ([email protected]) on December 20 and on JRuby Forum on January 2nd, but hasn't got any response yet). This ...
user1934428's user avatar
  • 22.9k
0 votes
1 answer
419 views

(Crossposted at JRuby Forum, but posted here again because I did not get any answer yet). Platform: jruby 9.0.4.0 (2.2.2) 2015-11-12 b9fb7aa Java HotSpot(TM) 64-Bit Server VM 24.79-b02 on 1.7.0_79-...
user1934428's user avatar
  • 22.9k
1 vote
1 answer
1k views

I'm trying to access the following static enum public class Colors { public enum ListofColors { BLUE, RED, YELLOW } } But I keep getting the error NameError: cannot load Java ...
hello_its_me's user avatar
0 votes
1 answer
200 views

My question is related to closure conversion. I want to test a proc that implements a functional interface from jruby code. I have a simple proc like proc { print 'hey!' } to implement a java ...
Samuel García's user avatar
3 votes
2 answers
164 views

I'm trying to implement a Java extension for JRuby to perform string xors. I'm just uncertain how to type cast a byte array into a RubyString: public static RubyString xor(ThreadContext context, ...
fny's user avatar
  • 34k
1 vote
2 answers
2k views

Is that feature still supported? I can't seem to find any Documentation past 2008 or so. This is an insert from the Oracle website... At runtime, the JSR 223 Scripting APIs must locate the ...
Buildersrejected's user avatar
0 votes
1 answer
793 views

I have a large Java project that uses some Ruby scripts (primarily because of Ruby's support for "yield"). The Ruby code calls Java code which calls more Ruby code. It's very interleaved, but ...
Jon O's user avatar
  • 6,591
2 votes
1 answer
836 views

Someone on my team is writing a ruby/cucumber test that calls a java api that takes a List<Long> argument. I'm trying to help him out but my jruby knowledge is pretty limited. Whenever the ...
k s's user avatar
  • 882
1 vote
0 answers
60 views

Is there anyone know the implementation of exec by JRuby implementation. I have two simple rubys scripts: Test.rb calls another called.rb via exec, as below: //Test.rb #!/usr/bin/env jruby sleep ...
shijie xu's user avatar
  • 2,107
0 votes
2 answers
117 views

I have a file with n number of lines. I need to search for a field(SessionId and its value) in it and print its corresponding value. I have coded to access the file and print it line by line. Need ...
karthick23's user avatar
  • 1,341

15 30 50 per page