| 1 | package pl.zankowski.iextrading4j.api.stats; | |
| 2 | ||
| 3 | import com.fasterxml.jackson.annotation.JsonCreator; | |
| 4 | import com.fasterxml.jackson.annotation.JsonProperty; | |
| 5 | import com.google.common.base.MoreObjects; | |
| 6 | import com.google.common.base.Objects; | |
| 7 | ||
| 8 | import java.io.Serializable; | |
| 9 | import java.math.BigDecimal; | |
| 10 | ||
| 11 | public class IntradayStat implements Serializable { | |
| 12 | ||
| 13 | private static final long serialVersionUID = 2592939764468529774L; | |
| 14 | ||
| 15 | private final BigDecimal value; | |
| 16 | private final Long lastUpdated; | |
| 17 | ||
| 18 | @JsonCreator | |
| 19 | public IntradayStat( | |
| 20 | @JsonProperty("value") final BigDecimal value, | |
| 21 | @JsonProperty("lastUpdated") final Long lastUpdated) { | |
| 22 | this.value = value; | |
| 23 | this.lastUpdated = lastUpdated; | |
| 24 | } | |
| 25 | ||
| 26 | public BigDecimal getValue() { | |
| 27 |
1
1. getValue : replaced return value with null for pl/zankowski/iextrading4j/api/stats/IntradayStat::getValue → KILLED |
return value; |
| 28 | } | |
| 29 | ||
| 30 | public Long getLastUpdated() { | |
| 31 |
1
1. getLastUpdated : replaced Long return value with 0L for pl/zankowski/iextrading4j/api/stats/IntradayStat::getLastUpdated → KILLED |
return lastUpdated; |
| 32 | } | |
| 33 | ||
| 34 | @Override | |
| 35 | public boolean equals(Object o) { | |
| 36 |
2
1. equals : negated conditional → KILLED 2. equals : replaced boolean return with false for pl/zankowski/iextrading4j/api/stats/IntradayStat::equals → KILLED |
if (this == o) return true; |
| 37 |
3
1. equals : negated conditional → KILLED 2. equals : negated conditional → KILLED 3. equals : replaced boolean return with true for pl/zankowski/iextrading4j/api/stats/IntradayStat::equals → KILLED |
if (o == null || getClass() != o.getClass()) return false; |
| 38 | IntradayStat that = (IntradayStat) o; | |
| 39 |
2
1. equals : negated conditional → KILLED 2. equals : replaced boolean return with true for pl/zankowski/iextrading4j/api/stats/IntradayStat::equals → KILLED |
return Objects.equal(value, that.value) && |
| 40 |
1
1. equals : negated conditional → KILLED |
Objects.equal(lastUpdated, that.lastUpdated); |
| 41 | } | |
| 42 | ||
| 43 | @Override | |
| 44 | public int hashCode() { | |
| 45 |
1
1. hashCode : replaced int return with 0 for pl/zankowski/iextrading4j/api/stats/IntradayStat::hashCode → KILLED |
return Objects.hashCode(value, lastUpdated); |
| 46 | } | |
| 47 | ||
| 48 | @Override | |
| 49 | public String toString() { | |
| 50 |
1
1. toString : replaced return value with "" for pl/zankowski/iextrading4j/api/stats/IntradayStat::toString → KILLED |
return MoreObjects.toStringHelper(this) |
| 51 | .add("value", value) | |
| 52 | .add("lastUpdated", lastUpdated) | |
| 53 | .toString(); | |
| 54 | } | |
| 55 | } | |
Mutations | ||
| 27 |
1.1 |
|
| 31 |
1.1 |
|
| 36 |
1.1 2.2 |
|
| 37 |
1.1 2.2 3.3 |
|
| 39 |
1.1 2.2 |
|
| 40 |
1.1 |
|
| 45 |
1.1 |
|
| 50 |
1.1 |