SlideShare a Scribd company logo
Write => Cleaner, Maintainable & Testable{ Code } in Android with Model View View-Model (MVVM) YOW Connected 2014Adil MughalSenior Developer @ Nintex
What to Expect Today? 
•What you must already know? 
–Android Development 
–Knowledge of patterns like MVC, MVP, MVVM 
•What you will see? 
–How to implement MVVM in Android 
–HOW than WHY 
•RoboBinding 
•Java PropertyChangeListeners
The App
Traditional Way
The Challenges 
•Complex Activities 
–UI Logic 
–GUI Widgets contains state of UI 
–Communication with outside world 
•Poor Testability 
–Testing UI state and Behavior becomes challenging
The MVVM Way
MVVM Quick Intro 
Model 
ViewModel 
View 
Data-Binding 
Listeners 
XML + Activity 
Presentation Logic 
Business/Data 
The objective here is to pull out the state and behavior of the view into a class 
-State + Behavior 
-Interaction with Business/External 
-Maps ViewModelto actual UI widgets
The MVVM Way
The Benefits 
•View is just UI 
–Activities/View will just do real UI stuff 
–Maps the state/behavior to UI Widgets 
•Improved testability 
–Having POJO ViewModelhelp testing/mocking easy 
–Easily test UI logic as simple JUnittest 
•Relatively easy to follow SOLID principles 
–Single Responsility, Dependency Injection in ViewModeletc.
Any Questions?
Questions? Thank YOU for your time and attention! 
Adil Ahmed Mughal 
@adilamughal 
http://www.adilmughal.com 
adil.mughal@live.com 
http://adilmughal.github.io/YOW2014-Android-MVVM/
Ad

More Related Content

What's hot (20)

AngularJS – What, Why, Advantages and Disadvantages
AngularJS – What, Why, Advantages and DisadvantagesAngularJS – What, Why, Advantages and Disadvantages
AngularJS – What, Why, Advantages and Disadvantages
karenmsmith0504
 
Angular 5,6,7
Angular 5,6,7Angular 5,6,7
Angular 5,6,7
snehalkamble29
 
How do you get your idea into the app store?
How do you get your idea into the app store?How do you get your idea into the app store?
How do you get your idea into the app store?
Gabe Kwakyi
 
Introduction To Model View Presenter
Introduction To Model View PresenterIntroduction To Model View Presenter
Introduction To Model View Presenter
saeed shargi ghazani
 
Angularjs 5,6,7
Angularjs 5,6,7Angularjs 5,6,7
Angularjs 5,6,7
ankitarasal
 
MVVM in iOS presentation
MVVM in iOS presentationMVVM in iOS presentation
MVVM in iOS presentation
G ABHISEK
 
Model View Presenter (MVP) In Aspnet
Model View Presenter (MVP) In AspnetModel View Presenter (MVP) In Aspnet
Model View Presenter (MVP) In Aspnet
rainynovember12
 
Ecommerce Mini Project / Group Project Coding
Ecommerce Mini Project / Group Project CodingEcommerce Mini Project / Group Project Coding
Ecommerce Mini Project / Group Project Coding
Hemant Sarthak
 
Automation Testing Using WebDriver
Automation Testing Using WebDriverAutomation Testing Using WebDriver
Automation Testing Using WebDriver
Evozon Test Lab
 
Angular js training institute
Angular js training instituteAngular js training institute
Angular js training institute
nihalsingh113
 
Mvp pattern
Mvp patternMvp pattern
Mvp pattern
Khuong Vo
 
Angular Js
Angular JsAngular Js
Angular Js
Knoldus Inc.
 
No brainer
No brainerNo brainer
No brainer
Tanzim Saqib
 
9 reasons why angular js web development should be your choice in 2020
9 reasons why angular js web development should be your choice in 20209 reasons why angular js web development should be your choice in 2020
9 reasons why angular js web development should be your choice in 2020
Biztech Consulting & Solutions
 
Automated Unit Testing in Silverlight for Windows Phone 7
Automated Unit Testing in Silverlight for Windows Phone 7Automated Unit Testing in Silverlight for Windows Phone 7
Automated Unit Testing in Silverlight for Windows Phone 7
Jacinto Limjap
 
