最新国产好看的视频,伊人天堂AV在线,国产Aaaaaa视频,蜜臀视频在线观看一区,人妻av色图,密臀久久久精品影片,青青视频免费观看毛片,久草在线观看视,国产三级精品色情在线

Java 版的 Ruby 解釋器 JRuby 1.7.14 發(fā)布

 更新時間:2014年08月29日 15:33:17   投稿:hebedich  
JRuby,一個采用純Java實現(xiàn)的Ruby解釋器,由JRuby團隊開發(fā)。它是一個自由軟件,在CPL/GPL/LGPL三種許可協(xié)議下發(fā)布。

JRuby 1.7.14 發(fā)布 ,此版本現(xiàn)已提供下載:

http://www.jruby.org/download

JRuby 1.7 主要是為了兼容 Ruby 1.9.3 版本,改進記錄如下:

解決了 30 個 issues

修復(fù)了 Jar 文件源潛在的內(nèi)存泄漏問題

因為在 Rails 應(yīng)用啟動比較慢,所以默認禁用 invokedynamic

load/require 內(nèi)部重構(gòu)和簡化

解決了一些兼容性問題

1.7.14 修復(fù)的 bug:

#1923 - String#start_with? returns false when using an empty string
#1905 - Tempfile and deleteOnExit
#1899 - Can't call static method on Java 8 interface
#1898 - Fix the memory leak and actually close the resources.
#1889 - NPE from org.jruby.java.proxies.ArrayJavaProxy.to_a
#1888 - native memory leak when reading files from inside a .jar
#1859 - JMX tries to double-bind a port when using bundle exec
#1858 - JRuby with Java 8 4 to 10 times slower than Java 7
#1852 - JRubyClassloader seems to have a problem with file urls pointing to jar ...
#1850 - embedded jars do not get loaded
#1846 - Fix $LOAD_FEATURES paths for 1.8
#1818 - fix ArrayJavaProxy#to_a failure on arrays containing null
#1813 - can not load resources from jar anymore with jar uri
#1809 - apply minor enebo's comments
#1808 - Fix BigDecimal#round behavior with NAN and INFINITY
#1805 - Zlib crc improvements
#1803 - Fix minor bug in `setNativeEnabled`, and expose it in ScriptingContainer
#1802 - Fix Encoding::Converter#inspect output
#1799 - mvn -Pall fails at the documentation step
#1790 - Make Time#to_r consistent with MRI
#1777 - ServerSocket#accept_nonblock returns the server's port, not the client's
#1772 - avoid sub-classing ThreadLocal since it will leak in envs such as .wars
#1765 - added a java_field method for use in the jrubyc command.
#1762 - enhanced the java_class compiler so it can handle multiple constructors
#1750 - Refactor LoadService to make use of resources
#1729 - no valid struct layout for Ethon::Curl::Slist
#1676 - Empty hash optimization
#1580 - IO.select raises CancelledKeyException on shutdown
#1520 - Date comparison as java objects
#1435 - bouncy-castle-java JARs missing when warbling with JRuby 1.7.10

JRuby是面向Ruby、基于Java虛擬機(JVM)的一種解釋程序,它結(jié)合了Ruby語言的簡易性和功能強大的JVM的執(zhí)行機制,包括與 Java庫 全面集成。Rails徹底加快及簡化了Web應(yīng)用的開發(fā),不過它讓人覺得不夠成熟,特別是在高端企業(yè)級功能方面。另一方面,Java平臺及其虛擬機、庫和 應(yīng)用服務(wù)器的速度、穩(wěn)定性和功能方面卻一直在提升,現(xiàn)在已被公認為是開發(fā)高端服務(wù)器應(yīng)用的領(lǐng)先平臺。不過如果Java平臺不與Ruby等新興語言聯(lián)系在一 起,就有可能落后于流行趨勢。

示例代碼:

require "java"
include_class "java.util.TreeSet"
include_class "com.example.CallMe"
include_class "com.example.ISpeaker"
puts "Hello from ruby"
set = TreeSet.new
set.add "foo"
set.add "Bar"
set.add "baz"
set.each { |v| puts "value: #{v}" }
cm = CallMe.new
cm.hello
$globalCM.hello
class CallJava
include ISpeaker
def initialize
 super
 @count = 0
end
def say(msg)
 puts "Ruby saying #{msg}"
end
def addOne(from)
#  m.synchronize {
  @count += 1
  puts "Now got #@count from #{from}"
#  }
end
end

相關(guān)文章

最新評論

霞浦县| 黔江区| 双江| 辽宁省| 安塞县| 咸阳市| 安塞县| 沁阳市| 梅州市| 黄梅县| 德江县| 涟水县| 惠东县| 历史| 高雄县| 绵竹市| 太谷县| 绥宁县| 五大连池市| 巴彦县| 巢湖市| 黑水县| 平顺县| 长汀县| 宜兴市| SHOW| 曲阜市| 凤山市| 昌江| 沁水县| 察隅县| 大兴区| 托克逊县| 巴彦淖尔市| 溧阳市| 牙克石市| 静乐县| 贞丰县| 鹿邑县| 安康市| 望谟县|