Add @Nullable to Object#equals()
This is a partial cherry-pick of change: I5eedb571c9d78862115dfdc5dae1cf2a35343580 for connectivity classes. Bug: 170883422 Test: m Merged-In: I5eedb571c9d78862115dfdc5dae1cf2a35343580 Change-Id: I7dc661863b73f4198ddb4f3a1566583d0f07db3c
This commit is contained in:
committed by
Remi NGUYEN VAN
parent
1b2443d1c5
commit
384a8c63f2
@@ -534,7 +534,7 @@ public final class RouteInfo implements Parcelable {
|
||||
* Compares this RouteInfo object against the specified object and indicates if they are equal.
|
||||
* @return {@code true} if the objects are equal, {@code false} otherwise.
|
||||
*/
|
||||
public boolean equals(Object obj) {
|
||||
public boolean equals(@Nullable Object obj) {
|
||||
if (this == obj) return true;
|
||||
|
||||
if (!(obj instanceof RouteInfo)) return false;
|
||||
@@ -570,7 +570,7 @@ public final class RouteInfo implements Parcelable {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o) {
|
||||
public boolean equals(@Nullable Object o) {
|
||||
if (!(o instanceof RouteKey)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user