SlideShare a Scribd company logo
turn ideas into code faster
Moritz Eysholdt
itemis AG
turn ideas into code faster
!
Java

Moritz Eysholdt
itemis AG
!

Java
!

Java
immutability
dispatch
data_extraction
polymorphism

caching

data_transformation

!

Java
design_patterns
state

null_state

events
persistence

localization
immutability

for

dispatch
data_extraction

caching

if

implements
extends

polymorphism

data_transformation

!

Java
design_patterns
while

state
null_state

events

break

;
persistence

localization

return

fields

variables
immutability
dispatch

caching

data_transformation

if

for

implements

data_extraction
polymorphism

!
state
null_state
events
localization
persistence
design_patterns

extends

Java
while
break
variables
fields

;

return
!

Xtend

Java
functional_programming
dispatch
templates

!

Xtend
lambdas
extension_methods
active_annotations

Java
functional_programming
dispatch
templates

!

Xtend
lambdas
extension_methods
active_annotations

Java
Java

for-if-spaghetti
List<String> result = new ArrayList<String>();
for(Integer integer: integers) {
if(integer > 10) {
result.add(“Int: ” + integer);
}
}

val result = integers.filter[it > 10].map[“Int” + it]

Xtend

functional programming
Java

if-else-spaghetti

String result = null;
if(foo != null) {
result = foo.value;
}
String result;
if(bar != null) {
result = bar;
} else {
result = “unset”;
}

val result = foo?.value

val result = bar ?: “unset”

Xtend

null-safe operators
Java

call non-member methods

backwards(reading(are(you(“X”))))

“X”.you.are.reading.backwards

Xtend

extension methods
Java

type-def boilerplate

Map<String, Set<Integer>> ints = new HashMap<String, Set<Integer>>();

val ints = new HashMap<String, Set<Integer>>

Xtend

type inference
Java

if-else-instanceof-spaghetti

if(shape instanceof Rect)
return ((Rect) shape).width * ((Rect) shape).height;
else if(shape instanceof Circle)
return ((Circle) shape).radius * 2 * PI;
else
return 0;
return switch shape {
Rect: shape.width * shape.height
Circle: shape.radius * 2 * PI
default: 0
}

Xtend

smart switch expression
Java

if-else-instanceof-spaghetti
Xtend

public double surface(Shape shape) {
if(shape instanceof Rect)
return surface((Rect) shape);
else if(shape instanceof Circle)
return surface((Circle) shape);
return 0;
}
protected double surface(Rectangle rect) {
return rect.width * rect.height;
}
protected double surface(Circle circle) {
return circle.radius * 2 + PI;
}

dispatch methods

def dispatch surface(Rectangle rect) {
rect.width * rect.height;
}
def dispatch surface(Circle circle) {
circle.radius * 2 + PI;
}
Java

immutable class boilerplate

@Data class Point {
int x
int y
}

public class Point {
private final int x;
private final int y;
public
public
public
public
public
public

Foo(int x, int x) { ... }
int getX() { ... }
int getY() { ... }
int hashCode() { ... }
boolean equals(Object obj) { ... }
String toString() { ... }

}

Xtend

@Data annotation
Java

getter/setter boilerplate

public class Point {
private int x;
private int y;
public
public
public
public

int getX() { ...
int getY() { ...
void setX(int x)
void setY(int y)

}
}
{ ... }
{ ... }

class Point {
@Property int x
@Property int y
}

}

Xtend

@Property annotation
Java

boilerplate or design pattern

public class MyClass {
...
...
...
...

...
...
...
...

...
...
...
...

{
{
{
{

...
...
...
...

}
}
}
}

@MyAnnotation class MyClass {
...
}

}

Xtend

active annotation
EOF

More Related Content

KEY
Codegeneration Goodies
PDF
Serializing EMF models with Xtext
PDF
Xtext's new Formatter API
DOC
EMF Tips n Tricks
PDF
Using Xcore with Xtext
PDF
Effective Scala (JavaDay Riga 2013)
PDF
Twins: Object Oriented Programming and Functional Programming
PDF
Recipes to build Code Generators for Non-Xtext Models with Xtend
Codegeneration Goodies
Serializing EMF models with Xtext
Xtext's new Formatter API
EMF Tips n Tricks
Using Xcore with Xtext
Effective Scala (JavaDay Riga 2013)
Twins: Object Oriented Programming and Functional Programming
Recipes to build Code Generators for Non-Xtext Models with Xtend

What's hot (20)

