Next Generation Java
Ceylon, Kotlin, Scala & Fantom im Überblick

Autor: dogmadic : http://www.sxc.hu/photo/436457
http://...
Disclaimer

Java

2 | Next Generation JVM Languages
Überblick

3.
3 | Next Generation JVM Languages
Überblick

3.
4 | Next Generation JVM Languages
Ist Java das neue Cobol?

–
–
–
–
–

5 | Next Generation JVM Languages

http://www.sxc.hu/photo/1389360
Ein BLick auf die .NET Plattform

l
l

l

–
–
–
–
–
–
–

6 | Next Generation JVM Languages
The JVM at a glance

l
l

l

–
–
–
–
–
–
–

7 | Next Generation JVM Languages
Das Java- Universum
8 | Next Generation JVM Languages
Überblick

3.
9 | Next Generation JVM Languages
Warum neue JVM Sprachen?

10 | Next Generation JVM Languages
Beginning Buzz-Word Bingo….

11 | Next Generation JVM Languages

http://www.sxc.hu/photo/377913
Warum neue JVM Sprachen?

12 | Next Generation JVM Languages
Von Lambdas und „1. Klasse“-Rechnen

13 | Next Generation JVM Languages
Imperativ vs. Funktional: Beispiel #1 Quicksort
public void quicksort(int array[]) {
quicksort(array, 0, array.length - 1)...
Imperativ vs. Funktional: Beispiel #1 Quicksort
public void quicksort(int array[]) {
quicksort(array, 0, array.length - 1)...
Imperativ vs. Funktional: Beispiel #2
int sum = 0;
for (int i = 0; i < 150; i++)
{
if (i % 5 != 0)
sum += i;
}

int sum = ...
Objektorientierte vs. Funktionale Programmierung

FP
Sammlung von Funktionen
Zustandlos & Unveränderlich
Rekursiv
Auswertu...
Warum neue JVM Sprachen?

18 | Next Generation JVM Languages
Dynamic Typing

Parsen und
Auflisten der Daten
19 | Next Generation JVM Languages

Practically Groovy: Building, parsing, ...
Dynamic Typing
import
import
import
import

org.xml.sax.SAXException;
org.w3c.dom.*;
javax.xml.parsers.*;
java.io.IOExcept...
Dynamic Typing

def langs = new XmlParser().parse("languages.xml")
println "type = ${langs.attribute("type")}"
langs.langu...
Warum neue JVM Sprachen?

22 | Next Generation JVM Languages
Schlankere Syntax : Listen befüllen
List<String> languages = new LinkedList<String>();
languages.add("Java");
languages.ad...
Schlankere Syntax : Getter/Setter
Class Circle
private Coordinate center, float radius;
public void setCenter(Coordinate c...
Warum neue JVM Sprachen?

25 | Next Generation JVM Languages
Warum neue JVM Sprachen?

26 | Next Generation JVM Languages
java.lang.NullPointerException
at
at
at
at
at
at
at
at
at
at

com.sun.tools.javac.comp.Check.checkCompatibleConcretes(Chec...
Die Null zügeln

l

l

28 | Next Generation JVM Languages
Warum neue JVM Sprachen?

29 | Next Generation JVM Languages
Domain Specific Languages

l

30 | Next Generation JVM Languages
Warum neue JVM Sprachen?

31 | Next Generation JVM Languages
Warum neue JVM Sprachen?

32 | Next Generation JVM Languages
33 | Next Generation JVM Languages
Alternativen zur Threads & Co.

l

–

–
–
l

–
–

34 | Next Generation JVM Languages

http://www.sxc.hu/photo/515995
Warum neue JVM Sprachen?

35 | Next Generation JVM Languages
Warum neue JVM Sprachen?

36 | Next Generation JVM Languages
Scripting

l

l

–

–
–
–

37 | Next Generation JVM Languages
Warum neue JVM Sprachen?

38 | Next Generation JVM Languages
Meta-Programmierung
Programmen, die sich oder andere P. als Daten behandeln und verändert.

l

–
–
–

l
l

–
–

39 | Next ...
Warum neue JVM Sprachen?

40 | Next Generation JVM Languages
Dynamic & Weak Typing

l
“A programming language is said to be dynamically typed when the majority
of its type checking is...
Warum neue JVM Sprachen?

42 | Next Generation JVM Languages
Überblick

3.
43 | Next Generation JVM Languages
Auszug neuer JVM Sprachen

Inzwischen über 50-250 verschiedene Sprachen auf der JVM…
44 | Next Generation JVM Languages
Anforderungen für den Industriellen Einsatz

–
–

–
–
45 | Next Generation JVM Languages
Sprachen im industriellen Einsatz

[...] programming by larger groups of people or by smaller groups over
longer time peri...
Auszug neuer JVM Sprachen

47 | Next Generation JVM Languages
Übersicht & Entwicklung JVM Sprachen

48 | Next Generation JVM Languages
Statisch-typisierte JVM Sprachen im Überblick

49 | Next Generation JVM Languages
50 | Next Generation JVM Languages

http://www.flickr.com/photos/tonino62/2295302323/

.
Scala im Portrait

l

–

51 | Next Generation JVM Languages
Scala im Portrait

l
l

–
–
–

52 | Next Generation JVM Languages
Traits & Mixins

trait Similarity {
def isSimilar(x: Any): Boolean
def isNotSimilar(x: Any): Boolean = !isSimilar(x)
}

53...
Extension Methods

l
l
54 | Next Generation JVM Languages
TL;DR
Too long; didn‘t read

Scala & Ko-/Kontravarianz
55 | Next Generation JVM Languages

http://www.sxc.hu/photo/330223
Scala im Portrait

l
l

l

–
–
–
–
–

56 | Next Generation JVM Languages
Scala - Implicit Conversion

object A {
implicit def aToB(a: A) : B = {
new B()
}
}

57 | Next Generation JVM Languages

o...
58 | Next Generation JVM Languages
Pattern Matching = Switch/Instanceof++

59 | Next Generation JVM Languages
Beherrschbarkeit?
http://bit.ly/LP2Spb

60 | Next Generation JVM Languages
Erfahrungen

l

–
–
–

l

–
–
–

61 | Next Generation JVM Languages
Erfahrungen

l

l

–
–
–
–
–

62 | Next Generation JVM Languages
JVM Sprachen im Überblick (Features)










































63 | Next Generation J...
Scala Summary

l

–
–

l
l

–
–
–

64 | Next Generation JVM Languages
Fantom

65 | Next Generation JVM Languages

http://www.sxc.hu/photo/366158
Fantom : Portabilität

l
„one portable system, graphics, and widget library
that just works everywhere”

l
–
–
–

66 | Nex...
Fantom im Portrait

l

l

l

–
–
–
–
–
–
–
–

67 | Next Generation JVM Languages
Fantom : Quadratur der Kreise

l
l
l
obj.methode()
obj->methode()

l
l

68 | Next Generation JVM Languages
Fantom : Multi-Threading

–
–
–

69 | Next Generation JVM Languages
Fantom : Elegante APIs und Sprache

–
–
–
–
–
–
–
–
70 | Next Generation JVM Languages
Fantom Hello World (Webapp)
using util
using web
using wisp
class WebHello : AbstractMain
{
@Opt { help = "http port" }
In...
Fantom: Summary

l

–
–
–

l
l

–
–
–

72 | Next Generation JVM Languages
JVM Sprachen im Überblick (Features)










































73 | Next Generation J...
http://bit.ly/LKM5YG

74 | Next Generation JVM Languages
Ceylon im Portrait
„Ceylon’s goal is to design the language that Java would have been
if its designers had been able to pr...
Ceylon: Code Example
doc "A component"
shared abstract class Component() {
OpenList<Callable<Void,Event>> observers =
Open...
…bisschen Spannendes hat Ceylon aber schon…

l
l
l
77 | Next Generation JVM Languages

http://www.sxc.hu/photo/732192
Nullables

78 | Next Generation JVM Languages
Von Typen mit und ohne Charakter

79 | Next Generation JVM Languages
Ceylon: Summary

l
l

–
–
–
–
–
–

80 | Next Generation JVM Languages
JVM Sprachen im Überblick (Features)










































81 | Next Generation J...
82 | Next Generation JVM Languages

http://www.sxc.hu/photo/1339625
Kotlin im Portrait
“General-purpose language intended for industrial use”
Kotlin = Java++ bzw. Scala--

l

–
–
–
–
–

83 |...
Kotlin Motivation & Hintergrund

“Although we’ve developed support for several JVM-targeted programming languages,
we are ...
85 | Next Generation JVM Languages
Kotlin Sprach-Features

–
–

86 | Next Generation JVM Languages
Kotlin Sprach-Features

l
l
interface Collection<E> ... {
void addAll(Collection<? extends E> items);
}

abstract class So...
Kotlin Sprach-Features

l
l
l
l
l
l
l

88 | Next Generation JVM Languages
Kotlin: Online Demo

89 | Next Generation JVM Languages
Kotlin Summary:

l
l
l
l
l
l

90 | Next Generation JVM Languages
JVM Sprachen im Überblick (Features)










































91 | Next Generation J...
Überblick

3.
92 | Next Generation JVM Languages
Blick über den Tellerrand

93 | Next Generation JVM Languages

http://www.sxc.hu/photo/1167119/
Resumee

94 | Next Generation JVM Languages

http://www.sxc.hu/photo/1022369
Anforderungen für den Industriellen Einsatz

–
–

–
–
95 | Next Generation JVM Languages
Wertung JVM Sprachen für den Industrie-Einsatz












































...
Resumée

l
l
l
l

–
–

–

l
l
l

97 | Next Generation JVM Languages
Resumée

98 | Next Generation JVM Languages
Weiterführende Information
Benjamin.Schmid@exxcellent.de
Scala: http://www.scala-lang.org/
Ceylon: http://ceylon-lang.org/...
Upcoming SlideShare
Loading in …5
×

Next Generation Java - Ceylon, Kotlin, Scala & Fantom im Überblick

1,087 views
1,001 views

Published on

Ist Java das neue Cobol? Die Flut neuer JVM-Sprachen hält dem eindrücklich die Leistungsfähigkeit und Modernität der Plattform entgegen. Insbesondere für den industriellen Einsatz gibt es neue Kandidaten, die wir genauer betrachten wollen. Dabei lernen wir viele Innovationen und Features rund um eine robustere und effizientere Entwicklung kennen. Code-Beispiele und Hintergrundinformationen über Tooling und Projekt helfen bei der kritischen Betrachtung. Ein abschließendes Fazit über ihre Potentiale gibt Orientierung im Dschungel der Neuerungen.

Extended Abstract:
Ein bisschen in die Jahre gekommen ist es ja schon: Java! Vereinzelt eilt ihm schon gar der verbrämende Ruf des "neuen Cobols" voraus. Dabei ist die zugrunde liegende JVM Plattform moderner und hochleistungsfähiger als je zuvor. Sowohl Android als auch die schiere Flut neu aus der Taufe gehobenen JVM Sprachen belegen die beeindruckende Solidität ihres Fundaments.

Zu den frühen, eher Scripting-orientierten Sprachentwürfen sind inzwischen einige statisch-typisierte Dialekte dazu gestoßen, die echtes Potential haben auch für Unternehmensanwendungen als ernste Alternativen zu Java aufzusteigen.

So z.B. Kotlin, welches explizit für den industriellen Einsatz bei 100% Java-Interoperabilität entworfen wurde. Oder das unbekanntere Fantom, das mit JavaScript/.NET-Crosscompiling, semi-statisch-/dynamischer Typisierung und innovativen Multithreading-Unterstützung selbst dem JVM-Urgestein Scala einiges entgegenzusetzen hat.

Wir werfen einen Blick auf diese verschiedenen Sprachen. Dabei betrachten wir insbesondere aus der Perspektive des industrienahen Java-Entwicklers ihre spannenden Kern-Features. Einzelne Code-Fragmente und Gegenüberstellungen sowie Hintergründe und Details zu ihrer Tooling- und Projekt-Landschaft sollen helfen, hier frühe Orientierung im Dschungel der spannenden Neuerungen zu erlangen.

Published in: Technology, News & Politics
0 Comments
1 Like
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
1,087
On SlideShare
0
From Embeds
0
Number of Embeds
8
Actions
Shares
0
Downloads
0
Comments
0
Likes
1
Embeds 0
No embeds

No notes for slide

Next Generation Java - Ceylon, Kotlin, Scala & Fantom im Überblick

  1. 1. Next Generation Java Ceylon, Kotlin, Scala & Fantom im Überblick Autor: dogmadic : http://www.sxc.hu/photo/436457 http://www.sxc.hu/photo/36128
  2. 2. Disclaimer Java 2 | Next Generation JVM Languages
  3. 3. Überblick 3. 3 | Next Generation JVM Languages
  4. 4. Überblick 3. 4 | Next Generation JVM Languages
  5. 5. Ist Java das neue Cobol? – – – – – 5 | Next Generation JVM Languages http://www.sxc.hu/photo/1389360
  6. 6. Ein BLick auf die .NET Plattform l l l – – – – – – – 6 | Next Generation JVM Languages
  7. 7. The JVM at a glance l l l – – – – – – – 7 | Next Generation JVM Languages
  8. 8. Das Java- Universum 8 | Next Generation JVM Languages
  9. 9. Überblick 3. 9 | Next Generation JVM Languages
  10. 10. Warum neue JVM Sprachen? 10 | Next Generation JVM Languages
  11. 11. Beginning Buzz-Word Bingo…. 11 | Next Generation JVM Languages http://www.sxc.hu/photo/377913
  12. 12. Warum neue JVM Sprachen? 12 | Next Generation JVM Languages
  13. 13. Von Lambdas und „1. Klasse“-Rechnen 13 | Next Generation JVM Languages
  14. 14. Imperativ vs. Funktional: Beispiel #1 Quicksort public void quicksort(int array[]) { quicksort(array, 0, array.length - 1); } public void quicksort(int array[], int start, int end){ int i = start; int k = end; if (end - start >= 1) { int pivot = array[start]; while (k > i) { while (array[i] <= pivot && i <= end && k > i) i++; while (array[k] > pivot && k >= start && k >= i) k--; if (k > i) swap(array, i, k); } swap(array, start, k); quicksort(array, start, k - 1); quicksort(array, k + 1, end); } else { return; } } public void swap(int array[], int index1, int index2) { int temp = array[index1]; array[index1] = array[index2]; array[index2] = temp; } 14 | Next Generation JVM Languages
  15. 15. Imperativ vs. Funktional: Beispiel #1 Quicksort public void quicksort(int array[]) { quicksort(array, 0, array.length - 1); } public void quicksort(int array[], int start, int end){ int i = start; int k = end; if (end - start >= 1) { int pivot = array[start]; while (k > i) { while (array[i] <= pivot && i <= end && k > i) i++; while (array[k] > pivot && k >= start && k >= i) k--; if (k > i) swap(array, i, k); } swap(array, start, k); quicksort(array, start, k - 1); quicksort(array, k + 1, end); } else { return; } } public void swap(int array[], int index1, int index2) { int temp = array[index1]; array[index1] = array[index2]; array[index2] = temp; } 15 | Next Generation JVM Languages
  16. 16. Imperativ vs. Funktional: Beispiel #2 int sum = 0; for (int i = 0; i < 150; i++) { if (i % 5 != 0) sum += i; } int sum = Enumerable.Range(0, 150).Where(i => i % 5 != 0).Sum(); f1( 16 | Next Generation JVM Languages f2( f3( f4())))
  17. 17. Objektorientierte vs. Funktionale Programmierung FP Sammlung von Funktionen Zustandlos & Unveränderlich Rekursiv Auswertung: Lazy 17 | Next Generation JVM Languages OOP Sammlung von Objekten Zustandsbehaftet Iterativ Imperativer Ablauf
  18. 18. Warum neue JVM Sprachen? 18 | Next Generation JVM Languages
  19. 19. Dynamic Typing Parsen und Auflisten der Daten 19 | Next Generation JVM Languages Practically Groovy: Building, parsing, and slurping XML http://www.ibm.com/developerworks/java/library/j-pg05199/
  20. 20. Dynamic Typing import import import import org.xml.sax.SAXException; org.w3c.dom.*; javax.xml.parsers.*; java.io.IOException; public class ParseXml { public static void main(String[] args) { DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); try { DocumentBuilder db = dbf.newDocumentBuilder(); Document doc = db.parse("src/languages.xml"); //print the "type" attribute Element langs = doc.getDocumentElement(); System.out.println("type = " + langs.getAttribute("type")); //print the "language" elements NodeList list = langs.getElementsByTagName("language"); for(int i = 0 ; i < list.getLength();i++) { Element language = (Element) list.item(i); System.out.println(language.getTextContent()); } }catch(ParserConfigurationException pce) { pce.printStackTrace(); }catch(SAXException se) { se.printStackTrace(); }catch(IOException ioe) { ioe.printStackTrace(); } } } 20 | Next Generation JVM Languages Parsen und Auflisten der Daten Practically Groovy: Building, parsing, and slurping XML http://www.ibm.com/developerworks/java/library/j-pg05199/
  21. 21. Dynamic Typing def langs = new XmlParser().parse("languages.xml") println "type = ${langs.attribute("type")}" langs.language.each{ println it.text() } Parsen und Auflisten der Daten 21 | Next Generation JVM Languages Practically Groovy: Building, parsing, and slurping XML http://www.ibm.com/developerworks/java/library/j-pg05199/
  22. 22. Warum neue JVM Sprachen? 22 | Next Generation JVM Languages
  23. 23. Schlankere Syntax : Listen befüllen List<String> languages = new LinkedList<String>(); languages.add("Java"); languages.add("Ruby"); languages.add("Python"); languages.add("Perl"); stuff = [] stuff << "Java", "Ruby", "Python" 23 | Next Generation JVM Languages Practically Groovy: Building, parsing, and slurping XML http://www.ibm.com/developerworks/java/library/j-pg05199/
  24. 24. Schlankere Syntax : Getter/Setter Class Circle private Coordinate center, float radius; public void setCenter(Coordinate center){ this.center = center; } public Coordinate getCenter(){ return center; } public void setRadius(float radius){ this.radius = radius; } public Coordinate getRadius(){ return radius; } } class Circle attr_accessor :center, :radius end 24 | Next Generation JVM Languages Practically Groovy: Building, parsing, and slurping XML http://www.ibm.com/developerworks/java/library/j-pg05199/
  25. 25. Warum neue JVM Sprachen? 25 | Next Generation JVM Languages
  26. 26. Warum neue JVM Sprachen? 26 | Next Generation JVM Languages
  27. 27. java.lang.NullPointerException at at at at at at at at at at com.sun.tools.javac.comp.Check.checkCompatibleConcretes(Check.java:1141) com.sun.tools.javac.comp.Check.checkCompatibleSupertypes(Check.java:1495) com.sun.tools.javac.comp.Attr.attribClassBody(Attr.java:2451) com.sun.tools.javac.comp.Attr.attribClass(Attr.java:2406) com.sun.tools.javac.comp.Attr.attribClass(Attr.java:2355) com.sun.tools.javac.main.JavaCompiler.compile(JavaCompiler.java:444) com.sun.tools.javac.main.Main.compile(Main.java:592) com.sun.tools.javac.main.Main.compile(Main.java:544) com.sun.tools.javac.Main.compile(Main.java:67) com.sun.tools.javac.Main.main(Main.java:52) 27 | Next Generation JVM Languages
  28. 28. Die Null zügeln l l 28 | Next Generation JVM Languages
  29. 29. Warum neue JVM Sprachen? 29 | Next Generation JVM Languages
  30. 30. Domain Specific Languages l 30 | Next Generation JVM Languages
  31. 31. Warum neue JVM Sprachen? 31 | Next Generation JVM Languages
  32. 32. Warum neue JVM Sprachen? 32 | Next Generation JVM Languages
  33. 33. 33 | Next Generation JVM Languages
  34. 34. Alternativen zur Threads & Co. l – – – l – – 34 | Next Generation JVM Languages http://www.sxc.hu/photo/515995
  35. 35. Warum neue JVM Sprachen? 35 | Next Generation JVM Languages
  36. 36. Warum neue JVM Sprachen? 36 | Next Generation JVM Languages
  37. 37. Scripting l l – – – – 37 | Next Generation JVM Languages
  38. 38. Warum neue JVM Sprachen? 38 | Next Generation JVM Languages
  39. 39. Meta-Programmierung Programmen, die sich oder andere P. als Daten behandeln und verändert. l – – – l l – – 39 | Next Generation JVM Languages
  40. 40. Warum neue JVM Sprachen? 40 | Next Generation JVM Languages
  41. 41. Dynamic & Weak Typing l “A programming language is said to be dynamically typed when the majority of its type checking is performed at run-time as opposed to at compile-time. In dynamic typing values have types, but variables do not […]” https://en.wikipedia.org/wiki/Dynamic_typing#Dynamic_typing l […] strong typing when it specifies one or more restrictions on how operations involving values of different data types can be intermixed. Weak typing means that a language implicitly converts (or casts) types when used. https://en.wikipedia.org/wiki/Dynamic_typing#Dynamic_typing 41 | Next Generation JVM Languages
  42. 42. Warum neue JVM Sprachen? 42 | Next Generation JVM Languages
  43. 43. Überblick 3. 43 | Next Generation JVM Languages
  44. 44. Auszug neuer JVM Sprachen Inzwischen über 50-250 verschiedene Sprachen auf der JVM… 44 | Next Generation JVM Languages
  45. 45. Anforderungen für den Industriellen Einsatz – – – – 45 | Next Generation JVM Languages
  46. 46. Sprachen im industriellen Einsatz [...] programming by larger groups of people or by smaller groups over longer time periods [...] result in large, and hence complicated, programs [...] place emphasis on partitioning work into modules with preciselyspecified interactions. http://en.wikipedia.org/wiki/Programming_in_the_large_and_programming_in_the_small – – 46 | Next Generation JVM Languages
  47. 47. Auszug neuer JVM Sprachen 47 | Next Generation JVM Languages
  48. 48. Übersicht & Entwicklung JVM Sprachen 48 | Next Generation JVM Languages
  49. 49. Statisch-typisierte JVM Sprachen im Überblick 49 | Next Generation JVM Languages
  50. 50. 50 | Next Generation JVM Languages http://www.flickr.com/photos/tonino62/2295302323/ .
  51. 51. Scala im Portrait l – 51 | Next Generation JVM Languages
  52. 52. Scala im Portrait l l – – – 52 | Next Generation JVM Languages
  53. 53. Traits & Mixins trait Similarity { def isSimilar(x: Any): Boolean def isNotSimilar(x: Any): Boolean = !isSimilar(x) } 53 | Next Generation JVM Languages
  54. 54. Extension Methods l l 54 | Next Generation JVM Languages
  55. 55. TL;DR Too long; didn‘t read Scala & Ko-/Kontravarianz 55 | Next Generation JVM Languages http://www.sxc.hu/photo/330223
  56. 56. Scala im Portrait l l l – – – – – 56 | Next Generation JVM Languages
  57. 57. Scala - Implicit Conversion object A { implicit def aToB(a: A) : B = { new B() } } 57 | Next Generation JVM Languages object MainClass { def main(args: Array[String]) { val b : B = new A() } }
  58. 58. 58 | Next Generation JVM Languages
  59. 59. Pattern Matching = Switch/Instanceof++ 59 | Next Generation JVM Languages
  60. 60. Beherrschbarkeit? http://bit.ly/LP2Spb 60 | Next Generation JVM Languages
  61. 61. Erfahrungen l – – – l – – – 61 | Next Generation JVM Languages
  62. 62. Erfahrungen l l – – – – – 62 | Next Generation JVM Languages
  63. 63. JVM Sprachen im Überblick (Features)                      63 | Next Generation JVM Languages           
  64. 64. Scala Summary l – – l l – – – 64 | Next Generation JVM Languages
  65. 65. Fantom 65 | Next Generation JVM Languages http://www.sxc.hu/photo/366158
  66. 66. Fantom : Portabilität l „one portable system, graphics, and widget library that just works everywhere” l – – – 66 | Next Generation JVM Languages
  67. 67. Fantom im Portrait l l l – – – – – – – – 67 | Next Generation JVM Languages
  68. 68. Fantom : Quadratur der Kreise l l l obj.methode() obj->methode() l l 68 | Next Generation JVM Languages
  69. 69. Fantom : Multi-Threading – – – 69 | Next Generation JVM Languages
  70. 70. Fantom : Elegante APIs und Sprache – – – – – – – – 70 | Next Generation JVM Languages
  71. 71. Fantom Hello World (Webapp) using util using web using wisp class WebHello : AbstractMain { @Opt { help = "http port" } Int port := 8080 override Int run() { wisp := WispService { it.port = this.port it.root = HelloMod() } return runServices([wisp]) } } 71 | Next Generation JVM Languages const class HelloMod : WebMod { override Void onGet() { res.headers["Content-Type"] = "text/plain; charset=utf-8" res.out.print("hello world #4") } }
  72. 72. Fantom: Summary l – – – l l – – – 72 | Next Generation JVM Languages
  73. 73. JVM Sprachen im Überblick (Features)                      73 | Next Generation JVM Languages           
  74. 74. http://bit.ly/LKM5YG 74 | Next Generation JVM Languages
  75. 75. Ceylon im Portrait „Ceylon’s goal is to design the language that Java would have been if its designers had been able to predict the future.” – – – – – 75 | Next Generation JVM Languages
  76. 76. Ceylon: Code Example doc "A component" shared abstract class Component() { OpenList<Callable<Void,Event>> observers = OpenList<Callable<Void,Event>>(); shared void addObserver(void observe(Event event)) { observers.append(observe); } shared void fire(Event event) { for (void observe(Event event) in observers) { observe(event); } } } 76 | Next Generation JVM Languages
  77. 77. …bisschen Spannendes hat Ceylon aber schon… l l l 77 | Next Generation JVM Languages http://www.sxc.hu/photo/732192
  78. 78. Nullables 78 | Next Generation JVM Languages
  79. 79. Von Typen mit und ohne Charakter 79 | Next Generation JVM Languages
  80. 80. Ceylon: Summary l l – – – – – – 80 | Next Generation JVM Languages
  81. 81. JVM Sprachen im Überblick (Features)                      81 | Next Generation JVM Languages           
  82. 82. 82 | Next Generation JVM Languages http://www.sxc.hu/photo/1339625
  83. 83. Kotlin im Portrait “General-purpose language intended for industrial use” Kotlin = Java++ bzw. Scala-- l – – – – – 83 | Next Generation JVM Languages
  84. 84. Kotlin Motivation & Hintergrund “Although we’ve developed support for several JVM-targeted programming languages, we are still writing all of our IntelliJ-based IDEs almost entirely in Java. We want to become more productive by switching to a more expressive language.” l – – – – 84 | Next Generation JVM Languages
  85. 85. 85 | Next Generation JVM Languages
  86. 86. Kotlin Sprach-Features – – 86 | Next Generation JVM Languages
  87. 87. Kotlin Sprach-Features l l interface Collection<E> ... { void addAll(Collection<? extends E> items); } abstract class Source<out T> { fun nextT() : T } fun fill(dest : Array<in String>, value : String) { // ... } 87 | Next Generation JVM Languages
  88. 88. Kotlin Sprach-Features l l l l l l l 88 | Next Generation JVM Languages
  89. 89. Kotlin: Online Demo 89 | Next Generation JVM Languages
  90. 90. Kotlin Summary: l l l l l l 90 | Next Generation JVM Languages
  91. 91. JVM Sprachen im Überblick (Features)                      91 | Next Generation JVM Languages           
  92. 92. Überblick 3. 92 | Next Generation JVM Languages
  93. 93. Blick über den Tellerrand 93 | Next Generation JVM Languages http://www.sxc.hu/photo/1167119/
  94. 94. Resumee 94 | Next Generation JVM Languages http://www.sxc.hu/photo/1022369
  95. 95. Anforderungen für den Industriellen Einsatz – – – – 95 | Next Generation JVM Languages
  96. 96. Wertung JVM Sprachen für den Industrie-Einsatz                        96 | Next Generation JVM Languages         
  97. 97. Resumée l l l l – – – l l l 97 | Next Generation JVM Languages
  98. 98. Resumée 98 | Next Generation JVM Languages
  99. 99. Weiterführende Information Benjamin.Schmid@exxcellent.de Scala: http://www.scala-lang.org/ Ceylon: http://ceylon-lang.org/ Kotlin: http://blog.jetbrains.com/kotlin/ Kotlin Demo: http://kotlin-demo.jetbrains.com/ Fantom vs. Kotlin http://fantom.org/sidewalk/topic/1581 99 | Next Generation JVM Languages Gosu: http://gosu-lang.org/ Search for a better Java: http://blog.joda.org/2011/07/kotlin-and-search-forbetter-java_9066.html Autor: woodleywonderworks http://www.flickr.com/photos/wwworks/4759535950/

×