Building databound JavaScript apps with Knockoutjs
Building databound JavaScript apps with KnockoutjsBuilding databound JavaScript apps with Knockoutjs
Building databound JavaScript apps with Knockoutjs
Nish Anil
 
Creating MVC Application with backbone js
Creating MVC Application with backbone jsCreating MVC Application with backbone js
Creating MVC Application with backbone js
Mindfire Solutions
 
Live Cycle ES2 News From Adobe MAX
Live Cycle ES2 News From Adobe MAXLive Cycle ES2 News From Adobe MAX
Live Cycle ES2 News From Adobe MAX
Matthias Zeller
 
Test automation, agile testing; dev ops summit hyderabad Bdd with cucumber
Test automation, agile testing; dev ops summit hyderabad Bdd with cucumberTest automation, agile testing; dev ops summit hyderabad Bdd with cucumber
Test automation, agile testing; dev ops summit hyderabad Bdd with cucumber
Dharmender Srivastav
 
Initiation to AngularJS
Initiation to AngularJSInitiation to AngularJS
Initiation to AngularJS
Ahmed Elmehri
 
AngularJS – What, Why, Advantages and Disadvantages
AngularJS – What, Why, Advantages and DisadvantagesAngularJS – What, Why, Advantages and Disadvantages
AngularJS – What, Why, Advantages and Disadvantages
karenmsmith0504
 
How do you get your idea into the app store?
How do you get your idea into the app store?How do you get your idea into the app store?
How do you get your idea into the app store?
Gabe Kwakyi
 
Introduction To Model View Presenter
Introduction To Model View PresenterIntroduction To Model View Presenter
Introduction To Model View Presenter
saeed shargi ghazani
 
MVVM in iOS presentation
MVVM in iOS presentationMVVM in iOS presentation
MVVM in iOS presentation
G ABHISEK
 
Model View Presenter (MVP) In Aspnet
Model View Presenter (MVP) In AspnetModel View Presenter (MVP) In Aspnet
Model View Presenter (MVP) In Aspnet
rainynovember12
 
Ecommerce Mini Project / Group Project Coding
Ecommerce Mini Project / Group Project CodingEcommerce Mini Project / Group Project Coding
Ecommerce Mini Project / Group Project Coding
Hemant Sarthak
 
Automation Testing Using WebDriver
Automation Testing Using WebDriverAutomation Testing Using WebDriver
Automation Testing Using WebDriver
Evozon Test Lab
 
Angular js training institute
Angular js training instituteAngular js training institute
Angular js training institute
nihalsingh113
 
9 reasons why angular js web development should be your choice in 2020
9 reasons why angular js web development should be your choice in 20209 reasons why angular js web development should be your choice in 2020
9 reasons why angular js web development should be your choice in 2020
Biztech Consulting & Solutions
 
Automated Unit Testing in Silverlight for Windows Phone 7
Automated Unit Testing in Silverlight for Windows Phone 7Automated Unit Testing in Silverlight for Windows Phone 7
Automated Unit Testing in Silverlight for Windows Phone 7
Jacinto Limjap
 
Building databound JavaScript apps with Knockoutjs
Building databound JavaScript apps with KnockoutjsBuilding databound JavaScript apps with Knockoutjs
Building databound JavaScript apps with Knockoutjs
Nish Anil
 
Creating MVC Application with backbone js
Creating MVC Application with backbone jsCreating MVC Application with backbone js
Creating MVC Application with backbone js
Mindfire Solutions
 
Live Cycle ES2 News From Adobe MAX
Live Cycle ES2 News From Adobe MAXLive Cycle ES2 News From Adobe MAX
Live Cycle ES2 News From Adobe MAX
Matthias Zeller
 
Test automation, agile testing; dev ops summit hyderabad Bdd with cucumber
Test automation, agile testing; dev ops summit hyderabad Bdd with cucumberTest automation, agile testing; dev ops summit hyderabad Bdd with cucumber
Test automation, agile testing; dev ops summit hyderabad Bdd with cucumber
Dharmender Srivastav
 
Initiation to AngularJS
Initiation to AngularJSInitiation to AngularJS
Initiation to AngularJS
Ahmed Elmehri
 

Viewers also liked (20)

