Module: Kernel

Defined in:
core/src/main/ruby/jruby/java/core_ext/kernel.rb

Overview

Note:

These methods are undef-ed within Java package stubs (in case of com.foo.com).

Convenience methods for top-level packages without the need to prefix e.g. `Java::java.util.ArrayList`.

Instance Method Summary (collapse)

Instance Method Details

- (Object) com

Java package short-cut method.

Examples:

com.google.common.base.Strings


27
28
29
# File 'core/src/main/ruby/jruby/java/core_ext/kernel.rb', line 27

def com
  JavaUtilities.get_package_module_dot_format('com') # stub
end

- (Object) java

Java package short-cut method.

Examples:

java.lang.System


9
10
11
# File 'core/src/main/ruby/jruby/java/core_ext/kernel.rb', line 9

def java
  JavaUtilities.get_package_module_dot_format('java') # stub
end

- (Object) javafx

Java package short-cut method.

Examples:

javafx.application.Platform


21
22
23
# File 'core/src/main/ruby/jruby/java/core_ext/kernel.rb', line 21

def javafx
  JavaUtilities.get_package_module_dot_format('javafx') # stub
end

- (Object) javax

Java package short-cut method.

Examples:

javax.swing.SwingUtilities


15
16
17
# File 'core/src/main/ruby/jruby/java/core_ext/kernel.rb', line 15

def javax
  JavaUtilities.get_package_module_dot_format('javax') # stub
end

- (Object) org

Java package short-cut method.

Examples:

org.json.JSONArray


33
34
35
# File 'core/src/main/ruby/jruby/java/core_ext/kernel.rb', line 33

def org
  JavaUtilities.get_package_module_dot_format('org') # stub
end