Class MindeeApiV2

  • Direct Known Subclasses:
    MindeeHttpApiV2

    public abstract class MindeeApiV2
    extends MindeeApiCommon
    Communicate with the Mindee HTTP API V2.

    You may use this base class to make your own custom class. However, we may introduce breaking changes in minor versions as needed.

    • Constructor Detail

      • MindeeApiV2

        public MindeeApiV2()
    • Method Detail

      • reqGetJobByUrl

        public abstract JobResponse reqGetJobByUrl​(String pollingUrl)
        Get the status of an inference that was previously enqueued.
        Parameters:
        pollingUrl - The job URL as returned by the predict_async route.
      • reqGetJobById

        public abstract JobResponse reqGetJobById​(String jobId)
        Attempts to poll the queue.
        Parameters:
        jobId - id of the job to get.
      • reqGetResultById

        public abstract <TResponse extends CommonResponse> TResponse reqGetResultById​(Class<TResponse> responseClass,
                                                                                      String inferenceId)
        Retrieves the inference from a 302 redirect.
        Parameters:
        inferenceId - ID of the inference to poll.
      • reqGetResultByUrl

        public abstract <TResponse extends CommonResponse> TResponse reqGetResultByUrl​(Class<TResponse> responseClass,
                                                                                       String inferenceUrl)
        Retrieves the inference from a given URL. The inference will only be available after it has finished processing.
      • reqGetSearch

        public abstract <TSearchResponse extends BaseSearchResponse> TSearchResponse reqGetSearch​(BaseSearchParameters<TSearchResponse> parameters)
        Retrieves a list of resources with the given criteria.
      • makeUnknownError

        protected ErrorResponse makeUnknownError​(int statusCode)
        Creates an "unknown error" response from an HTTP status code.