1.0-dev18 (prerelease 1 completed)

This commit is contained in:
2022-05-15 22:13:47 +02:00
Unverified
parent 7acaeb24de
commit e36c1404ee
61 changed files with 1004 additions and 144 deletions

View File

@@ -1,24 +0,0 @@
using System;
namespace VDownload.Core.EventArgs
{
public class DownloadTaskEndedSuccessfullyEventArgs : System.EventArgs
{
#region CONSTRUCTORS
public DownloadTaskEndedSuccessfullyEventArgs(TimeSpan elapsedTime)
{
ElapsedTime = elapsedTime;
}
#endregion
#region PROPERTIES
public TimeSpan ElapsedTime { get; private set; }
#endregion
}
}

View File

@@ -1,24 +0,0 @@
using System;
namespace VDownload.Core.EventArgs
{
public class DownloadTaskEndedUnsuccessfullyEventArgs : System.EventArgs
{
#region CONSTRUCTORS
public DownloadTaskEndedUnsuccessfullyEventArgs(Exception exception)
{
Exception = exception;
}
#endregion
#region PROPERTIES
public Exception Exception { get; private set; }
#endregion
}
}

View File

@@ -1,24 +0,0 @@
using System;
namespace VDownload.Core.EventArgs
{
public class DownloadTaskScheduledEventArgs : System.EventArgs
{
#region CONSTRUCTORS
public DownloadTaskScheduledEventArgs(DateTime scheduledFor)
{
ScheduledFor = scheduledFor;
}
#endregion
#region PROPERTIES
public DateTime ScheduledFor { get; private set; }
#endregion
}
}

View File

@@ -0,0 +1,61 @@
using System;
using VDownload.Core.Enums;
namespace VDownload.Core.EventArgs
{
public class DownloadTaskStatusChangedEventArgs : System.EventArgs
{
#region CONSTRUCTORS
public DownloadTaskStatusChangedEventArgs(DownloadTaskStatus status)
{
Status = status;
}
public DownloadTaskStatusChangedEventArgs(DownloadTaskStatus status, DateTime scheduledFor)
{
Status = status;
ScheduledFor = scheduledFor;
}
public DownloadTaskStatusChangedEventArgs(DownloadTaskStatus status, double progress)
{
Status = status;
if (Status == DownloadTaskStatus.Downloading)
{
DownloadingProgress = progress;
}
else if (Status == DownloadTaskStatus.Processing)
{
ProcessingProgress = progress;
}
}
public DownloadTaskStatusChangedEventArgs(DownloadTaskStatus status, TimeSpan elapsedTime)
{
Status = status;
ElapsedTime = elapsedTime;
}
public DownloadTaskStatusChangedEventArgs(DownloadTaskStatus status, Exception exception)
{
Status = status;
Exception = exception;
}
#endregion
#region PROPERTIES
public DownloadTaskStatus Status { get; private set; }
public DateTime ScheduledFor { get; private set; }
public double DownloadingProgress { get; private set; }
public double ProcessingProgress { get; private set; }
public TimeSpan ElapsedTime { get; private set; }
public Exception Exception { get; private set; }
#endregion
}
}