Quality Assurance in SDLC
Quality Assurance in SDLCQuality Assurance in SDLC
Quality Assurance in SDLC
Adil Mughal
 
20 Game Ideas You Should Steal
20 Game Ideas You Should Steal20 Game Ideas You Should Steal
20 Game Ideas You Should Steal
Stuart Dredge
 
More Android UIs
More Android UIsMore Android UIs
More Android UIs
DENNIS JUNG
 
Android Code Puzzles (DroidCon Amsterdam 2012)
Android Code Puzzles (DroidCon Amsterdam 2012)Android Code Puzzles (DroidCon Amsterdam 2012)
Android Code Puzzles (DroidCon Amsterdam 2012)
Danny Preussler
 
Infinum Android Talks #09 - UI optimization
Infinum Android Talks #09 - UI optimization Infinum Android Talks #09 - UI optimization
Infinum Android Talks #09 - UI optimization
Infinum
 
Android UI Tips, Tricks and Techniques
Android UI Tips, Tricks and TechniquesAndroid UI Tips, Tricks and Techniques
Android UI Tips, Tricks and Techniques
Marakana Inc.
 
Tech Talk #2: Android app performance tips
Tech Talk #2: Android app performance tipsTech Talk #2: Android app performance tips
Tech Talk #2: Android app performance tips
Nexus FrontierTech
 
7 stages of unit testing
7 stages of unit testing7 stages of unit testing
7 stages of unit testing
Jorge Ortiz
 
Recyclerview in action
Recyclerview in action Recyclerview in action
Recyclerview in action
Pratama Nur Wijaya
 
Mastering RecyclerView Layouts
Mastering RecyclerView LayoutsMastering RecyclerView Layouts
Mastering RecyclerView Layouts
Dave Smith
 
DevNext - Web Programming Concepts Using Asp Net
DevNext - Web Programming Concepts Using Asp NetDevNext - Web Programming Concepts Using Asp Net
DevNext - Web Programming Concepts Using Asp Net
Adil Mughal
 
Windows 7 For Geeks
Windows 7 For GeeksWindows 7 For Geeks
Windows 7 For Geeks
Adil Mughal
 
Community Contribution Experience
Community Contribution ExperienceCommunity Contribution Experience
Community Contribution Experience
Adil Mughal
 
What's New in Visual Studio 2010
What's New in Visual Studio 2010What's New in Visual Studio 2010
What's New in Visual Studio 2010
Adil Mughal
 
Testable Android Apps DroidCon Italy 2015
Testable Android Apps DroidCon Italy 2015Testable Android Apps DroidCon Italy 2015
Testable Android Apps DroidCon Italy 2015
Fabio Collini
 
Android Wear CodeLab - GDG Firenze
Android Wear CodeLab - GDG FirenzeAndroid Wear CodeLab - GDG Firenze
Android Wear CodeLab - GDG Firenze
Fabio Collini
 
Testable Android Apps using data binding and MVVM
Testable Android Apps using data binding and MVVMTestable Android Apps using data binding and MVVM
Testable Android Apps using data binding and MVVM
Fabio Collini
 
Introduction to Retrofit and RxJava
Introduction to Retrofit and RxJavaIntroduction to Retrofit and RxJava
Introduction to Retrofit and RxJava
Fabio Collini
 
Android Data Binding in action using MVVM pattern - droidconUK
Android Data Binding in action using MVVM pattern - droidconUKAndroid Data Binding in action using MVVM pattern - droidconUK
Android Data Binding in action using MVVM pattern - droidconUK
Fabio Collini
 
Data Binding in Action using MVVM pattern
Data Binding in Action using MVVM patternData Binding in Action using MVVM pattern
Data Binding in Action using MVVM pattern
Fabio Collini
 
Quality Assurance in SDLC
Quality Assurance in SDLCQuality Assurance in SDLC
Quality Assurance in SDLC
Adil Mughal
 
20 Game Ideas You Should Steal
20 Game Ideas You Should Steal20 Game Ideas You Should Steal
20 Game Ideas You Should Steal
Stuart Dredge
 
More Android UIs
More Android UIsMore Android UIs
More Android UIs
DENNIS JUNG
 
