redis.clients.jedis.timeseries.TSMRangeElements Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jedis_preview Show documentation
Show all versions of jedis_preview Show documentation
Jedis is a blazingly small and sane Redis java client.
The newest version!
package redis.clients.jedis.timeseries;
import java.util.List;
import java.util.Map;
import redis.clients.jedis.util.KeyValue;
public class TSMRangeElements extends KeyValue> {
private final Map labels;
private final List aggregators;
private final List reducers;
private final List sources;
public TSMRangeElements(String key, Map labels, List value) {
super(key, value);
this.labels = labels;
this.aggregators = null;
this.reducers = null;
this.sources = null;
}
public TSMRangeElements(String key, Map labels, List aggregators, List value) {
super(key, value);
this.labels = labels;
this.aggregators = aggregators;
this.reducers = null;
this.sources = null;
}
public TSMRangeElements(String key, Map labels, List reducers, List sources, List value) {
super(key, value);
this.labels = labels;
this.aggregators = null;
this.reducers = reducers;
this.sources = sources;
}
public Map getLabels() {
return labels;
}
public List getAggregators() {
return aggregators;
}
public List getReducers() {
return reducers;
}
public List getSources() {
return sources;
}
public List getElements() {
return getValue();
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder().append(getClass().getSimpleName())
.append("{key=").append(getKey()).append(", labels=").append(labels);
if (aggregators != null) {
sb.append(", aggregators=").append(aggregators);
}
if (reducers != null && sources != null) {
sb.append(", reducers").append(reducers).append(", sources").append(sources);
}
return sb.append(", elements=").append(getElements()).append('}').toString();
}
}