Git Product home page Git Product logo

mvvm's Introduction

Android Mvvm:不再更新, 请移步Ayvytr/Flow

Android Kotlin Mvvm框架,使用了ViewModel, LiveData, 协程Coroutine,为简化开发而生。

搭配如下框架使用,效果更佳

implementation "com.ayvytr:network:2.3.0"
implementation "com.ayvytr:ktx:2.5.0"

Import

android

​ implementation 'com.ayvytr:mvvm:0.1.4'

androidx

​ implementation 'com.ayvytr:mvvm-androidx:0.1.4'

ChangeLog

  • 0.1.4

    1. 删除BaseViewModel.mNetworkExceptionHandler,.launchLoading
    2. 增加BaseViewModel.jobMap,用以方便取消未结束的Job
    3. 修改WrapperObserver,增加WrapperListObserver专门支持List和分页相关参数
  • 0.1.3 增加WrapperObserver.onSucceed ResponseWrapper参数

  • 0.1.2 修改launchLoading,launchWrapper方法返回Job

  • 0.1.1 修改WrapperObserver为abstract class,并提供onError默认实现

  • 0.1.0 框架第一版

使用

参考资料

Android中用Kotlin Coroutine(协程)和Retrofit进行网络请求和取消请求

Retrofit 2.6.0 ! 更快捷的协程体验 !

使用协程进行 UI 编程指南

mvvm's People

Contributors

ayvytr avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.