NewDownloader
Creates and returns a new Downloader instance, configured with the specified data store, literal map format, and download mode.
def NewDownloader(
_: context.Context,
store: storage.DataStore,
format: core.DataLoadingConfig_LiteralMapFormat,
mode: core.IOStrategy_DownloadMode
) - > Downloader
Creates and returns a new Downloader instance, configured with the specified data store, format, and download mode. Callers use this to obtain a Downloader object for subsequent data loading operations.
Parameters
| Name | Type | Description |
|---|---|---|
| _ | context.Context | The context for the operation, typically used for cancellation or deadlines. This parameter is currently unused within the function. |
| store | storage.DataStore | The data store from which data will be downloaded. This defines the source of the data. |
| format | core.DataLoadingConfig_LiteralMapFormat | The format in which the data should be interpreted or downloaded. This specifies the structure of the data. |
| mode | core.IOStrategy_DownloadMode | The download mode to be used, dictating the strategy for downloading data (e.g., direct download, streamed). This controls how the data transfer is performed. |
Returns
| Type | Description |
|---|---|
Downloader | A new Downloader instance configured with the provided parameters. |