package eu.eudat.controllers.publicapi.query.definition; import eu.eudat.controllers.publicapi.QueryableList; import eu.eudat.controllers.publicapi.criteria.Criteria; import eu.eudat.controllers.publicapi.query.definition.helpers.ColumnOrderings; import eu.eudat.controllers.publicapi.query.definition.helpers.SelectionFields; import io.swagger.annotations.ApiModelProperty; public abstract class TableQuery, T, K> extends Query implements TableCriteriaQuery { private ColumnOrderings orderings; @ApiModelProperty(hidden = true) private SelectionFields selection; @ApiModelProperty(value = "length", name = "length", dataType = "Integer", example = "2") private Integer length; @ApiModelProperty(value = "offset", name = "offset", dataType = "Integer", example = "0") private Integer offset; public Integer getLength() { return length; } public void setLength(Integer length) { this.length = length; } public Integer getOffset() { return offset; } public void setOffset(Integer offset) { this.offset = offset; } public ColumnOrderings getOrderings() { return orderings; } public void setOrderings(ColumnOrderings orderings) { this.orderings = orderings; } public SelectionFields getSelection() { return selection; } public void setSelection(SelectionFields selection) { this.selection = selection; } @Override public QueryableList collect() { return this.applyPaging(super.collect()); } @Override public QueryableList collect(QueryableList repo) { return this.applyPaging(super.collect(repo)); } }