Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
s0nerik authored Jul 7, 2016
1 parent edb8c83 commit 0c242cd
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ You can use an `RxList` either as a wrapper around any other `java.util.List` im
(in this case an `ArrayList` will be used as an implementation for a backing list).
Also it's possible to enable the "item removed" notification for each item that was removed when the list gets cleared (disabled by default).

```
```java
// ArrayList will be used as a backing list implementation.
RxList<Item> items = new RxList<>();

Expand All @@ -28,7 +28,7 @@ RxList<Item> items = new RxList<>(wrappedItems, true);

After you've created the `RxList` instance you will be able to get notified of the events that happen with it.
Use the `events()` method of the `RxList` to get the Observable of the `RxList`'s events:
```
```java
RxList<Item> items = new RxList<>();
items.events().subscribe(event -> System.out.println(event.type))
```
Expand All @@ -43,15 +43,15 @@ the changes in a list be shown to the user. Take a look at the

### Installation
- To use this library, add the following to your project level `build.gradle`:
```
```gradle
allprojects {
repositories {
maven { url "https://jitpack.io" }
}
}
```
- Add this to your app's `build.gradle`:
```
```gradle
compile 'com.github.s0nerik:rxlist:{latest version}'
```

Expand Down

0 comments on commit 0c242cd

Please sign in to comment.