Class AbstractConvertFilesResource<TRAR extends AbstractResult<TaskResponse>,​ORP extends AbstractResult<Pageable<OperationResponse>>>

java.lang.Object
com.cloudconvert.resource.AbstractResource
com.cloudconvert.resource.AbstractConvertFilesResource<TRAR,​ORP>
All Implemented Interfaces:
java.io.Closeable, java.lang.AutoCloseable
Direct Known Subclasses:
AsyncConvertFilesResource, ConvertFilesResource

public abstract class AbstractConvertFilesResource<TRAR extends AbstractResult<TaskResponse>,​ORP extends AbstractResult<Pageable<OperationResponse>>>
extends AbstractResource
  • Field Details

    • PATH_SEGMENT_CONVERT

      public static final java.lang.String PATH_SEGMENT_CONVERT
      See Also:
      Constant Field Values
    • PATH_SEGMENT_FORMATS

      public static final java.lang.String PATH_SEGMENT_FORMATS
      See Also:
      Constant Field Values
  • Constructor Details

  • Method Details

    • convert

      public abstract TRAR convert​(@NotNull @NotNull ConvertFilesTaskRequest convertFilesTaskRequest) throws java.io.IOException, java.net.URISyntaxException, CloudConvertClientException, CloudConvertServerException
      Create a task to convert one input file from input_format to output_format. Requires the task.write scope.
      Parameters:
      convertFilesTaskRequest - ConvertFilesTaskRequest
      Returns:
      AbstractConvertFilesResource
      Throws:
      java.io.IOException
      java.net.URISyntaxException
      CloudConvertClientException
      CloudConvertServerException
    • getConvertHttpUriRequest

      protected org.apache.http.client.methods.HttpUriRequest getConvertHttpUriRequest​(@NotNull @NotNull ConvertFilesTaskRequest convertFilesTaskRequest) throws java.io.IOException, java.net.URISyntaxException
      Throws:
      java.io.IOException
      java.net.URISyntaxException
    • convertFormats

      public abstract ORP convertFormats() throws java.io.IOException, java.net.URISyntaxException, CloudConvertClientException, CloudConvertServerException
      List all supported formats, their engines and possible options.
      Returns:
      AbstractConvertFilesResource
      Throws:
      java.io.IOException
      java.net.URISyntaxException
      CloudConvertClientException
      CloudConvertServerException
    • convertFormats

      public abstract ORP convertFormats​(@NotNull @NotNull java.util.Map<Filter,​java.lang.String> filters) throws java.io.IOException, java.net.URISyntaxException, CloudConvertClientException, CloudConvertServerException
      List all supported formats, their engines and possible options.
      Parameters:
      filters - (optional) Filters: - input_format - The result will be filtered to include only possible conversions with a matching input format. - output_format - The result will be filtered to include only possible conversions with a matching output format. - engine - Filter result to only include conversions with a matching engine name. - engine_version - Filter result to only include conversions with a matching engine version.
      Returns:
      AbstractConvertFilesResource
      Throws:
      java.io.IOException
      java.net.URISyntaxException
      CloudConvertClientException
      CloudConvertServerException
    • convertFormats

      public abstract ORP convertFormats​(@NotNull @NotNull java.util.Map<Filter,​java.lang.String> filters, @NotNull @NotNull java.util.List<Include> includes) throws java.io.IOException, java.net.URISyntaxException, CloudConvertClientException, CloudConvertServerException
      List all supported formats, their engines and possible options.
      Parameters:
      filters - (optional) Filters: - input_format - The result will be filtered to include only possible conversions with a matching input format. - output_format - The result will be filtered to include only possible conversions with a matching output format. - engine - Filter result to only include conversions with a matching engine name. - engine_version - Filter result to only include conversions with a matching engine version.
      includes - (optional) Include options and/or engine_versions in the result.
      Returns:
      AbstractConvertFilesResource
      Throws:
      java.io.IOException
      java.net.URISyntaxException
      CloudConvertClientException
      CloudConvertServerException
    • convertFormats

      public abstract ORP convertFormats​(@NotNull @NotNull java.util.Map<Filter,​java.lang.String> filters, @NotNull @NotNull java.util.List<Include> includes, @Nullable @Nullable java.lang.Boolean alternative) throws java.io.IOException, java.net.URISyntaxException, CloudConvertClientException, CloudConvertServerException
      List all supported formats, their engines and possible options.
      Parameters:
      filters - (optional) Filters: - input_format - The result will be filtered to include only possible conversions with a matching input format. - output_format - The result will be filtered to include only possible conversions with a matching output format. - engine - Filter result to only include conversions with a matching engine name. - engine_version - Filter result to only include conversions with a matching engine version.
      includes - (optional) Include options and/or engine_versions in the result.
      alternative - (optional) For some formats multiple alternative engines are available. If set to true, the result includes these alternative conversion types. Default to false.
      Returns:
      AbstractConvertFilesResource
      Throws:
      java.io.IOException
      java.net.URISyntaxException
      CloudConvertClientException
      CloudConvertServerException
    • getConvertFormatsHttpUriRequest

      protected org.apache.http.client.methods.HttpUriRequest getConvertFormatsHttpUriRequest​(@NotNull @NotNull java.util.Map<Filter,​java.lang.String> filters, @NotNull @NotNull java.util.List<Include> includes, @Nullable @Nullable java.lang.Boolean alternative) throws java.io.IOException, java.net.URISyntaxException
      Throws:
      java.io.IOException
      java.net.URISyntaxException