Android Code Puzzles (DroidCon Amsterdam 2012)
Android Code Puzzles (DroidCon Amsterdam 2012)Android Code Puzzles (DroidCon Amsterdam 2012)
Android Code Puzzles (DroidCon Amsterdam 2012)
Danny Preussler
 
Infinum Android Talks #09 - UI optimization
Infinum Android Talks #09 - UI optimization Infinum Android Talks #09 - UI optimization
Infinum Android Talks #09 - UI optimization
Infinum
 
Android UI Tips, Tricks and Techniques
Android UI Tips, Tricks and TechniquesAndroid UI Tips, Tricks and Techniques
Android UI Tips, Tricks and Techniques
Marakana Inc.
 
Tech Talk #2: Android app performance tips
Tech Talk #2: Android app performance tipsTech Talk #2: Android app performance tips
Tech Talk #2: Android app performance tips
Nexus FrontierTech
 
7 stages of unit testing
7 stages of unit testing7 stages of unit testing
7 stages of unit testing
Jorge Ortiz
 
Mastering RecyclerView Layouts
Mastering RecyclerView LayoutsMastering RecyclerView Layouts
Mastering RecyclerView Layouts
Dave Smith
 
DevNext - Web Programming Concepts Using Asp Net
DevNext - Web Programming Concepts Using Asp NetDevNext - Web Programming Concepts Using Asp Net
DevNext - Web Programming Concepts Using Asp Net
Adil Mughal
 
Windows 7 For Geeks
Windows 7 For GeeksWindows 7 For Geeks
Windows 7 For Geeks
Adil Mughal
 
Community Contribution Experience
Community Contribution ExperienceCommunity Contribution Experience
Community Contribution Experience
Adil Mughal
 
What's New in Visual Studio 2010
What's New in Visual Studio 2010What's New in Visual Studio 2010
What's New in Visual Studio 2010
Adil Mughal
 
Testable Android Apps DroidCon Italy 2015
Testable Android Apps DroidCon Italy 2015Testable Android Apps DroidCon Italy 2015
Testable Android Apps DroidCon Italy 2015
Fabio Collini
 
Android Wear CodeLab - GDG Firenze
Android Wear CodeLab - GDG FirenzeAndroid Wear CodeLab - GDG Firenze
Android Wear CodeLab - GDG Firenze
Fabio Collini
 
Testable Android Apps using data binding and MVVM
Testable Android Apps using data binding and MVVMTestable Android Apps using data binding and MVVM
Testable Android Apps using data binding and MVVM
Fabio Collini
 
Introduction to Retrofit and RxJava
Introduction to Retrofit and RxJavaIntroduction to Retrofit and RxJava
Introduction to Retrofit and RxJava
Fabio Collini
 
Android Data Binding in action using MVVM pattern - droidconUK
Android Data Binding in action using MVVM pattern - droidconUKAndroid Data Binding in action using MVVM pattern - droidconUK
Android Data Binding in action using MVVM pattern - droidconUK
Fabio Collini
 
Data Binding in Action using MVVM pattern
Data Binding in Action using MVVM patternData Binding in Action using MVVM pattern
Data Binding in Action using MVVM pattern
Fabio Collini
 
Ad

Similar to Write cleaner, maintainable, and testable code in Android with MVVM (20)

"iOS: MVVMC" - Aleksandr Nikolajev from Mooncascade
"iOS: MVVMC" - Aleksandr Nikolajev from Mooncascade"iOS: MVVMC" - Aleksandr Nikolajev from Mooncascade
"iOS: MVVMC" - Aleksandr Nikolajev from Mooncascade
MobileMonday Estonia
 
Adopting MVVM
Adopting MVVMAdopting MVVM
Adopting MVVM
John Cumming
 
MVP Clean Architecture
MVP Clean  Architecture MVP Clean  Architecture
MVP Clean Architecture
Himanshu Dudhat
 
Knockout js
Knockout jsKnockout js
Knockout js
Dr. Awase Khirni Syed
 
MVVM with DataBinding on android
MVVM with DataBinding on androidMVVM with DataBinding on android
MVVM with DataBinding on android
Rodrigo Bressan
 
Angular JS - Introduction
Angular JS - IntroductionAngular JS - Introduction
Angular JS - Introduction
Sagar Acharya
 