PDF
Effective Scala (SoftShake 2013)
PDF
Effective Scala: Programming Patterns
PPT
Ajax and JavaScript Bootcamp
PPT
JavaScript Basics
PPT
A Deeper look into Javascript Basics
KEY
Java Performance MythBusters
PPTX
Java best practices
PPT
Javascript
PPT
The JavaScript Programming Language
PPT
Introduction to Javascript
PDF
Basics of JavaScript
PPT
JavaScript - An Introduction
PDF
Why Java Sucks and C# Rocks (Final)
PDF
Fundamental JavaScript [UTC, March 2014]
PDF
A Re-Introduction to JavaScript
PDF
Compiler2016 by abcdabcd987
PDF
Javascript basic course
PPT
Java Intro
ODP
What I Love About Ruby
PDF
Javascript basics
Effective Scala (SoftShake 2013)
Effective Scala: Programming Patterns
Ajax and JavaScript Bootcamp
JavaScript Basics
A Deeper look into Javascript Basics
Java Performance MythBusters
Java best practices
Javascript
The JavaScript Programming Language
Introduction to Javascript
Basics of JavaScript
JavaScript - An Introduction
Why Java Sucks and C# Rocks (Final)
Fundamental JavaScript [UTC, March 2014]
A Re-Introduction to JavaScript
Compiler2016 by abcdabcd987
Javascript basic course
Java Intro
What I Love About Ruby
Javascript basics
Ad

Similar to Turning Ideas Into Code Faster (20)

PPTX
Writing Hadoop Jobs in Scala using Scalding
PDF
Making The Move To Java 17 (JConf 2022)
PPTX
Scala Programming for Semantic Web Developers ESWC Semdev2015
PPT
PPTX
PPTX
Knowledge of Javascript
ODP
Caerusone
PPTX
Jugar Introduccion a Scala
PPT
Oscon keynote: Working hard to keep it simple
PDF
Intro to Scala.js - Scala UG Cologne
PDF
Crossing the Bridge: Connecting Rails and your Front-end Framework
PDF
Adding geospatial features to a java web app
PDF
Modern, Scalable, Ambitious apps with Ember.js
PDF
Introduction To Scala
PDF
What did you miss in Java from 9-13?
KEY
Debugging Your Ext JS Code
PDF
Aop clustering
PDF
Coding Your Way to Java 13
PDF
Real life-coffeescript
Writing Hadoop Jobs in Scala using Scalding
Making The Move To Java 17 (JConf 2022)
Scala Programming for Semantic Web Developers ESWC Semdev2015
Knowledge of Javascript
Caerusone
Jugar Introduccion a Scala
Oscon keynote: Working hard to keep it simple
Intro to Scala.js - Scala UG Cologne
Crossing the Bridge: Connecting Rails and your Front-end Framework
Adding geospatial features to a java web app
Modern, Scalable, Ambitious apps with Ember.js
Introduction To Scala
What did you miss in Java from 9-13?
Debugging Your Ext JS Code
Aop clustering
Coding Your Way to Java 13
Real life-coffeescript
Ad

Recently uploaded (20)

PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PDF
gpt5_lecture_notes_comprehensive_20250812015547.pdf
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PDF
Spectral efficient network and resource selection model in 5G networks
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
Approach and Philosophy of On baking technology
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
PDF
Electronic commerce courselecture one. Pdf
PDF
Unlocking AI with Model Context Protocol (MCP)
PDF
Network Security Unit 5.pdf for BCA BBA.
PPTX
Programs and apps: productivity, graphics, security and other tools
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PPTX
MYSQL Presentation for SQL database connectivity
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PDF
Chapter 3 Spatial Domain Image Processing.pdf
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
gpt5_lecture_notes_comprehensive_20250812015547.pdf
Reach Out and Touch Someone: Haptics and Empathic Computing
20250228 LYD VKU AI Blended-Learning.pptx
Per capita expenditure prediction using model stacking based on satellite ima...
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Spectral efficient network and resource selection model in 5G networks
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
Approach and Philosophy of On baking technology
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
Electronic commerce courselecture one. Pdf
Unlocking AI with Model Context Protocol (MCP)
Network Security Unit 5.pdf for BCA BBA.
Programs and apps: productivity, graphics, security and other tools
Digital-Transformation-Roadmap-for-Companies.pptx
MYSQL Presentation for SQL database connectivity
Diabetes mellitus diagnosis method based random forest with bat algorithm
Chapter 3 Spatial Domain Image Processing.pdf
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows

Turning Ideas Into Code Faster