GeofabrikDownloader.print_action_prompt

classmethod GeofabrikDownloader.print_action_prompt(data_name='<data_name>', verbose=False, confirmation_required=True, note='', end=' ... ')[source]

Print a short message showing the action as a function runs.

Parameters:
  • data_name (str) – name of the prepacked data, defaults to '<data_name>'

  • verbose (bool | int) – whether to print relevant information in console, defaults to False

  • confirmation_required (bool) – whether asking for confirmation to proceed, defaults to True

  • note (str) – additional message, defaults to ""

  • end (str) – end string after printing the status message, defaults to " ... "

Returns:

None.

Return type:

None

Examples:

>>> from pydriosm.downloader._base import BaseDownloader
>>> BaseDownloader.print_action_prompt(verbose=False) is None  # Nothing is printed.
True
>>> BaseDownloader.print_action_prompt(verbose=True)
... print("Done.")
Retrieving/compiling the data ... Done.
>>> BaseDownloader.print_action_prompt(verbose=True, note="(Some notes)")
... print("Done.")
Retrieving/compiling the data (Some notes) ... Done.
>>> BaseDownloader.print_action_prompt(verbose=True, confirmation_required=False)
... print("Done.")
Retrieving/compiling data of <data_name> ... Done.