Skip to content

Commit 0883a92

Browse files
authored
Update README.md
1 parent 1fb56d7 commit 0883a92

File tree

1 file changed

+14
-14
lines changed

1 file changed

+14
-14
lines changed

README.md

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@
1010
```groovy
1111
// RxJava2
1212
implementation 'io.reactivex.rxjava2:rxjava:2.2.17'
13-
// RxAndroid
13+
// RxAndroid
1414
implementation 'io.reactivex.rxjava2:rxandroid:2.1.1'
15-
// RxLife
16-
implementation 'com.zpj.rxbus:RxBus:latest_version'
15+
// RxBus
16+
implementation 'com.github.Z-P-J:RxBus:latest_version'
1717
1818
```
1919
## 二、使用([查看 demo](https://github.com/Z-P-J/RxBus/tree/master/app)
@@ -141,8 +141,8 @@
141141
// 发送数据
142142
RxBus.post("Key", "msg", false, 100.0);
143143

144-
// 注意:若发送以下数据上面的订阅者将接收不到,第三个参数必须是Double类型才能接收到
145-
RxBus.post("Key", "msg", false, 100);
144+
// 注意:若发送以下数据上面的订阅者将接收不到,第三个参数必须是Double类型才能接收到
145+
RxBus.post("Key", "msg", false, 100);
146146
```
147147

148148
### 5. Sticky Event
@@ -159,15 +159,15 @@
159159
RxBus.postSticky(...);
160160

161161
// 获取Sticky事件
162-
RxBus.getStickyEvent("key");
163-
RxBus.getStickyEvent(clazz);
164-
RxBus.getStickyEvent("key", clazz);
165-
166-
// 移除Sticky事件
167-
RxBus.removeStickyEvent("key");
168-
RxBus.removeStickyEvent(clazz);
169-
RxBus.removeStickyEvent("key", clazz);
170-
RxBus.removeAllStickyEvents();
162+
RxBus.getStickyEvent("key");
163+
RxBus.getStickyEvent(clazz);
164+
RxBus.getStickyEvent("key", clazz);
165+
166+
// 移除Sticky事件
167+
RxBus.removeStickyEvent("key");
168+
RxBus.removeStickyEvent(clazz);
169+
RxBus.removeStickyEvent("key", clazz);
170+
RxBus.removeAllStickyEvents();
171171
```
172172

173173
### 6. 生命周期管理([使用RxLife框架实现](https://github.com/Z-P-J/RxLife)

0 commit comments

Comments
 (0)