Skip to content
This repository has been archived by the owner on Jun 18, 2020. It is now read-only.

Commit

Permalink
Simplify casting
Browse files Browse the repository at this point in the history
  • Loading branch information
austinv11 committed May 15, 2017
1 parent 07f6094 commit 9a7412f
Show file tree
Hide file tree
Showing 7 changed files with 46 additions and 109 deletions.
49 changes: 14 additions & 35 deletions .idea/modules/rx-extensions-core/rx-extensions-core.iml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

49 changes: 14 additions & 35 deletions .idea/modules/rx-extensions-reactor/rx-extensions-reactor.iml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

49 changes: 14 additions & 35 deletions .idea/modules/rx-extensions-rxjava/rx-extensions-rxjava.iml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ buildscript {

allprojects {
group 'com.austinv11.rx'
version '1.0'
version '1.1'

task wrapper(type: Wrapper) {
gradleVersion = '3.4.1'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public String getAuthor() {

@Override
public String getVersion() {
return "1.0";
return "1.1";
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ public ReactorEventAdapter(EventDispatcher dispatcher) {
*/
@Override
public <T extends Event> Flux<T> stream(Class<T> c) {
return flux.filter(e -> c.isAssignableFrom(e.getClass())).map(e -> (T) e);
return flux.ofType(c);
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ public RxJavaEventAdapter(EventDispatcher dispatcher) {
*/
@Override
public <T extends Event> Flowable<T> stream(Class<T> c) {
return eventFlowable.filter(e -> c.isAssignableFrom(e.getClass())).map(e -> (T) e);
return eventFlowable.ofType(c);
}

/**
Expand Down

0 comments on commit 9a7412f

Please sign in to comment.