Skip to content

Commit 0531b8b

Browse files
Change hasException to hasThrowable
1 parent 349c11e commit 0531b8b

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

rxjava-core/src/main/java/rx/Notification.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ public boolean hasValue() {
9191
*
9292
* @return a value indicating whether this notification has an exception.
9393
*/
94-
public boolean hasException() {
94+
public boolean hasThrowable() {
9595
return isOnError() && throwable != null;
9696
}
9797

@@ -125,7 +125,7 @@ public String toString() {
125125
StringBuilder str = new StringBuilder("[").append(super.toString()).append(" ").append(getKind());
126126
if (hasValue())
127127
str.append(" ").append(getValue());
128-
if (hasException())
128+
if (hasThrowable())
129129
str.append(" ").append(getThrowable().getMessage());
130130
str.append("]");
131131
return str.toString();
@@ -136,7 +136,7 @@ public int hashCode() {
136136
int hash = getKind().hashCode();
137137
if (hasValue())
138138
hash = hash * 31 + getValue().hashCode();
139-
if (hasException())
139+
if (hasThrowable())
140140
hash = hash * 31 + getThrowable().hashCode();
141141
return hash;
142142
}
@@ -154,7 +154,7 @@ public boolean equals(Object obj) {
154154
return false;
155155
if (hasValue() && !getValue().equals(notification.getValue()))
156156
return false;
157-
if (hasException() && !getThrowable().equals(notification.getThrowable()))
157+
if (hasThrowable() && !getThrowable().equals(notification.getThrowable()))
158158
return false;
159159
return true;
160160
}

0 commit comments

Comments
 (0)