The Upload interface, extension of Transfer

Hierarchy

Accessors

  • get destinationFolder(): string
  • Return the current selected destination folder

    Returns string

  • set destinationFolder(relativePortalRootFolderPath: string): void
  • Parameters

    • relativePortalRootFolderPath: string

    Returns void

  • get transferId(): string
  • Returns

    The unique identifier for this transfer

    Example

    2ccc5d48-e43b-40b7-bb70-f591dc51c293
    

    Returns string

Methods

  • Opens destination folder chosen during the download initialization This launches a finder window for Mac or an explorer window for windows

    Returns

    A Promise which resolves to the files included in the upload.

    Returns Promise<LocalFile[]>

  • Attempt to add a pre-authorized list of files to the upload.

    Returns

    A Promise which resolves to the files attempted to be included in the upload. If a file is in error, it will not be added to the upload.

    Parameters

    • filePaths: string[]

      Array of absolute file paths to be attempted to be added to the upload

    • token: string

      Authorization token generated by the Platform API.

    Returns Promise<LocalFile[]>

  • Cancel the transfer. Valid in the following states:

    • STARTING,
    • QUEUED,
    • IN_PROGRESS

    Returns

    A Promise which will resolve when the transfer has canceled successfully.

    Returns Promise<void>

  • Attempt to extract technical metadata from a list of files. Files must match or be a subset of the files previously selected.

    Returns

    A Promise which resolves to an array of file metadata. If there is an error extracting the file metadata, the file's absolute path and error details will be returned in the array.

    Parameters

    • filePaths: string[]

      Array of absolute file paths to be attempted for metadata extraction.

    Returns Promise<FileMetadata[]>

  • Using a list of paths it removes the selected files whose path is in the provided array

    Parameters

    • filePaths: string[]

      paths of the files to be removed

    Returns Promise<LocalFile[]>

  • Retry the incomplete transfer. Valid in the following states

    • FAILURE
    • CANCELED

    Returns

    A Promise which will resolve when the retry has been successfully initiated.

    Returns Promise<void>

  • Start the transfer. Valid in the following states:

    • IDLE

    Returns

    A Promise which will resolve when the transfer has started successfully.

    Returns Promise<void>

  • Unsubscribe from a transfer event

    Returns

    true if the listener was present and unsubscribed, false if there was no match for the eventType / listener combination.

    Parameters

    Returns boolean

  • Returns

    true when 1 or more listeners were removed.

    Returns boolean

Generated using TypeDoc