Package com.mindee.v2.http
Class MindeeHttpApiV2
- java.lang.Object
-
- com.mindee.http.MindeeApiCommon
-
- com.mindee.v2.http.MindeeApiV2
-
- com.mindee.v2.http.MindeeHttpApiV2
-
public final class MindeeHttpApiV2 extends MindeeApiV2
HTTP Client class for the V2 API.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classMindeeHttpApiV2.MindeeHttpApiV2Builder
-
Constructor Summary
Constructors Constructor Description MindeeHttpApiV2(MindeeSettings mindeeSettings)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static MindeeHttpApiV2.MindeeHttpApiV2Builderbuilder()JobResponsereqGetJobById(String jobId)Attempts to poll the queue.JobResponsereqGetJobByUrl(String pollingUrl)Get the status of an inference that was previously enqueued.<TResponse extends CommonResponse>
TResponsereqGetResultById(Class<TResponse> responseClass, String inferenceId)Retrieves the inference from a 302 redirect.<TResponse extends CommonResponse>
TResponsereqGetResultByUrl(Class<TResponse> responseClass, String inferenceUrl)Retrieves the inference from a given URL.<TSearchResponse extends BaseSearchResponse>
TSearchResponsereqGetSearch(BaseSearchParameters<TSearchResponse> parameters)Retrieves a list of resources with the given criteria.SearchResponsereqGetSearch(ModelSearchParameters parameters)Deprecated.JobResponsereqPostProductEnqueue(InputSource inputSource, BaseProductParameters parameters)Send a file to the asynchronous processing queue for a product.-
Methods inherited from class com.mindee.v2.http.MindeeApiV2
getParamsProductAttributes, getResponseProductAttributes, makeUnknownError
-
Methods inherited from class com.mindee.http.MindeeApiCommon
getUserAgent, isInvalidStatusCode, readRawResponse
-
-
-
-
Constructor Detail
-
MindeeHttpApiV2
public MindeeHttpApiV2(MindeeSettings mindeeSettings)
-
-
Method Detail
-
reqPostProductEnqueue
public JobResponse reqPostProductEnqueue(InputSource inputSource, BaseProductParameters parameters)
Description copied from class:MindeeApiV2Send a file to the asynchronous processing queue for a product.- Specified by:
reqPostProductEnqueuein classMindeeApiV2- Parameters:
inputSource- Local input source from URL.parameters- parameters.
-
reqGetJobByUrl
public JobResponse reqGetJobByUrl(String pollingUrl)
Description copied from class:MindeeApiV2Get the status of an inference that was previously enqueued.- Specified by:
reqGetJobByUrlin classMindeeApiV2- Parameters:
pollingUrl- The job URL as returned by the predict_async route.
-
reqGetJobById
public JobResponse reqGetJobById(String jobId)
Description copied from class:MindeeApiV2Attempts to poll the queue.- Specified by:
reqGetJobByIdin classMindeeApiV2- Parameters:
jobId- id of the job to get.
-
reqGetResultById
public <TResponse extends CommonResponse> TResponse reqGetResultById(Class<TResponse> responseClass, String inferenceId)
Description copied from class:MindeeApiV2Retrieves the inference from a 302 redirect.- Specified by:
reqGetResultByIdin classMindeeApiV2inferenceId- ID of the inference to poll.
-
reqGetResultByUrl
public <TResponse extends CommonResponse> TResponse reqGetResultByUrl(Class<TResponse> responseClass, String inferenceUrl)
Description copied from class:MindeeApiV2Retrieves the inference from a given URL. The inference will only be available after it has finished processing.- Specified by:
reqGetResultByUrlin classMindeeApiV2
-
reqGetSearch
public <TSearchResponse extends BaseSearchResponse> TSearchResponse reqGetSearch(BaseSearchParameters<TSearchResponse> parameters)
Description copied from class:MindeeApiV2Retrieves a list of resources with the given criteria.- Specified by:
reqGetSearchin classMindeeApiV2
-
reqGetSearch
@Deprecated public SearchResponse reqGetSearch(ModelSearchParameters parameters)
Deprecated.- Specified by:
reqGetSearchin classMindeeApiV2
-
builder
public static MindeeHttpApiV2.MindeeHttpApiV2Builder builder()
-
-