Class UploadManager.UploadRequest.UploadRequestBuilder

    • Constructor Detail

    • Method Detail

      • allowOverwrite

        public UploadManager.UploadRequest.UploadRequestBuilder allowOverwrite​(boolean allowOverwrite)
        Configures whether or not the if-none-match header will be used to prevent overwrites on PUT.

        If this is disabled, the ifNoneMatch value in the PutObjectRequest builder will be overwritten with “*”.

        The default value is 'true'.

        Parameters:
        allowOverwrite - true to allow objects to be overwritten, false if not.
        Returns:
        This builder instance
      • parallelUploadExecutorService

        public UploadManager.UploadRequest.UploadRequestBuilder parallelUploadExecutorService​(ExecutorService parallelUploadExecutorService)
        Sets the executor service that should be used if the upload being made uses multi-part uploads.

        If none is provided, the UploadManager will create a new Executor per upload request. If the caller prefers to have a shared executor, one can be created by the caller and set on every UploadRequest through this method.

        Parameters:
        parallelUploadExecutorService - The executor to use.
        Returns:
        This builder instance
      • progressReporter

        public UploadManager.UploadRequest.UploadRequestBuilder progressReporter​(ProgressReporter progressReporter)
        Sets the progress reporter that is used to notify of updates during the upload.

        If none is provided, then no progress updates shall be reported.

        Parameters:
        progressReporter - The progress reporter to use.
        Returns:
        This builder instance
      • build

        public UploadManager.UploadRequest build​(PutObjectRequest request)
        Builds a new UploadRequest instance.

        The body and content length will be set on the given request based on the original values provided when creating the builder.

        Parameters:
        request - The request containing all param except the body and content length.
        Returns:
        A new request instance.