Angular JS, A dive to concepts
Angular JS, A dive to conceptsAngular JS, A dive to concepts
Angular JS, A dive to concepts
Abhishek Sur
 
Introduction To MVVM
Introduction To MVVMIntroduction To MVVM
Introduction To MVVM
Boulos Dib
 
Mvvm
MvvmMvvm
Mvvm
Rajeev Ranjan Singh
 
MVVM ( Model View ViewModel )
MVVM ( Model View ViewModel )MVVM ( Model View ViewModel )
MVVM ( Model View ViewModel )
Ahmed Emad
 
A Smooth Transition to HTML5
A Smooth Transition to HTML5A Smooth Transition to HTML5
A Smooth Transition to HTML5
Chris Bannon
 
Model View Presenter
Model View Presenter Model View Presenter
Model View Presenter
rendra toro
 
Ramesh Elangovan
Ramesh ElangovanRamesh Elangovan
Ramesh Elangovan
Ramesh Elangovan
 
A Smooth Transition to HTML5 Using MVVM
A Smooth Transition to HTML5 Using MVVMA Smooth Transition to HTML5 Using MVVM
A Smooth Transition to HTML5 Using MVVM
Chris Bannon
 
Models used in iOS programming, with a focus on MVVM
Models used in iOS programming, with a focus on MVVMModels used in iOS programming, with a focus on MVVM
Models used in iOS programming, with a focus on MVVM
Andrei Popa
 
Rendra Toro - Model View Presenter
Rendra Toro - Model View PresenterRendra Toro - Model View Presenter
Rendra Toro - Model View Presenter
Dicoding
 
MVC 1.0 / JSR 371
MVC 1.0 / JSR 371MVC 1.0 / JSR 371
MVC 1.0 / JSR 371
David Delabassee
 
Angularjs y Simple Page Applications
Angularjs y Simple Page Applications Angularjs y Simple Page Applications
Angularjs y Simple Page Applications
johnpisg
 
Good bye Massive View Controller!
Good bye Massive View Controller!Good bye Massive View Controller!
Good bye Massive View Controller!
Supercharge
 
Training: MVVM Pattern
Training: MVVM PatternTraining: MVVM Pattern
Training: MVVM Pattern
Betclic Everest Group Tech Team
 
"iOS: MVVMC" - Aleksandr Nikolajev from Mooncascade
"iOS: MVVMC" - Aleksandr Nikolajev from Mooncascade"iOS: MVVMC" - Aleksandr Nikolajev from Mooncascade
"iOS: MVVMC" - Aleksandr Nikolajev from Mooncascade
MobileMonday Estonia
 
MVVM with DataBinding on android
MVVM with DataBinding on androidMVVM with DataBinding on android
MVVM with DataBinding on android
Rodrigo Bressan
 
Angular JS - Introduction
Angular JS - IntroductionAngular JS - Introduction
Angular JS - Introduction
Sagar Acharya
 
Angular JS, A dive to concepts
Angular JS, A dive to conceptsAngular JS, A dive to concepts
Angular JS, A dive to concepts
Abhishek Sur
 
Introduction To MVVM
Introduction To MVVMIntroduction To MVVM
Introduction To MVVM
Boulos Dib
 
MVVM ( Model View ViewModel )
MVVM ( Model View ViewModel )MVVM ( Model View ViewModel )
MVVM ( Model View ViewModel )
Ahmed Emad
 
A Smooth Transition to HTML5
A Smooth Transition to HTML5A Smooth Transition to HTML5
A Smooth Transition to HTML5
Chris Bannon
 
Model View Presenter
Model View Presenter Model View Presenter
Model View Presenter
rendra toro
 
A Smooth Transition to HTML5 Using MVVM
A Smooth Transition to HTML5 Using MVVMA Smooth Transition to HTML5 Using MVVM
A Smooth Transition to HTML5 Using MVVM
Chris Bannon
 
Models used in iOS programming, with a focus on MVVM
Models used in iOS programming, with a focus on MVVMModels used in iOS programming, with a focus on MVVM
Models used in iOS programming, with a focus on MVVM
Andrei Popa
 
Rendra Toro - Model View Presenter
Rendra Toro - Model View PresenterRendra Toro - Model View Presenter
Rendra Toro - Model View Presenter
Dicoding
 
