com.sigopt.net.PaginatedAPIMethodCaller Maven / Gradle / Ivy
package com.sigopt.net;
import com.sigopt.model.APIObject;
import com.sigopt.model.APIResource;
import com.sigopt.model.Pagination;
public class PaginatedAPIMethodCaller extends APIMethodCaller> {
Class subklass;
public PaginatedAPIMethodCaller(String method, String path, Class klass) {
super(method, path);
this.subklass = subklass;
}
@Override
protected Pagination processBody(String body) {
return APIResource.constructPaginationFromJson(apiMethod.response.body, this.subklass);
}
}