当前位置: 软件>java软件
Android Binding
本文导语: Android Binding 提供了一个通用的框架用来实现 Android 的视图部件跟数据模型进行绑定的功能,用来实现 Android 应用程序的 MVC 模式。 Android-Binding is a MVVM (Model-View-ViewModel) framework, that helps freeing the Activity from working directly to User Inte...
Android Binding 提供了一个通用的框架用来实现 Android 的视图部件跟数据模型进行绑定的功能,用来实现 Android 应用程序的 MVC 模式。
Android-Binding is a MVVM (Model-View-ViewModel) framework, that helps freeing the Activity from working directly to User Interfaces. As an Activity, it's job is only to supply the ViewModel that the View requires to render the result while ViewModel is a class that with zero direct coupling with the View (and actually you might supply a different View to it).
关键特性:
- Declare view binding in Layout XML files. No additional files needed.
- Helps implements MVVM
- Much easier for Unit-Testing
- Model Validation that validates against ViewModel
- Support Cursor results, and you can even validate the cursor result!
您可能感兴趣的文章:
本站(WWW.)旨在分享和传播互联网科技相关的资讯和技术,将尽最大努力为读者提供更好的信息聚合和浏览方式。
本站(WWW.)站内文章除注明原创外,均为转载、整理或搜集自网络。欢迎任何形式的转载,转载请注明出处。
本站(WWW.)站内文章除注明原创外,均为转载、整理或搜集自网络。欢迎任何形式的转载,转载请注明出处。