Skip to content

Commit

Permalink
Rename exception to throwable to be clear
Browse files Browse the repository at this point in the history
  • Loading branch information
benjchristensen committed Aug 1, 2013
1 parent 97fafb0 commit 349c11e
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions rxjava-core/src/main/java/rx/Notification.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
public class Notification<T> {

private final Kind kind;
private final Throwable exception;
private final Throwable throwable;
private final T value;

/**
Expand All @@ -34,7 +34,7 @@ public class Notification<T> {
*/
public Notification(T value) {
this.value = value;
this.exception = null;
this.throwable = null;
this.kind = Kind.OnNext;
}

Expand All @@ -45,7 +45,7 @@ public Notification(T value) {
* The exception passed to the onError notification.
*/
public Notification(Throwable exception) {
this.exception = exception;
this.throwable = exception;
this.value = null;
this.kind = Kind.OnError;
}
Expand All @@ -54,7 +54,7 @@ public Notification(Throwable exception) {
* A constructor used to represent an onCompleted notification.
*/
public Notification() {
this.exception = null;
this.throwable = null;
this.value = null;
this.kind = Kind.OnCompleted;
}
Expand All @@ -65,7 +65,7 @@ public Notification() {
* @return Throwable associated with an onError notification.
*/
public Throwable getThrowable() {
return exception;
return throwable;
}

/**
Expand All @@ -92,7 +92,7 @@ public boolean hasValue() {
* @return a value indicating whether this notification has an exception.
*/
public boolean hasException() {
return isOnError() && exception != null;
return isOnError() && throwable != null;
}

/**
Expand Down

0 comments on commit 349c11e

Please sign in to comment.