Angularjs y Simple Page Applications
Angularjs y Simple Page Applications Angularjs y Simple Page Applications
Angularjs y Simple Page Applications
johnpisg
 
Good bye Massive View Controller!
Good bye Massive View Controller!Good bye Massive View Controller!
Good bye Massive View Controller!
Supercharge
 
Ad

Recently uploaded (20)

Solidworks Crack 2025 latest new + license code
Solidworks Crack 2025 latest new + license codeSolidworks Crack 2025 latest new + license code
Solidworks Crack 2025 latest new + license code
aneelaramzan63
 
Revolutionizing Residential Wi-Fi PPT.pptx
Revolutionizing Residential Wi-Fi PPT.pptxRevolutionizing Residential Wi-Fi PPT.pptx
Revolutionizing Residential Wi-Fi PPT.pptx
nidhisingh691197
 
What Do Contribution Guidelines Say About Software Testing? (MSR 2025)
What Do Contribution Guidelines Say About Software Testing? (MSR 2025)What Do Contribution Guidelines Say About Software Testing? (MSR 2025)
What Do Contribution Guidelines Say About Software Testing? (MSR 2025)
Andre Hora
 
Exceptional Behaviors: How Frequently Are They Tested? (AST 2025)
Exceptional Behaviors: How Frequently Are They Tested? (AST 2025)Exceptional Behaviors: How Frequently Are They Tested? (AST 2025)
Exceptional Behaviors: How Frequently Are They Tested? (AST 2025)
Andre Hora
 
Societal challenges of AI: biases, multilinguism and sustainability
Societal challenges of AI: biases, multilinguism and sustainabilitySocietal challenges of AI: biases, multilinguism and sustainability
Societal challenges of AI: biases, multilinguism and sustainability
Jordi Cabot
 
Landscape of Requirements Engineering for/by AI through Literature Review
Landscape of Requirements Engineering for/by AI through Literature ReviewLandscape of Requirements Engineering for/by AI through Literature Review
Landscape of Requirements Engineering for/by AI through Literature Review
Hironori Washizaki
 
Download Wondershare Filmora Crack [2025] With Latest
Download Wondershare Filmora Crack [2025] With LatestDownload Wondershare Filmora Crack [2025] With Latest
Download Wondershare Filmora Crack [2025] With Latest
tahirabibi60507
 
Adobe Illustrator Crack | Free Download & Install Illustrator
Adobe Illustrator Crack | Free Download & Install IllustratorAdobe Illustrator Crack | Free Download & Install Illustrator
Adobe Illustrator Crack | Free Download & Install Illustrator
usmanhidray
 
Adobe Marketo Engage Champion Deep Dive - SFDC CRM Synch V2 & Usage Dashboards
Adobe Marketo Engage Champion Deep Dive - SFDC CRM Synch V2 & Usage DashboardsAdobe Marketo Engage Champion Deep Dive - SFDC CRM Synch V2 & Usage Dashboards
Adobe Marketo Engage Champion Deep Dive - SFDC CRM Synch V2 & Usage Dashboards
BradBedford3
 
Adobe Illustrator Crack FREE Download 2025 Latest Version
Adobe Illustrator Crack FREE Download 2025 Latest VersionAdobe Illustrator Crack FREE Download 2025 Latest Version
Adobe Illustrator Crack FREE Download 2025 Latest Version
kashifyounis067
 
Microsoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdf
Microsoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdfMicrosoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdf
Microsoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdf
TechSoup
 
FL Studio Producer Edition Crack 2025 Full Version
FL Studio Producer Edition Crack 2025 Full VersionFL Studio Producer Edition Crack 2025 Full Version
FL Studio Producer Edition Crack 2025 Full Version
tahirabibi60507
 
Minitab 22 Full Crack Plus Product Key Free Download [Latest] 2025
Minitab 22 Full Crack Plus Product Key Free Download [Latest] 2025Minitab 22 Full Crack Plus Product Key Free Download [Latest] 2025
Minitab 22 Full Crack Plus Product Key Free Download [Latest] 2025
wareshashahzadiii
 
Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.
Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.
Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.
Dele Amefo
 
