com.mailgun.model.PagingWithPivot Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of mailgun-java Show documentation
Show all versions of mailgun-java Show documentation
The Mailgun SDK for Java enables Java developers to work with Mailgun API
efficiently.
The newest version!
package com.mailgun.model;
import com.mailgun.enums.Page;
import feign.Param;
import lombok.Builder;
import lombok.Value;
import lombok.extern.jackson.Jacksonized;
/**
*
* Template page request.
*
*
* @see Templates
*/
@Value
@Jacksonized
@Builder
public class PagingWithPivot {
/**
*
* Number of records to retrieve.
* Default value is 10.
*
*/
Integer limit;
/**
*
* Name of a page to retrieve.
* FIRST
, LAST
, NEXT
or PREV
.
*
*/
String page;
/**
*
* Pivot is used to retrieve records in chronological order.
*
*/
@Param("p")
String pivot;
public static class PagingWithPivotBuilder {
/**
*
* Name of a page to retrieve.
* FIRST
, LAST
, NEXT
or PREV
.
*
*
* @param page {@link Page}
* @return Returns a reference to this object so that method calls can be chained together.
*/
public PagingWithPivot.PagingWithPivotBuilder page(Page page) {
this.page = page.getValue();
return this;
}
}
}