192 lines
4.4 KiB
Java
192 lines
4.4 KiB
Java
package com.inteligr8.alfresco.acs.model;
|
|
|
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
|
import io.swagger.annotations.ApiModel;
|
|
import io.swagger.annotations.ApiModelProperty;
|
|
import java.util.List;
|
|
|
|
/**
|
|
* A bucket of facet results
|
|
**/
|
|
@ApiModel(description="A bucket of facet results")
|
|
public class GenericBucket {
|
|
|
|
@ApiModelProperty(value = "The bucket label")
|
|
/**
|
|
* The bucket label
|
|
**/
|
|
private String label = null;
|
|
|
|
@ApiModelProperty(value = "The filter query you can use to apply this facet")
|
|
/**
|
|
* The filter query you can use to apply this facet
|
|
**/
|
|
private String filterQuery = null;
|
|
|
|
@ApiModelProperty(value = "An optional field for additional display information")
|
|
/**
|
|
* An optional field for additional display information
|
|
**/
|
|
private Object display = null;
|
|
|
|
@ApiModelProperty(value = "An array of buckets and values")
|
|
/**
|
|
* An array of buckets and values
|
|
**/
|
|
private List<GenericMetric> metrics = null;
|
|
|
|
@ApiModelProperty(value = "Additional list of nested facets")
|
|
/**
|
|
* Additional list of nested facets
|
|
**/
|
|
private List<Object> facets = null;
|
|
|
|
@ApiModelProperty(value = "")
|
|
private GenericBucketBucketInfo bucketInfo = null;
|
|
/**
|
|
* The bucket label
|
|
* @return label
|
|
**/
|
|
@JsonProperty("label")
|
|
public String getLabel() {
|
|
return label;
|
|
}
|
|
|
|
public void setLabel(String label) {
|
|
this.label = label;
|
|
}
|
|
|
|
public GenericBucket label(String label) {
|
|
this.label = label;
|
|
return this;
|
|
}
|
|
|
|
/**
|
|
* The filter query you can use to apply this facet
|
|
* @return filterQuery
|
|
**/
|
|
@JsonProperty("filterQuery")
|
|
public String getFilterQuery() {
|
|
return filterQuery;
|
|
}
|
|
|
|
public void setFilterQuery(String filterQuery) {
|
|
this.filterQuery = filterQuery;
|
|
}
|
|
|
|
public GenericBucket filterQuery(String filterQuery) {
|
|
this.filterQuery = filterQuery;
|
|
return this;
|
|
}
|
|
|
|
/**
|
|
* An optional field for additional display information
|
|
* @return display
|
|
**/
|
|
@JsonProperty("display")
|
|
public Object getDisplay() {
|
|
return display;
|
|
}
|
|
|
|
public void setDisplay(Object display) {
|
|
this.display = display;
|
|
}
|
|
|
|
public GenericBucket display(Object display) {
|
|
this.display = display;
|
|
return this;
|
|
}
|
|
|
|
/**
|
|
* An array of buckets and values
|
|
* @return metrics
|
|
**/
|
|
@JsonProperty("metrics")
|
|
public List<GenericMetric> getMetrics() {
|
|
return metrics;
|
|
}
|
|
|
|
public void setMetrics(List<GenericMetric> metrics) {
|
|
this.metrics = metrics;
|
|
}
|
|
|
|
public GenericBucket metrics(List<GenericMetric> metrics) {
|
|
this.metrics = metrics;
|
|
return this;
|
|
}
|
|
|
|
public GenericBucket addMetricsItem(GenericMetric metricsItem) {
|
|
this.metrics.add(metricsItem);
|
|
return this;
|
|
}
|
|
|
|
/**
|
|
* Additional list of nested facets
|
|
* @return facets
|
|
**/
|
|
@JsonProperty("facets")
|
|
public List<Object> getFacets() {
|
|
return facets;
|
|
}
|
|
|
|
public void setFacets(List<Object> facets) {
|
|
this.facets = facets;
|
|
}
|
|
|
|
public GenericBucket facets(List<Object> facets) {
|
|
this.facets = facets;
|
|
return this;
|
|
}
|
|
|
|
public GenericBucket addFacetsItem(Object facetsItem) {
|
|
this.facets.add(facetsItem);
|
|
return this;
|
|
}
|
|
|
|
/**
|
|
* Get bucketInfo
|
|
* @return bucketInfo
|
|
**/
|
|
@JsonProperty("bucketInfo")
|
|
public GenericBucketBucketInfo getBucketInfo() {
|
|
return bucketInfo;
|
|
}
|
|
|
|
public void setBucketInfo(GenericBucketBucketInfo bucketInfo) {
|
|
this.bucketInfo = bucketInfo;
|
|
}
|
|
|
|
public GenericBucket bucketInfo(GenericBucketBucketInfo bucketInfo) {
|
|
this.bucketInfo = bucketInfo;
|
|
return this;
|
|
}
|
|
|
|
|
|
@Override
|
|
public String toString() {
|
|
StringBuilder sb = new StringBuilder();
|
|
sb.append("class GenericBucket {\n");
|
|
|
|
sb.append(" label: ").append(toIndentedString(label)).append("\n");
|
|
sb.append(" filterQuery: ").append(toIndentedString(filterQuery)).append("\n");
|
|
sb.append(" display: ").append(toIndentedString(display)).append("\n");
|
|
sb.append(" metrics: ").append(toIndentedString(metrics)).append("\n");
|
|
sb.append(" facets: ").append(toIndentedString(facets)).append("\n");
|
|
sb.append(" bucketInfo: ").append(toIndentedString(bucketInfo)).append("\n");
|
|
sb.append("}");
|
|
return sb.toString();
|
|
}
|
|
|
|
/**
|
|
* Convert the given object to string with each line indented by 4 spaces
|
|
* (except the first line).
|
|
*/
|
|
private static String toIndentedString(java.lang.Object o) {
|
|
if (o == null) {
|
|
return "null";
|
|
}
|
|
return o.toString().replace("\n", "\n ");
|
|
}
|
|
}
|
|
|