com.groupbyinc.api.model.Sort Maven / Gradle / Ivy
package com.groupbyinc.api.model;
import com.fasterxml.jackson.annotation.JsonSubTypes;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
import com.groupbyinc.api.model.sort.FieldSort;
import com.groupbyinc.api.model.sort.SortByIds;
/**
*
* Interface for Sorts
*
*/
@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "type", defaultImpl = FieldSort.class)
@JsonSubTypes({
@JsonSubTypes.Type(value = FieldSort.class, name = "Field"), //
@JsonSubTypes.Type(value = SortByIds.class, name = "ByIds") //
})
public interface Sort {
enum Order {
Ascending,
Descending
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy