All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.oxerr.viagogo.model.request.sale.SaleRequest Maven / Gradle / Ivy

There is a newer version: 6.5.1
Show newest version
package org.oxerr.viagogo.model.request.sale;

import java.util.Locale;

import org.oxerr.viagogo.model.Link;
import org.oxerr.viagogo.model.request.PagedRequest;

import io.openapitools.jackson.dataformat.hal.HALLink;

/**
 * Query parameter for List
 * sales.
 */
public class SaleRequest extends PagedRequest {

	private static final long serialVersionUID = 2023112401L;

	public enum Sort implements PagedRequest.Sort {

		CREATED_AT,

		EVENT_DATE,

		INHAND_AT,

		PAYMENT_AMOUNT,

		QUANTITY,

		RESOURCE_VERSION;

		@Override
		public String getCode() {
			return this.name().toLowerCase(Locale.US);
		}

	}

	public static SaleRequest from(HALLink halLink) {
		return new SaleRequest(new Link(halLink));
	}

	public SaleRequest() {
	}

	public SaleRequest(Link link) {
		super(link);
	}

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy