Xamarin.Android Features
Presented below is the list of features which MugenMvvm provides to Xamarin.Android:
- Work with
Activityis supported. There are exists MugenMvvm implementation for each of standard AndroidActivity(name convention is 'Mvvm'+<activity's name>). In order to successfully work with MugenMvvm you must inherit appropriateMvvmimplementation ofActivity. For instance, if you would match aActivitywith a ViewModel, so after you callShowAsyncnavigation onActivityof this type will be made. - Work with
Fragmentis supported. There are exists MugenMvvm implementation for each of standard AndroidFragment(name convention is 'Mvvm'+<fragment's name>). In order to successfully work with MugenMvvm you must inherit appropriateMvvmimplementation ofFragment. For instance, if you would match aMvvmDialogFragmentwith a ViewModel, so after you callShowAsyncmethod instance will be shown. - State control for
ActivityandFragmentis supported. States of anyActivityorFragmentare tracked "behind the scene", therefore you haven't manually invoke methods for save/restore the state of ViewModel. - Back stack navigation is supported.
- Markup binding is supported. In order to use binding on Android one must add the next namepace in
xmlfile:
xmlns:pkg="http://schemas.android.com/apk/res-auto
After that Bind attribute is available to use in xml layout.
- Bindings for
ActionBar,Toolbar,PopupMenuandOptionsMenuare supported. - There is implemented a conception of
DataTemplateSelector, so one can select view template dynamically in runtime. ThisDataTemplateSelectoris analogue of conception ofDataTemplateSelectorfor Xaml platform (WPF, WinRT, etc). - Validation with usage of standard
TextView.Errorproperty is supported.
Updated less than a minute ago
