天天看點

在JVM上運作的五大腳本語言(Top five scripting languages on the JVM)

        遵循軟體開發工具,在過去十年中的任何人都知道,長期的“Java”指的是一雙的技術:Java程式設計語言和Java虛拟機(JVM)。Java語言被編譯成位元組碼在JVM上運作。通過這種設計,JAVA提供可移植性。

        然而,語言和JVM,已越來越多地在相反的方向移動。語言已變得越來越複雜,而JVM已經成為最快和最有效的執行平台之一。Java的許多基準,等于如編譯語言生成的二進制代碼的性能C和C + +的。日益複雜的語言和卓越的性能,可移植性和可擴充性的JVM已經建立了一個開放的新一代程式設計語言。這些語言缺乏Java的文法超載(通常稱為“儀式”輕蔑) - 也就是多餘的代碼量做實際工作的代碼前,需要手搖的,可以書面 - 但利用JVM的。

        [PDT的Eclipse,NetBeans中,NuSphere PhpED的,和Zend Studio導緻Web開發的一個IDE的能力領域。見“ InfoWorld的審查:8個PHP的電動工具 “|有了所見即所得的原型環境和預先設定的圖形元件,快速Web開發工具可以幫助你更快地建構應用程式-但缺乏靈活性。見“InfoWorld的審查:用于快速Web開發工具 “]

        在這篇文章中,我研究這些語言的少數,比較和對比,并确定他們滿足特别的需求。我自己是自由和開放源碼JVM語言限制。令人驚訝的是,閉源的商業世界,有幾相媲美的産品。一個突出的是冷聚變标記語言,這是Adobe的冷聚變的Web應用程式開發環境的一部分。

        技師上存在分歧,究竟是一種腳本語言。在其最窄的定義,它是一種語言,使開發人員編寫的快速方案。這些方案一般解釋或半編譯的,而不是在傳統的方式編制。這項檢讨在選擇的語言,我用了一個更廣泛的定義,這是任何JVM語言簡單,比Java代碼。一些編譯,其他半編譯的,但都是适合快速發展。我把重點放在語言是用Groovy,JRuby,FANTOM,Jython中,和Scala。還有其他幾個候選人,Clojure的分别是,JavaFX的NetRexx,我簡要地覆寫在年底。

        今天JVM的腳本語言,自然分成兩組,基于他們的采用率。Groovy和JRuby落入流行的陣營,而​​其他有特殊的球員 - 也就是說,他們呼籲,目前一個小社會。這一點很重要,但要注意,Groovy和JRuby也特殊的球員,兩年前,是以沒有理由相信利基語言是永久降級的邊緣。我認為出現的可能性,有利于斯卡拉,然後FANTOM,最後的Jython。正如我解釋後,我覺得Jython的時刻已經在陽光下可能來來去去。

JVM腳本語言第1号:Groovy的-強大的,高層次的,企業的友好

JVM腳本語言第2号:JRuby的​​-比Ruby更好的Ruby?

JVM腳本語言第3号:Scala-快速,多範例程式設計

JVM腳本語言第4号:FANTOM - Java和網加性能。

JVM腳本語言第4号:Jython - JVM上的Python。

頂部的腳本語言在JVM上

Groovy JRuby Scala FANTOM Jython
樣式/打字 OO /動态 OO /動态 面向對象,功能/靜态 00 /靜态 OO /動态
藍本 Java Ruby N / A N / A Python
執行 編譯 編譯,解釋 編譯 半編譯 編譯
平台(S) JVM JVM JVM JVM,NET CLR JVM
與Java的整合 優秀 優秀 優秀 公平 優秀
執行速度 公平 公平 優秀 非常好 放慢
工具支援 廣泛 公平 廣泛

  原文http://www.infoworld.com/d/developer-world/top-five-scripting-languages-the-jvm-855?page=0,0如下:

        Anyone who has followed software development tools during the last decade knows that the term "Java" refers to a pair of technologies: the Java programming language and the Java Virtual Machine (JVM). The Java language is compiled into bytecodes that run on the JVM. Through this design, Java delivers its vaunted portability.

        The language and the JVM, however, have been increasingly moving in opposite directions. The language has grown more complex, while the JVM has become one of the fastest and most efficient execution platforms available. On many benchmarks, Java equals the performance of binary code generated by compiled languages such as C and C++. The increasing complexity of the language and the remarkable performance, portability, and scalability of the JVM have created an opening for a new generation of programming languages. These languages lack Java's syntax overload (often referred to disparagingly as its "ceremony") -- that is, the amount of excess code that needs to be cranked out before the code that does the actual work can be written -- but take advantage of the JVM.

        [ Eclipse PDT, NetBeans, NuSphere PhpED, and Zend Studio lead a capable field of IDEs for Web developers. See "InfoWorld review: Eight PHP power tools" | With WYSIWYG prototyping environments and preconfigured graphical components, rapid Web development tools can help you build applications faster -- but with less flexibility. See "InfoWorld review: Tools for rapid Web development" ]

        In this article, I examine a handful of these languages, comparing and contrasting them, and identifying the needs they satisfy particularly well. I limit myself to the JVM languages that are free and open source. The closed source, commercial world, surprisingly, has few comparable offerings. The one standout is Cold Fusion Markup Language, which is part of Adobe's Cold Fusion Web application development environment.

        Technologists differ on what exactly is a scripting language. In its narrowest definition, it's a language that enables the developer to write quick programs. These programs are generally interpreted or semicompiled, rather than compiled in the traditional manner. In choosing the languages for this review, I used a broader definition, which is any JVM language that is simpler to code in than Java. Some are compiled, others are semicompiled, but all are suitable for rapid development. The languages I've focused on are Groovy, JRuby, Fantom, Jython, and Scala. There are a few other candidates, namely Clojure, JavaFX, and NetRexx, which I cover briefly at the end.

        The JVM scripting languages today naturally divide into two groups based on their rate of adoption. Groovy and JRuby fall into the popular camp, while the others are niche players -- that is, they appeal to a small community at present. It's important to note, however, that both Groovy and JRuby were also niche players two years ago, so there is no reason to believe that a niche language is relegated permanently to the margins. I believe that the likelihood of emergence favors Scala, then Fantom, and finally Jython. As I explain later, I think Jython's moment in the sun has probably come and gone.

JVM scripting language No. 1: Groovy -- powerful, high-level, enterprise-friendly

JVM scripting language No. 2: JRuby -- a better Ruby than Ruby?

JVM scripting language No. 3: Scala -- fast, multiparadigm programming

JVM scripting language No. 4: Fantom -- Java and .Net plus performance

JVM scripting language No. 5: Jython -- Python for the JVM

Top scripting languages on the JVM

Groovy JRuby Scala Fantom Jython
Style / typing OO / Dynamic OO / Dynamic OO, Functional / Static OO / Static OO / Dynamic
Modeled on Java Ruby N/A N/A Python
Execution Compiled Compiled, Interpreted Compiled Semicompiled Compiled
Platform(s) JVM JVM JVM JVM, .Net CLR JVM
Integration with Java Excellent Excellent Excellent Fair Excellent
Execution speed Fair Fair Excellent Very Good Slow
Tool support Extensive Fair Extensive Little Little