Shift Left using Lean for Agile Software Development
Shift Left using Lean for Agile Software DevelopmentShift Left using Lean for Agile Software Development
Shift Left using Lean for Agile Software Development
SathyaShankar6
 
PDF Reader Pro Crack Latest Version FREE Download 2025
PDF Reader Pro Crack Latest Version FREE Download 2025PDF Reader Pro Crack Latest Version FREE Download 2025
PDF Reader Pro Crack Latest Version FREE Download 2025
mu394968
 
Scaling GraphRAG: Efficient Knowledge Retrieval for Enterprise AI
Scaling GraphRAG:  Efficient Knowledge Retrieval for Enterprise AIScaling GraphRAG:  Efficient Knowledge Retrieval for Enterprise AI
Scaling GraphRAG: Efficient Knowledge Retrieval for Enterprise AI
danshalev
 
Avast Premium Security Crack FREE Latest Version 2025
Avast Premium Security Crack FREE Latest Version 2025Avast Premium Security Crack FREE Latest Version 2025
Avast Premium Security Crack FREE Latest Version 2025
mu394968
 
EASEUS Partition Master Crack + License Code
EASEUS Partition Master Crack + License CodeEASEUS Partition Master Crack + License Code
EASEUS Partition Master Crack + License Code
aneelaramzan63
 
Mastering OOP: Understanding the Four Core Pillars
Mastering OOP: Understanding the Four Core PillarsMastering OOP: Understanding the Four Core Pillars
Mastering OOP: Understanding the Four Core Pillars
Marcel David
 
Solidworks Crack 2025 latest new + license code
Solidworks Crack 2025 latest new + license codeSolidworks Crack 2025 latest new + license code
Solidworks Crack 2025 latest new + license code
aneelaramzan63
 
Revolutionizing Residential Wi-Fi PPT.pptx
Revolutionizing Residential Wi-Fi PPT.pptxRevolutionizing Residential Wi-Fi PPT.pptx
Revolutionizing Residential Wi-Fi PPT.pptx
nidhisingh691197
 
What Do Contribution Guidelines Say About Software Testing? (MSR 2025)
What Do Contribution Guidelines Say About Software Testing? (MSR 2025)What Do Contribution Guidelines Say About Software Testing? (MSR 2025)
What Do Contribution Guidelines Say About Software Testing? (MSR 2025)
Andre Hora
 
Exceptional Behaviors: How Frequently Are They Tested? (AST 2025)
Exceptional Behaviors: How Frequently Are They Tested? (AST 2025)Exceptional Behaviors: How Frequently Are They Tested? (AST 2025)
Exceptional Behaviors: How Frequently Are They Tested? (AST 2025)
Andre Hora
 
Societal challenges of AI: biases, multilinguism and sustainability
Societal challenges of AI: biases, multilinguism and sustainabilitySocietal challenges of AI: biases, multilinguism and sustainability
Societal challenges of AI: biases, multilinguism and sustainability
Jordi Cabot
 
Landscape of Requirements Engineering for/by AI through Literature Review
Landscape of Requirements Engineering for/by AI through Literature ReviewLandscape of Requirements Engineering for/by AI through Literature Review
Landscape of Requirements Engineering for/by AI through Literature Review
Hironori Washizaki
 
Download Wondershare Filmora Crack [2025] With Latest
Download Wondershare Filmora Crack [2025] With LatestDownload Wondershare Filmora Crack [2025] With Latest
Download Wondershare Filmora Crack [2025] With Latest
tahirabibi60507
 
Adobe Illustrator Crack | Free Download & Install Illustrator
Adobe Illustrator Crack | Free Download & Install IllustratorAdobe Illustrator Crack | Free Download & Install Illustrator
Adobe Illustrator Crack | Free Download & Install Illustrator
usmanhidray
 
Adobe Marketo Engage Champion Deep Dive - SFDC CRM Synch V2 & Usage Dashboards
Adobe Marketo Engage Champion Deep Dive - SFDC CRM Synch V2 & Usage DashboardsAdobe Marketo Engage Champion Deep Dive - SFDC CRM Synch V2 & Usage Dashboards
Adobe Marketo Engage Champion Deep Dive - SFDC CRM Synch V2 & Usage Dashboards
BradBedford3
 
