Skip to content

Commit 413f7b0

Browse files
committed
1.0.7
1 parent 0ea3f59 commit 413f7b0

File tree

3 files changed

+11
-9
lines changed

3 files changed

+11
-9
lines changed

README.md

+7-7
Original file line numberDiff line numberDiff line change
@@ -2,50 +2,50 @@
22

33
###TaskHelper主要用于执行多个任务,通过回调ICallback更新UI
44

5-
Download Library [JAR](https://github.com/LuckyJayce/MVCHelper/releases/download/1.0.2/LuckyJayce_MVCHelper_1.0.2.zip)
5+
Download Library [JAR](https://github.com/LuckyJayce/MVCHelper/releases/download/1.0.7/LuckyJayce_MVCHelper_1.0.7.zip)
66
Download sample [Apk](https://github.com/LuckyJayce/MVCHelper/blob/master/raw/MVCHelper_Demo.apk?raw=true)
77

88
# Gradle导入 #
99
## 1.必须导入: ##
1010

1111
//MVCHelper核心类库
12-
compile 'com.shizhefei:MVCHelper-Library:1.0.6'
12+
compile 'com.shizhefei:MVCHelper-Library:1.0.7'
1313
//里面有使用recyclerview,所以需要导入recyclerview
1414
compile 'com.android.support:recyclerview-v7:24.0.0'
1515

1616
## 2.可选: ##
1717
<1> 使用 https://github.com/chrisbanes/Android-PullToRefresh 的刷新控件导入
1818

1919
//里面包含一个MVCPullrefshHelper 是适配这个控件的 MVCHelper
20-
compile 'com.shizhefei:MVCHelper-Pullrefresh:1.0.6'
20+
compile 'com.shizhefei:MVCHelper-Pullrefresh:1.0.7'
2121
//由于没有找到gradle排至,我自己把它上传到jcenter上
2222
compile 'com.shizhefei:pulltorefresh:1.0.1'
2323

2424
<2> 使用 https://github.com/liaohuqiu/android-Ultra-Pull-To-Refresh 的刷新控件导入
2525

2626
//里面包含一个MVCUltraHelper 是适配这个控件的 MVCHelper
27-
compile 'com.shizhefei:MVCHelper-UltraRefresh:1.0.6'
27+
compile 'com.shizhefei:MVCHelper-UltraRefresh:1.0.7'
2828
//这里6月29号目前最新的,要实时关注新版本去秋大的网站上去看
2929
compile 'in.srain.cube:ultra-ptr:1.0.11'
3030

3131
<3> 使用android v4的SwipeRefreshLayout的作为刷新控件导入
3232

3333
//里面包含一个MVCSwipeRefreshHelper 是适配这个控件的 MVCHelper
34-
compile 'com.shizhefei:MVCHelper-SwipeRefresh:1.0.6'
34+
compile 'com.shizhefei:MVCHelper-SwipeRefresh:1.0.7'
3535
//v4包应该都有导入吧,v7包里面包含v4包
3636
compile 'com.android.support:support-v4:24.0.0'
3737

3838
<4> 测试用例,可以方便的查看MVCHelper,Task的运行情况和返回数据,还提供了修改接口字段,用于接口测试很方便哦
3939

4040
//MVCHelper的测试用例,继承ABSTestCaseFragment实现List<TestCaseData> getTestCaseDatas()方法
41-
compile 'com.shizhefei:MVCHelper-TestCase:1.0.6'
41+
compile 'com.shizhefei:MVCHelper-TestCase:1.0.7'
4242
//里面用到了gson
4343
compile 'com.google.code.gson:gson:2.2.4'
4444

4545
<5> MVCHelper-OkHttp 对OKHttp的简单封装
4646

4747
//MVCHelper的 OKHttp的简单封装
48-
compile 'com.shizhefei:MVCHelper-OkHttp:1.0.6'
48+
compile 'com.shizhefei:MVCHelper-OkHttp:1.0.7'
4949
//里面用到了okhttp3
5050
compile 'com.squareup.okhttp3:okhttp:3.4.0'
5151
compile 'com.squareup.okio:okio:1.9.0'

build.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ allprojects {
1919
}
2020

2121
ext {
22-
VERSION_NAME = '1.0.6'
23-
VERSION_CODE = 7
22+
VERSION_NAME = '1.0.7'
23+
VERSION_CODE = 8
2424
}
2525

2626

mvchelper_library/src/main/java/com/shizhefei/task/TaskHelper.java

+2
Original file line numberDiff line numberDiff line change
@@ -239,6 +239,8 @@ public void cancelAll() {
239239
if (taskImps.isEmpty()) {
240240
return;
241241
}
242+
//这里创建一个临时的map,主要原因是Set循环的时候不能remove操作,否则会报ConcurrentModificationException
243+
//TaskImp里面会调用到Set的remove
242244
HashSet<TaskImp> temp = new HashSet<>(taskImps);
243245
for (TaskImp entry : temp) {
244246
entry.cancle();

0 commit comments

Comments
 (0)