• linkedu视频
  • 平面设计
  • 电脑入门
  • 操作系统
  • 办公应用
  • 电脑硬件
  • 动画设计
  • 3D设计
  • 网页设计
  • CAD设计
  • 影音处理
  • 数据库
  • 程序设计
  • 认证考试
  • 信息管理
  • 信息安全
菜单
linkedu.com
  • 网页制作
  • 数据库
  • 程序设计
  • 操作系统
  • CMS教程
  • 游戏攻略
  • 脚本语言
  • 平面设计
  • 软件教程
  • 网络安全
  • 电脑知识
  • 服务器
  • 视频教程
  • vbs
  • DOS/BAT
  • hta/htc
  • python
  • perl
  • VBA
  • ColdFusion
  • ruby
  • PowerShell
  • Lua
  • Golang
  • linux shell
您的位置:首页 > 脚本语言 >ruby > Java 版的 Ruby 解释器 JRuby 1.7.14 发布

Java 版的 Ruby 解释器 JRuby 1.7.14 发布

作者:hebedich 字体:[增加 减小] 来源:互联网

hebedich 通过本文主要向大家介绍了jruby,unable to find jruby,jruby下载,jruby教程,org.jruby.main等相关知识,希望对您有所帮助,也希望大家支持linkedu.com www.linkedu.com

JRuby 1.7.14 发布 ,此版本现已提供下载:

http://www.jruby.org/download

JRuby 1.7 主要是为了兼容 Ruby 1.9.3 版本,改进记录如下:

解决了 30 个 issues

修复了 Jar 文件源潜在的内存泄漏问题

因为在 Rails 应用启动比较慢,所以默认禁用 invokedynamic

load/require 内部重构和简化

解决了一些兼容性问题

1.7.14 修复的 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

</div>

JRuby是面向Ruby、基于Java虚拟机(JVM)的一种解释程序,它结合了Ruby语言的简易性和功能强大的JVM的执行机制,包括与 Java库 全面集成。Rails彻底加快及简化了Web应用的开发,不过它让人觉得不够成熟,特别是在高端企业级功能方面。另一方面,Java平台及其虚拟机、库和 应用服务器的速度、稳定性和功能方面却一直在提升,现在已被公认为是开发高端服务器应用的领先平台。不过如果Java平台不与Ruby等新兴语言联系在一 起,就有可能落后于流行趋势。

示例代码:

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
</div>

</div>

您可能想查找下面的文章:

  • Java 版的 Ruby 解释器 JRuby 1.7.14 发布
  • Java版的Ruby解释器 JRuby简介

相关文章

  • 举例理解Ruby on Rails的页面缓存机制
  • Ruby中使用连续体Continuation实现生成器
  • Ruby实现网页图片抓取
  • 比较不错的关于ruby的电子书下载地址集合
  • 在Docker中自动化部署Ruby on Rails的教程
  • 比较详细的ruby symbol 学习资料
  • Ruby迭代器的7种技巧分享
  • Ubuntu上配置Ruby on Rails框架及RubyMine IDE开发环境
  • 关于Ruby on Rails路由配置的一些建议
  • ruby+nokogori抓取糗事百科前10页并存储进数据库示例

文章分类

  • vbs
  • DOS/BAT
  • hta/htc
  • python
  • perl
  • VBA
  • ColdFusion
  • ruby
  • PowerShell
  • Lua
  • Golang
  • linux shell

最近更新的内容

    • 使用C++来编写Ruby程序扩展的教程
    • Ruby实现的最长公共子序列算法
    • ruby元编程之method_missing的一个使用细节
    • Ruby学习笔记一
    • Ruby 魔法 学习笔记之一
    • Ruby中执行Linux shell命令的六种方法详解
    • Ruby 之 class 中的 private、 protected、public
    • Ruby中实现把字符串转换为类的2种方法
    • Ruby元编程的一些值得注意的地方
    • Ruby on Rails中MVC结构的数据传递解析

关于我们 - 联系我们 - 免责声明 - 网站地图

©2020-2025 All Rights Reserved. linkedu.com 版权所有