Skip to content
This repository has been archived by the owner on Jan 12, 2024. It is now read-only.

Commit

Permalink
Update SensorDataCyclingCadence.java
Browse files Browse the repository at this point in the history
  • Loading branch information
bhavya-bugude authored Oct 13, 2023
1 parent 960e6cd commit b3dbf20
Showing 1 changed file with 10 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@

public class SensorDataCyclingCadence extends SensorData<Cadence> {

private final String TAG = SensorDataCyclingCadence.class.getSimpleName();

private final String tag = SensorDataCyclingCadence.class.getSimpleName();
private final Long crankRevolutionsCount; // UINT32
private final Integer crankRevolutionsTime; // UINT16; 1/1024s

Expand Down Expand Up @@ -84,4 +84,12 @@ public boolean equals(@Nullable Object obj) {
return false;
}
}

@Override
public int hashCode() {
int result = super.hashCode();
result = 31 * result + (crankRevolutionsCount != null ? crankRevolutionsCount.hashCode() : 0);
result = 31 * result + (crankRevolutionsTime != null ? crankRevolutionsTime.hashCode() : 0);
return result;
}
}

0 comments on commit b3dbf20

Please sign in to comment.