Create cross platform mobile apps in Java with the Multi-OS Engine. This is a presentation by Gergely Kis at the Darwino Workshop November 2016, in Cologne, Germany
1. MIGERAN - SMART SOFTWARE SOLUTIONS
MIGERAN
MOE: CROSS PLATFORM
MOBILE APPS IN JAVA
An Introduction to the Multi-OS Engine
Dr. Annamária Mattasits
CEO / Co-Founder
Gergely Kis
CTO / Co-Founder
2. MIGERAN - SMART SOFTWARE SOLUTIONS
ABOUT MIGERAN
• In 2013 we started the development of our first product
• Migeran for iOS: Create iOS Apps in Java
• Intel acquired Migeran for iOS in 2015
• Multi-OS Engine
• Migeran became Intel Development, Consulting & Training
Partner
• Intel open-sourced Multi-OS Engine in 2016
• Migeran is the Project Lead and Core Developer of MOE
2
3. MIGERAN - SMART SOFTWARE SOLUTIONS
ABOUT MIGERAN
• We started at Siemens - C65 and X75 generations
• Started our company in 2007
• Outsourced Software Development
• Diverse Projects
• Mobile App & Platform Development
• Android, iOS, BB10, BB Classic, J2ME
• Embedded Linux: C/C++, Asm on ARM, MIPS
• Web / Server: Java EE
• Built on Teleworking
Mobile Development since 2004
3
4. MIGERAN - SMART SOFTWARE SOLUTIONS
ABOUT MIGERAN
• Worked on V8 development for over 6 years
• Participated in all major rewrites since 2010
• First "Optimizing Compiler"
• Crankshaft
• TurboFan
• Ignite (the new interpreter)
Google V8 JavaScript Engine
4
Over 1100 Commits
5. MIGERAN - SMART SOFTWARE SOLUTIONS
THE MOBILE CHALLENGE
Deploy the same app on multiple platforms
5
Rewrite from Scratch Go Cross-Platform
6. MIGERAN - SMART SOFTWARE SOLUTIONS
OUR CHOICE: USE JAVA
• Most of our codebase was in Java
• J2ME, Classic BlackBerry, Android
• Java is native on Android
• We don't like reinventing the wheel...
• ... and debugging it all over again
• Native UI
• Customers did not like Cross-Platform UIs
• Great development tools
• Debugger, IDEs, Native API access, UI Designer
And design apps The Right WayTM
6
Business Logic (Model)
View Model
User Interface
Platform Dependent
Native View
7. MIGERAN - SMART SOFTWARE SOLUTIONS
MIGERAN FOR IOS
The Birth of MOE
7
Migeran for iOS
• Since 2009, we used XMLVM
• Migeran Development started in 2013
• Runtime based on Android ART
• Nat/J
• Java to native bindings with automated generator
• Full iOS API mapping
• Eclipse and later Android Studio / IDEA integration
• First public release at the end of 2014
• In 2015 Intel acquired Migeran for iOS
• Migeran became Intel Partner
8. MIGERAN - SMART SOFTWARE SOLUTIONS
MULTI-OS ENGINE
End to End Solution for Cross-Platform Java Development
8
Java runtime based on Android ART
Mac and Windows Host Support
with On Device Debugging
Nat/J Java to native bindings
with automated binding generator
100% Objective-C API Access
Use Xcode Storyboard Integration
with Eclipse / Android Studio / IntelliJ
100 %
Open Source
9. MIGERAN - SMART SOFTWARE SOLUTIONS
MIGERAN ANALYZER
Is your Android App Ready for iOS?
9
analyzer.migeran.com
10. MIGERAN - SMART SOFTWARE SOLUTIONS
MULTI-OS ENGINE
• Use any language
• JVM, C / C++, ObjC, Swift
• Your favorite tools
• AS / IDEA, Eclipse, Xcode
• Gradle, Maven builds
• JUnit
• CI servers (e.g. Jenkins)
• Debug native and Java code at the same time
MOE is Flexible
10
iOS
Android ART VM
Nat/J
Java Libraries
3rd Party
iOS
Libraries
iOS Java Bindings
Application Code (Java, Objective-C, Swift, C / C++)
11. MIGERAN - SMART SOFTWARE SOLUTIONS
NAT/J - JAVA TO NATIVE BINDING
• Java to native bindings defined using Java annotations
• C and Objective-C runtimes supported
• Manages Objective-C object lifecycle
• Dynamically links Java and native functions
• Automatic binding generator
• The full iOS API is automatically generated
• Bind Objective-C ViewController stubs to Java
• Generate bindings for 3rd party Objective-C and Swift libraries
• Works on any JNI compatible Java VM (Oracle, ART ...)
Never use JNI Again!
11
Created
by Migeran
12. MIGERAN - SMART SOFTWARE SOLUTIONS
ADVANCED JAVA & NATIVE INTEGRATION
• Use any JVM language (Scala, Kotlin, Clojure ... etc.)
• Use Java libraries from Objective-C / Swift
• Implement Objective-C protocols in Java
• Extend Objective-C classes in Java
• Build your UI in Java, Swift or Objective-C
• Automatically generate bindings with Nat/J
Use the tools best suited for the task
12
Java Class
Objective-C
Protocol
Objective-C
Class
<<extends>> <<implements>>
Native UI
Objective-C
Class
<<uses>>
13. MIGERAN - SMART SOFTWARE SOLUTIONS
XCODE STORYBOARD INTEGRATION
Design in Xcode, Develop in Java
13
Generated user interface
binding methods
14. MIGERAN - SMART SOFTWARE SOLUTIONS
MOE USE CASES
14
Port libGDX Games
to iOS
Port from Android
Darwino uses MOE on iOS
Migrate from RoboVM
Cross-Platform App
15. MIGERAN - SMART SOFTWARE SOLUTIONS
MOE ROADMAP
• 2016.08 MOE 1.0 - Initial Open Source Release
• 2016.09 MOE 1.1 - First Release by Migeran
• 2016.10 MOE 1.2 - Eclipse & Maven Support
• 2016.11 MOE 1.2.5 (released on 28.11.2016)
• 2016.12 MOE 1.3 beta 1
• 2017.01 MOE 2.0 alpha 1
• 2017.01 MOE 1.3 final
• 2017.Q1 MOE 2.0 beta
• 2017.H1 MOE 2.0 final
Exciting Times Ahead!
15
Migeran is
the Project Lead and
Core Developer of MOE
16. MIGERAN - SMART SOFTWARE SOLUTIONS
MOE ROADMAP
• Redesigned Xcode Project Layout
• Very flexible, minimal customization
• Tool to apply to any Xcode project
• Supports Xcode Workspaces, CocoaPods
• Redesigned Binding Generation
• Generate ObjC stubs from Java classes
• Generate Java code from ObjC classes
• Custom binding configurations
New Features in MOE 1.3
16
• Binding Projects
• Create and distribute bindings for
your native libraries
• MOE Standard Bindings Project
• Bindings for common libraries
• e.g. Google Play Services on iOS
• Contributions Welcome!
MOE ROADMAP
17. MIGERAN - SMART SOFTWARE SOLUTIONS
MOE ROADMAP
• Everything in MOE 1.3
• Drop-in replacement
• Upgrade to Android 7 (Nougat)
• Custom LLVM based ART backend
• Required for Bitcode Support
• Easier to port to other architectures
New Features in MOE 2.0
17
MOE ROADMAP
• Integration with Jack
• Required for Java 8 in Android 7
• Integrates ProGuard functionality
MOE 2.0 Alpha 1
is scheduled for 2017.01
18. MIGERAN - SMART SOFTWARE SOLUTIONS
MOE ROADMAP
• Linux as a Development Environment
• MacOS Desktop App Support
• Windows App Support
• ART needs to be ported to Windows
• Proof of Concept works
• Depends on MOE 2.x LLVM backend
More Exciting Features
18
Development driven by
Community Demand
19. MIGERAN - SMART SOFTWARE SOLUTIONS
MIGERAN SERVICES
• Outsourced Development Services
• Mobile App Development (Android, iOS)
• Java, C/C++, Objective-C, Swift, Python, Kotlin, JavaScript
• Custom System Development
• JavaEE Backend, Mobile and Web frontends, IoT devices
• MOE Support Services
• Technical Support with guaranteed SLA
• Live Support (Screen sharing with Migeran Engineers)
• Hot Fixes
• MOE Training
Smart Software Solutions
19
20. MIGERAN - SMART SOFTWARE SOLUTIONS
Q & A
Thank you for your attention!
20
TRAINING PREMIUM SUPPORT DEVELOPMENT
migeran.com
GET MULTI-OS ENGINE
multi-os-engine.org