I currently do a lot of WPF development and have started creating some basic Android apps. When creating WPF apps I often use MVVM, normally using Prism, and would like to know if there are any examples of MVVM for the Android platform?
相关问题
- Delete Messages from a Topic in Apache Kafka
- Jackson Deserialization not calling deserialize on
- How can I create this custom Bottom Navigation on
- How to maintain order of key-value in DataFrame sa
- StackExchange API - Deserialize Date in JSON Respo
There is a relatively new framework being developed that allows for Views to be bound to ViewModels called android-binding. Using this framework and RoboGuice you can get your MVVM on. The framework still needs some work, but it's a good starting point.
Just to post as a reference to other people who may be interested. I am a contributor to RoboBinding - A data-binding Presentation Model framework for the Android platform. It is another framework for the same purpose. Apart from helping with project structure, one major focus for RoboBinding is to make testing android apps with normal JUnit tests possible instead of Android unit tests, as Unit tests are so important to guarantee the quality of projects, but Android unit tests take ages to run and make unit tests somewhat impractical. RoboBinding itself comes with more than 300 JUnit tests to ensure its quality. MVVM originated from Microsoft as a specialization of the Presentation Model design pattern introduced by Martin Fowler. Other alternatives: Android-Binding, Bindroid and MvvmCross.