Interface DownloadSource<T>
- Type Parameters:
T- The type of the data that a download source uses.
- All Known Implementing Classes:
OSMDownloadSource,OverpassDownloadSource
public interface DownloadSource<T>
Defines an interface for different download sources.
Plugins may implement this to provide new download sources to the main download dialog.
- Since:
- 12652
-
Method Summary
Modifier and TypeMethodDescriptioncreatePanel(DownloadDialog dialog) Creates a panel with GUI specific for the download source.voiddoDownload(T data, DownloadSettings settings) Downloads the data.getLabel()Returns a string representation of this download source.booleanDefines whether this download source should be visible only in the expert mode.
-
Method Details
-
createPanel
Creates a panel with GUI specific for the download source.- Parameters:
dialog- the parent download dialog, asDownloadDialog.getInstance()might not be initialized yet- Returns:
- Returns
AbstractDownloadSourcePanel. - Since:
- 12900
-
doDownload
Downloads the data.- Parameters:
data- The required data for the download source.settings- The global settings of the download dialog, seeDownloadDialog.
-
getLabel
Returns a string representation of this download source.- Returns:
- A string representation of this download source.
-
onlyExpert
boolean onlyExpert()Defines whether this download source should be visible only in the expert mode.- Returns:
- Returns
trueif the download source should be visible only in the expert mode,falseotherwise.
-