Adobe Illustrator Crack FREE Download 2025 Latest Version
Adobe Illustrator Crack FREE Download 2025 Latest VersionAdobe Illustrator Crack FREE Download 2025 Latest Version
Adobe Illustrator Crack FREE Download 2025 Latest Version
kashifyounis067
 
Microsoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdf
Microsoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdfMicrosoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdf
Microsoft AI Nonprofit Use Cases and Live Demo_2025.04.30.pdf
TechSoup
 
FL Studio Producer Edition Crack 2025 Full Version
FL Studio Producer Edition Crack 2025 Full VersionFL Studio Producer Edition Crack 2025 Full Version
FL Studio Producer Edition Crack 2025 Full Version
tahirabibi60507
 
Minitab 22 Full Crack Plus Product Key Free Download [Latest] 2025
Minitab 22 Full Crack Plus Product Key Free Download [Latest] 2025Minitab 22 Full Crack Plus Product Key Free Download [Latest] 2025
Minitab 22 Full Crack Plus Product Key Free Download [Latest] 2025
wareshashahzadiii
 
Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.
Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.
Salesforce Data Cloud- Hyperscale data platform, built for Salesforce.
Dele Amefo
 
Shift Left using Lean for Agile Software Development
Shift Left using Lean for Agile Software DevelopmentShift Left using Lean for Agile Software Development
Shift Left using Lean for Agile Software Development
SathyaShankar6
 
PDF Reader Pro Crack Latest Version FREE Download 2025
PDF Reader Pro Crack Latest Version FREE Download 2025PDF Reader Pro Crack Latest Version FREE Download 2025
PDF Reader Pro Crack Latest Version FREE Download 2025
mu394968
 
Scaling GraphRAG: Efficient Knowledge Retrieval for Enterprise AI
Scaling GraphRAG:  Efficient Knowledge Retrieval for Enterprise AIScaling GraphRAG:  Efficient Knowledge Retrieval for Enterprise AI
Scaling GraphRAG: Efficient Knowledge Retrieval for Enterprise AI
danshalev
 
Avast Premium Security Crack FREE Latest Version 2025
Avast Premium Security Crack FREE Latest Version 2025Avast Premium Security Crack FREE Latest Version 2025
Avast Premium Security Crack FREE Latest Version 2025
mu394968
 
EASEUS Partition Master Crack + License Code
EASEUS Partition Master Crack + License CodeEASEUS Partition Master Crack + License Code
EASEUS Partition Master Crack + License Code
aneelaramzan63
 
Mastering OOP: Understanding the Four Core Pillars
Mastering OOP: Understanding the Four Core PillarsMastering OOP: Understanding the Four Core Pillars
Mastering OOP: Understanding the Four Core Pillars
Marcel David
 

Write cleaner, maintainable, and testable code in Android with MVVM

  • 1. Write => Cleaner, Maintainable & Testable{ Code } in Android with Model View View-Model (MVVM) YOW Connected 2014Adil MughalSenior Developer @ Nintex
  • 2. What to Expect Today? •What you must already know? –Android Development –Knowledge of patterns like MVC, MVP, MVVM •What you will see? –How to implement MVVM in Android –HOW than WHY •RoboBinding •Java PropertyChangeListeners
  • 5. The Challenges •Complex Activities –UI Logic –GUI Widgets contains state of UI –Communication with outside world •Poor Testability –Testing UI state and Behavior becomes challenging
  • 7. MVVM Quick Intro Model ViewModel View Data-Binding Listeners XML + Activity Presentation Logic Business/Data The objective here is to pull out the state and behavior of the view into a class -State + Behavior -Interaction with Business/External -Maps ViewModelto actual UI widgets
  • 9. The Benefits •View is just UI –Activities/View will just do real UI stuff –Maps the state/behavior to UI Widgets •Improved testability –Having POJO ViewModelhelp testing/mocking easy –Easily test UI logic as simple JUnittest •Relatively easy to follow SOLID principles –Single Responsility, Dependency Injection in ViewModeletc.
  • 11. Questions? Thank YOU for your time and attention! Adil Ahmed Mughal @adilamughal http://www.adilmughal.com [email protected] http://adilmughal.github.io/YOW2014-Android-MVVM/