FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
jruby/samples/jrubyc_java/simple_class.rb at master · java66liu/jruby · GitHub
java66liu
/
jruby
Public
forked from
jruby/jruby
Notifications
You must be signed in to change notification settings
Fork
0
Star
0
Code
Pull requests
0
Actions
Projects
Wiki
Security and quality
0
Insights
Additional navigation options
Code
Pull requests
Actions
Projects
Wiki
Security and quality
Insights
Expand file tree
Breadcrumbs
jruby
/
samples
/
jrubyc_java
/
simple_class.rb
Copy path
More file actions
More file actions
Latest commit
History
History
History
23 lines (20 loc) · 623 Bytes
Breadcrumbs
jruby
/
samples
/
jrubyc_java
/
simple_class.rb
Copy path
File metadata and controls
23 lines (20 loc) · 623 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
require
'java'
class
SimpleRubyClass
java_signature
"void simple_method()"
def
simple_method
puts
"here!"
end
end
=begin
~/projects/jruby/jrubyc_stuff ➔ jrubyc --java simple_class.rb
Compiling simple_class.rb to class simple_class
Generating Java class SimpleRubyClass to SimpleRubyClass.java
javac -cp /Users/headius/projects/jruby/lib/jruby.jar:. SimpleRubyClass.java
~/projects/jruby/jrubyc_stuff ➔ javap SimpleRubyClass
Compiled from "SimpleRubyClass.java"
public class SimpleRubyClass extends org.jruby.RubyObject{
public SimpleRubyClass();
public void simple_method();
static {};
}
=end
Back
|
FazBrowse Home
|
New Git URL