groovy on android
DESCRIPTION
Recently Apple has introduced a new language - Swift. Many of us have already had an opportunity to work with it. Without any doubt Swift will be more popular than Objective-C. Unfortunately it is useful for iOS only. Do we have a viable alternative for Android? Yes, and it is called Groovy! During this meet-up Olexandr Leuschenko, cross-platform mobile developer: - tells what Groovy is; - shows the differences between Java, Swift and Groovy code; - talks about development with Groovy for Android in general. The presentation will be interesting for all Android developers.TRANSCRIPT
Groovy on Android
9 oct 2014
Agenda
1. What is Groovy?
2. Swift and Groovy
3. Groovy on Android
Agenda
1. What is Groovy?
2. Swift and Groovy
3. Groovy on Android
What Apple think
After Swift release
• Ruby devs: Swift looks like Ruby
• Groovy devs: Swift looks like Groovy
• C# devs: Swift looks like C#
• Java devs: WTH is a closure?
Groovy• Started in August 2003 (release 1.0 on January 2,
2007)
• Open Source (BSD/Apache licenses)
• Compiled to Java Bytecode
• Grammar similar to Java with inspiration from Python, Ruby and Smalltalk
• Extremely flat learning curve for the Java developers
Groovy
Java
Groovy features• Annotations for AST Transformation
(@InheritConstructors, @Singleton, @EqualsAndHashCode)
• Closure
• Metaprogramming (adding method to a class on the fly)
• Native JSON support
Groovy features
• ?. and *. operators
• Native support for Lists, Maps and Regular Expressions
• String interpolation
• Static and Dynamic typing
Groovy features
• ?. and *. operators
• Native support for Lists, Maps and Regular Expressions
• String interpolation
• Static and Dynamic typing
Agenda
1. What is Groovy?
2. Swift and Groovy
3. Groovy on Android
Groovy and Swift
Groovy and Swift
Groovy and Swift
Groovy and Swift
Groovy and Swift
Groovy and Swift
Groovy and Swift
Agenda
1. What is Groovy?
2. Swift and Groovy
3. Groovy on Android
Let’s code!
Q & A