Files
notes/02-projects/Uplink/interfaces.py.md
T
2026-07-14 08:05:36 -07:00

1.1 KiB

BaseBackupEngine

class BaseBackupEngine(ABC)
	"""
	Abstract Base Class for backup engine class
	"""
	@abstractmethod
	def run(self, tasks: list[BackupTasks], dry_run) -> bool:
	"""
	This method handles the backup process for the engine. Any tasks related to
	that backup task should be handled in this method
	
	args:
		- tasks (list[BackupTask]): list of BackgroundTask objects to be
		  processed.
		- dry_run (bool, optional): Dry run flag. If this flag is set, this
		  function will return None. A list of all files to be compressed, their
		  total size, and the path to the output file will be printed to the
		  console, and logged. Defaults to False.
	"""

run

This method handles the backup process for the engine. Any tasks related to that backup task should be handled in this method

args:

  • tasks (list[BackupTask]): list of BackupTask objects to be processed.
  • dry_run (bool, optional): Dry run flag. If this flag is set, this function will return None. A list of all files to be compressed, their total size, and the path to the output file will be printed to the console, and logged. Defaults to False.