ThresholdSecurities.java

1
package pl.zankowski.iextrading4j.api.stocks;
2
3
import com.fasterxml.jackson.annotation.JsonCreator;
4
import com.fasterxml.jackson.annotation.JsonFormat;
5
import com.fasterxml.jackson.annotation.JsonProperty;
6
import com.google.common.base.MoreObjects;
7
import com.google.common.base.Objects;
8
9
import java.io.Serializable;
10
import java.time.LocalDate;
11
12
public class ThresholdSecurities implements Serializable {
13
14
    private static final long serialVersionUID = -1919263280882297974L;
15
16
    private final LocalDate tradeDate;
17
    private final String symbolInINETSymbology;
18
    private final String symbolInCQSSymbology;
19
    private final String symbolInCMSSymbology;
20
    private final String cusip;
21
    private final String securityName;
22
23
    @JsonCreator
24
    public ThresholdSecurities(
25
            @JsonProperty("TradeDate") @JsonFormat(pattern = "yyyyMMdd") final LocalDate tradeDate,
26
            @JsonProperty("SymbolinINETSymbology") final String symbolInINETSymbology,
27
            @JsonProperty("SymbolinCQSSymbology") final String symbolInCQSSymbology,
28
            @JsonProperty("SymbolinCMSSymbology") final String symbolInCMSSymbology,
29
            @JsonProperty("CUSIP") final String cusip,
30
            @JsonProperty("SecurityName") final String securityName) {
31
        this.tradeDate = tradeDate;
32
        this.symbolInINETSymbology = symbolInINETSymbology;
33
        this.symbolInCQSSymbology = symbolInCQSSymbology;
34
        this.symbolInCMSSymbology = symbolInCMSSymbology;
35
        this.cusip = cusip;
36
        this.securityName = securityName;
37
    }
38
39
    public LocalDate getTradeDate() {
40 1 1. getTradeDate : replaced return value with null for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::getTradeDate → KILLED
        return tradeDate;
41
    }
42
43
    public String getSymbolInINETSymbology() {
44 1 1. getSymbolInINETSymbology : replaced return value with "" for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::getSymbolInINETSymbology → KILLED
        return symbolInINETSymbology;
45
    }
46
47
    public String getSymbolInCQSSymbology() {
48 1 1. getSymbolInCQSSymbology : replaced return value with "" for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::getSymbolInCQSSymbology → KILLED
        return symbolInCQSSymbology;
49
    }
50
51
    public String getSymbolInCMSSymbology() {
52 1 1. getSymbolInCMSSymbology : replaced return value with "" for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::getSymbolInCMSSymbology → KILLED
        return symbolInCMSSymbology;
53
    }
54
55
    public String getCusip() {
56 1 1. getCusip : replaced return value with "" for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::getCusip → KILLED
        return cusip;
57
    }
58
59
    public String getSecurityName() {
60 1 1. getSecurityName : replaced return value with "" for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::getSecurityName → KILLED
        return securityName;
61
    }
62
63
    @Override
64
    public boolean equals(final Object o) {
65 2 1. equals : negated conditional → KILLED
2. equals : replaced boolean return with false for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::equals → KILLED
        if (this == o) return true;
66 3 1. equals : negated conditional → KILLED
2. equals : negated conditional → KILLED
3. equals : replaced boolean return with true for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::equals → KILLED
        if (o == null || getClass() != o.getClass()) return false;
67
        final ThresholdSecurities that = (ThresholdSecurities) o;
68 2 1. equals : negated conditional → KILLED
2. equals : replaced boolean return with true for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::equals → KILLED
        return Objects.equal(tradeDate, that.tradeDate) &&
69 1 1. equals : negated conditional → KILLED
                Objects.equal(symbolInINETSymbology, that.symbolInINETSymbology) &&
70 1 1. equals : negated conditional → KILLED
                Objects.equal(symbolInCQSSymbology, that.symbolInCQSSymbology) &&
71 1 1. equals : negated conditional → KILLED
                Objects.equal(symbolInCMSSymbology, that.symbolInCMSSymbology) &&
72 1 1. equals : negated conditional → KILLED
                Objects.equal(cusip, that.cusip) &&
73 1 1. equals : negated conditional → KILLED
                Objects.equal(securityName, that.securityName);
74
    }
75
76
    @Override
77
    public int hashCode() {
78 1 1. hashCode : replaced int return with 0 for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::hashCode → KILLED
        return Objects.hashCode(tradeDate, symbolInINETSymbology, symbolInCQSSymbology, symbolInCMSSymbology,
79
                cusip, securityName);
80
    }
81
82
    @Override
83
    public String toString() {
84 1 1. toString : replaced return value with "" for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::toString → KILLED
        return MoreObjects.toStringHelper(this)
85
                .add("tradeDate", tradeDate)
86
                .add("symbolInINETSymbology", symbolInINETSymbology)
87
                .add("symbolInCQSSymbology", symbolInCQSSymbology)
88
                .add("symbolInCMSSymbology", symbolInCMSSymbology)
89
                .add("cusip", cusip)
90
                .add("securityName", securityName)
91
                .toString();
92
    }
93
}

Mutations

40

1.1
Location : getTradeDate
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:constructor()]
replaced return value with null for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::getTradeDate → KILLED

44

1.1
Location : getSymbolInINETSymbology
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:constructor()]
replaced return value with "" for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::getSymbolInINETSymbology → KILLED

48

1.1
Location : getSymbolInCQSSymbology
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:constructor()]
replaced return value with "" for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::getSymbolInCQSSymbology → KILLED

52

1.1
Location : getSymbolInCMSSymbology
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:constructor()]
replaced return value with "" for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::getSymbolInCMSSymbology → KILLED

56

1.1
Location : getCusip
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:constructor()]
replaced return value with "" for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::getCusip → KILLED

60

1.1
Location : getSecurityName
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:constructor()]
replaced return value with "" for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::getSecurityName → KILLED

65

1.1
Location : equals
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:equalsContract()]
negated conditional → KILLED

2.2
Location : equals
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:equalsContract()]
replaced boolean return with false for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::equals → KILLED

66

1.1
Location : equals
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:equalsContract()]
negated conditional → KILLED

2.2
Location : equals
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:equalsContract()]
negated conditional → KILLED

3.3
Location : equals
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:equalsContract()]
replaced boolean return with true for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::equals → KILLED

68

1.1
Location : equals
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:equalsContract()]
negated conditional → KILLED

2.2
Location : equals
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:equalsContract()]
replaced boolean return with true for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::equals → KILLED

69

1.1
Location : equals
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:equalsContract()]
negated conditional → KILLED

70

1.1
Location : equals
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:equalsContract()]
negated conditional → KILLED

71

1.1
Location : equals
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:equalsContract()]
negated conditional → KILLED

72

1.1
Location : equals
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:equalsContract()]
negated conditional → KILLED

73

1.1
Location : equals
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:equalsContract()]
negated conditional → KILLED

78

1.1
Location : hashCode
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:equalsContract()]
replaced int return with 0 for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::hashCode → KILLED

84

1.1
Location : toString
Killed by : pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest.[engine:junit-jupiter]/[class:pl.zankowski.iextrading4j.api.stocks.ThresholdSecuritiesTest]/[method:toStringVerification()]
replaced return value with "" for pl/zankowski/iextrading4j/api/stocks/ThresholdSecurities::toString → KILLED

Active mutators

Tests examined


Report generated by PIT 1.7.1