Reaproveitando código 
entre plataformas com 
Xamarin e MVVM Cross 
How do we think 
Ricardo Dorta 
http://ricardodorta.net.br 
@dortaway
Ricardo Dorta 
http://ricardodorta.net.br 
@dortaway 
How do we think • Systems Expert in GFT Brazil 
• Microsoft Most Valuable Professional (MVP) C# 
• Microsoft Certified Professional 
• Microsoft Certified Application Developer 
• Microsoft Certified Solution Developer 
• Microsoft Certified Technology Specialist - Silverlight 
• São Paulino 
• Viciado em games 
• Nerd e Bonitão 
Our objective is to provide innovation 
to society. 
We work to shape trends and ideas using 
technology.
Cenário Comum
Xamarin... 
• Native User Interface 
• Native Performance 
• Shared code across platforms 
• C# Rocks!!!! 
• Full API Coveragehink 
How do we think 
Our objective is to provide innovation 
to society. 
We work to shape trends and ideas using 
technology. 
C# with Xamarin 
http://ricardodorta.net.br 
@dortaway 
Java
E agora Mister M? 
• A mágica é escrever apenas 1 
código que funcione em todas 
as plataformas 
• Mas como isso é possível? 
How do we think 
http://ricardodorta.net.br 
@dortaway
Mister M says: the magic is .... PCL!!! 
• Portable Class Library 
• 1 Assembly 
• Várias plataformas 
• Xamarin também!!! 
How do we think 
Our objective is to provide innovation 
to society. 
We work to shape trends and ideas using 
technology. 
•Xamarin.Android 
•Xamarin.iOS
MVVM (Model-View-ViewModel) 
• Criado em 2005 por John Grossman – 
Arquiteto do WPF e do Silverlight 
• Baseado no padrão MVC (Model-View- 
Controller) 
• Visa separação de UI(User Interface – 
VIEW), das camadas de negócio. 
• Facilita a introdução de testes 
Our objective is to provide innovation 
to society. 
We work to shape trends and ideas using 
technology. 
unitários 
• Model : Regras de negócio 
• View : UI (User Interface) 
• View model: Model da View, contém regras 
de interface e propriedades que são 
utilizadas pela interface para definir 
regras de layout. 
• w do we think 
http://ricardodorta.net.br 
@dortaway
• Criado por Stuart Lodge (@slodge) 
• Open-Source: 
(https://github.com/MvvmCross/MvvmCross) 
• Extensível via plug-ins 
• Mecanismo de injeção de dependência 
embutido 
• Vários plug-ins já desenvolvidos 
Our objective is to provide innovation 
to society. 
We work to shape trends and ideas using 
technology. 
(Messages, GPS, Camera ....) 
• Traz o modelo de binding para Android e 
IOS 
• Possibilidade de criação de bindings 
customizáveis (controles próprios) 
• w do we think 
MVVM Cross 
http://ricardodorta.net.br 
@dortaway
MVVM Cross 
Our objective is to provide innovation 
to society. 
We work to shape trends and ideas using 
technology. 
http://ricardodorta.net.br 
@dortaway
Acorda que chegou a hora do código!!! 
Momento… 
Awwnnnn 
http://ricardodorta.net.br 
@dortaway
Nuff said!!!! 
Demo – MVVM Cross – 
Windows Phone, Android 
e Windows Store 
http://ricardodorta.net.br 
@dortaway
Dúvidas? 
Brincadeira... Pergunta aí!!! http://ricardodorta.net.br 
@dortaway
How do we think 
Obrigado! 
Our objective is to provide innovation 
to society. 
We work to shape trends and ideas using 
technology. 
http://ricardodorta.net.br 
@dortaway

Reaproveitamento de código com Xamarin e MVVM Cross

  • 1.
    Reaproveitando código entreplataformas com Xamarin e MVVM Cross How do we think Ricardo Dorta http://ricardodorta.net.br @dortaway
  • 2.
    Ricardo Dorta http://ricardodorta.net.br @dortaway How do we think • Systems Expert in GFT Brazil • Microsoft Most Valuable Professional (MVP) C# • Microsoft Certified Professional • Microsoft Certified Application Developer • Microsoft Certified Solution Developer • Microsoft Certified Technology Specialist - Silverlight • São Paulino • Viciado em games • Nerd e Bonitão Our objective is to provide innovation to society. We work to shape trends and ideas using technology.
  • 3.
  • 4.
    Xamarin... • NativeUser Interface • Native Performance • Shared code across platforms • C# Rocks!!!! • Full API Coveragehink How do we think Our objective is to provide innovation to society. We work to shape trends and ideas using technology. C# with Xamarin http://ricardodorta.net.br @dortaway Java
  • 5.
    E agora MisterM? • A mágica é escrever apenas 1 código que funcione em todas as plataformas • Mas como isso é possível? How do we think http://ricardodorta.net.br @dortaway
  • 6.
    Mister M says:the magic is .... PCL!!! • Portable Class Library • 1 Assembly • Várias plataformas • Xamarin também!!! How do we think Our objective is to provide innovation to society. We work to shape trends and ideas using technology. •Xamarin.Android •Xamarin.iOS
  • 7.
    MVVM (Model-View-ViewModel) •Criado em 2005 por John Grossman – Arquiteto do WPF e do Silverlight • Baseado no padrão MVC (Model-View- Controller) • Visa separação de UI(User Interface – VIEW), das camadas de negócio. • Facilita a introdução de testes Our objective is to provide innovation to society. We work to shape trends and ideas using technology. unitários • Model : Regras de negócio • View : UI (User Interface) • View model: Model da View, contém regras de interface e propriedades que são utilizadas pela interface para definir regras de layout. • w do we think http://ricardodorta.net.br @dortaway
  • 8.
    • Criado porStuart Lodge (@slodge) • Open-Source: (https://github.com/MvvmCross/MvvmCross) • Extensível via plug-ins • Mecanismo de injeção de dependência embutido • Vários plug-ins já desenvolvidos Our objective is to provide innovation to society. We work to shape trends and ideas using technology. (Messages, GPS, Camera ....) • Traz o modelo de binding para Android e IOS • Possibilidade de criação de bindings customizáveis (controles próprios) • w do we think MVVM Cross http://ricardodorta.net.br @dortaway
  • 9.
    MVVM Cross Ourobjective is to provide innovation to society. We work to shape trends and ideas using technology. http://ricardodorta.net.br @dortaway
  • 10.
    Acorda que chegoua hora do código!!! Momento… Awwnnnn http://ricardodorta.net.br @dortaway
  • 11.
    Nuff said!!!! Demo– MVVM Cross – Windows Phone, Android e Windows Store http://ricardodorta.net.br @dortaway
  • 12.
    Dúvidas? Brincadeira... Perguntaaí!!! http://ricardodorta.net.br @dortaway
  • 13.
    How do wethink Obrigado! Our objective is to provide innovation to society. We work to shape trends and ideas using technology. http://ricardodorta.net.br @dortaway