001
002package net.sf.jkniv.whinstone.couchdb;
003
004import java.util.HashMap;
005import java.util.Map;
006import com.fasterxml.jackson.annotation.JsonAnyGetter;
007import com.fasterxml.jackson.annotation.JsonAnySetter;
008import com.fasterxml.jackson.annotation.JsonIgnore;
009import com.fasterxml.jackson.annotation.JsonInclude;
010import com.fasterxml.jackson.annotation.JsonProperty;
011import com.fasterxml.jackson.annotation.JsonPropertyOrder;
012
013@JsonInclude(JsonInclude.Include.NON_NULL)
014@JsonPropertyOrder({
015    "total_keys_examined",
016    "total_docs_examined",
017    "total_quorum_docs_examined",
018    "results_returned",
019    "execution_time_ms"
020})
021public class ExecutionStats {
022
023    @JsonProperty("total_keys_examined")
024    private Long totalKeysExamined;
025    @JsonProperty("total_docs_examined")
026    private Long totalDocsExamined;
027    @JsonProperty("total_quorum_docs_examined")
028    private Long totalQuorumDocsExamined;
029    @JsonProperty("results_returned")
030    private Long resultsReturned;
031    @JsonProperty("execution_time_ms")
032    private Double executionTimeMs;
033    
034    @JsonIgnore
035    private Map<String, Object> additionalProperties = new HashMap<String, Object>();
036
037    @JsonProperty("total_keys_examined")
038    public Long getTotalKeysExamined() {
039        return totalKeysExamined;
040    }
041
042    @JsonProperty("total_keys_examined")
043    public void setTotalKeysExamined(Long totalKeysExamined) {
044        this.totalKeysExamined = totalKeysExamined;
045    }
046
047    @JsonProperty("total_docs_examined")
048    public Long getTotalDocsExamined() {
049        return totalDocsExamined;
050    }
051
052    @JsonProperty("total_docs_examined")
053    public void setTotalDocsExamined(Long totalDocsExamined) {
054        this.totalDocsExamined = totalDocsExamined;
055    }
056
057    @JsonProperty("total_quorum_docs_examined")
058    public Long getTotalQuorumDocsExamined() {
059        return totalQuorumDocsExamined;
060    }
061
062    @JsonProperty("total_quorum_docs_examined")
063    public void setTotalQuorumDocsExamined(Long totalQuorumDocsExamined) {
064        this.totalQuorumDocsExamined = totalQuorumDocsExamined;
065    }
066
067    @JsonProperty("results_returned")
068    public Long getResultsReturned() {
069        return resultsReturned;
070    }
071
072    @JsonProperty("results_returned")
073    public void setResultsReturned(Long resultsReturned) {
074        this.resultsReturned = resultsReturned;
075    }
076
077    @JsonProperty("execution_time_ms")
078    public Double getExecutionTimeMs() {
079        return executionTimeMs;
080    }
081
082    @JsonProperty("execution_time_ms")
083    public void setExecutionTimeMs(Double executionTimeMs) {
084        this.executionTimeMs = executionTimeMs;
085    }
086
087    @JsonAnyGetter
088    public Map<String, Object> getAdditionalProperties() {
089        return this.additionalProperties;
090    }
091
092    @JsonAnySetter
093    public void setAdditionalProperty(String name, Object value) {
094        this.additionalProperties.put(name, value);
095    }
096
097    @Override
098    public String toString()
099    {
100        return "ExecutionStats [totalKeysExamined=" + totalKeysExamined + ", totalDocsExamined=" + totalDocsExamined
101                + ", totalQuorumDocsExamined=" + totalQuorumDocsExamined + ", resultsReturned=" + resultsReturned
102                + ", executionTimeMs=" + executionTimeMs + "]";
103    }
104
105}