public void OnValidSuspeciousFilePathCreated(object sender, string filePath) { _suspeciousFilePath = filePath; _suspeciousItems = ParseSuspeciousItems(); if (_suspeciousItems != null) { SuspeciousFilePathUpdate?.Invoke(this, _suspeciousFilePath); SuspeciousItemsUpdate?.Invoke(this, _suspeciousItems); } }
public void OnScanButtonWasClicked(object sender, EventArgs e) { Parallel.ForEach(_suspeciousItems.ToList(), item => _virusTotalWebAPI.PopulateSuspeciousItem(item)); SuspeciousItemsUpdate?.Invoke(this, _suspeciousItems); }