C# Class Nexus.Client.DownloadMonitoring.UI.DownloadMonitorVM

This class encapsulates the data and the operations presented by UI elements that display Download monitoring.
Inheritance: INotifyPropertyChanged
Afficher le fichier Open project: NexusMods/NexusModManager-4.5 Class Usage Examples

Méthodes publiques

Méthode Description
CanCancelTask ( IBackgroundTask p_tskTask ) : bool

Determines if the given IBackgroundTask can be cancelled.

CanPauseDownload ( IBackgroundTask p_tskTask ) : bool

Determines if the given IBackgroundTask can be paused.

CanQueueDownload ( IBackgroundTask p_tskTask ) : bool

Determines if the given IBackgroundTask can be paused.

CanRemoveDownload ( IBackgroundTask p_tskTask ) : bool

Determines if the given IBackgroundTask can be removed.

CanResumeDownload ( IBackgroundTask p_tskTask ) : bool

Determines if the given IBackgroundTask can be resumed.

CancelTask ( IBackgroundTask p_tskTask ) : void

Cancels the given task.

DownloadMonitorVM ( DownloadMonitor p_amnDownloadMonitor, ISettings p_setSettings, ModManager p_mmgModManager, IModRepository p_mrpModRepository ) : Nexus.Client.BackgroundTasks

A simple constructor that initializes the object with its dependencies.

PauseTask ( IBackgroundTask p_tskTask ) : void

Puases the given task.

QueueTask ( IBackgroundTask p_tskTask ) : void

Puases the given task.

RemoveAllTasks ( ) : void

Removes all the completed/failed tasks.

RemoveTask ( AddModTask p_tskTask ) : void

Removes the given task.

ResumeAllTasks ( ) : void

Resumes all paused tasks.

ResumeTask ( IBackgroundTask p_tskTask ) : void

Resumes the given task.

Méthodes protégées

Méthode Description
OnPropertyChanged ( string name ) : void

Raises the INotifyPropertyChanged.PropertyChanged event of the project.

Private Methods

Méthode Description
ActiveTasks_PropertyChanged ( object sender, System e ) : void
ModRepository_UserStatusUpdate ( object sender, System e ) : void

Handles the m_mrpModRepository.UserStatusUpdate event of the tasks list.

Updates the UI elements.

bgwWorker_DoWork ( object sender, DoWorkEventArgs e ) : void
bgwWorker_RunWorkerCompleted ( object sender, RunWorkerCompletedEventArgs e ) : void

Method Details

CanCancelTask() public méthode

Determines if the given IBackgroundTask can be cancelled.
public CanCancelTask ( IBackgroundTask p_tskTask ) : bool
p_tskTask IBackgroundTask The task for which it is to be determined /// if it can be cancelled.
Résultat bool

CanPauseDownload() public méthode

Determines if the given IBackgroundTask can be paused.
public CanPauseDownload ( IBackgroundTask p_tskTask ) : bool
p_tskTask IBackgroundTask The task for which it is to be determined /// if it can be paused.
Résultat bool

CanQueueDownload() public méthode

Determines if the given IBackgroundTask can be paused.
public CanQueueDownload ( IBackgroundTask p_tskTask ) : bool
p_tskTask IBackgroundTask The task for which it is to be determined /// if it can be paused.
Résultat bool

CanRemoveDownload() public méthode

Determines if the given IBackgroundTask can be removed.
public CanRemoveDownload ( IBackgroundTask p_tskTask ) : bool
p_tskTask IBackgroundTask The task for which it is to be determined /// if it can be removed.
Résultat bool

CanResumeDownload() public méthode

Determines if the given IBackgroundTask can be resumed.
public CanResumeDownload ( IBackgroundTask p_tskTask ) : bool
p_tskTask IBackgroundTask The task for which it is to be determined /// if it can be resumed.
Résultat bool

CancelTask() public méthode

Cancels the given task.
public CancelTask ( IBackgroundTask p_tskTask ) : void
p_tskTask IBackgroundTask The task to cancel.
Résultat void

DownloadMonitorVM() public méthode

A simple constructor that initializes the object with its dependencies.
public DownloadMonitorVM ( DownloadMonitor p_amnDownloadMonitor, ISettings p_setSettings, ModManager p_mmgModManager, IModRepository p_mrpModRepository ) : Nexus.Client.BackgroundTasks
p_amnDownloadMonitor DownloadMonitor The Download manager to use to manage the monitored activities.
p_setSettings ISettings The application and user settings.
p_mmgModManager Nexus.Client.ModManagement.ModManager
p_mrpModRepository IModRepository
Résultat Nexus.Client.BackgroundTasks

OnPropertyChanged() protected méthode

Raises the INotifyPropertyChanged.PropertyChanged event of the project.
protected OnPropertyChanged ( string name ) : void
name string The property name.
Résultat void

PauseTask() public méthode

Puases the given task.
public PauseTask ( IBackgroundTask p_tskTask ) : void
p_tskTask IBackgroundTask The task to pause.
Résultat void

QueueTask() public méthode

Puases the given task.
public QueueTask ( IBackgroundTask p_tskTask ) : void
p_tskTask IBackgroundTask The task to pause.
Résultat void

RemoveAllTasks() public méthode

Removes all the completed/failed tasks.
public RemoveAllTasks ( ) : void
Résultat void

RemoveTask() public méthode

Removes the given task.
public RemoveTask ( AddModTask p_tskTask ) : void
p_tskTask Nexus.Client.ModManagement.AddModTask IBackgroundTask task to remove.
Résultat void

ResumeAllTasks() public méthode

Resumes all paused tasks.
public ResumeAllTasks ( ) : void
Résultat void

ResumeTask() public méthode

Resumes the given task.
public ResumeTask ( IBackgroundTask p_tskTask ) : void
p_tskTask IBackgroundTask The task to resume.
Résultat void