You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
|
using System;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.Linq;
|
|
|
|
|
using System.Text;
|
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
|
|
|
|
|
namespace Scheduler.Backgrounding
|
|
|
|
|
{
|
|
|
|
|
public static class Extensions
|
|
|
|
|
{
|
|
|
|
|
/// <summary> unique identifier, described by IntervalID + TaskBackgrounderID </summary>
|
|
|
|
|
public static string GetBGTaskID(this BGTaskInfo bgTEndEvent)
|
|
|
|
|
=> "id:" + bgTEndEvent.IntervalID + "-" + bgTEndEvent.TaskBackgrounderID;
|
|
|
|
|
|
|
|
|
|
/// <summary> unique identifier, described by IntervalID + TaskBackgrounderID </summary>
|
|
|
|
|
public static string GetBGTaskID(this BGTaskStartEvent bgTStartEvent)
|
|
|
|
|
=> "id:" + bgTStartEvent.IntervalID + "-" + bgTStartEvent.BGTaskGuid;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary> unique identifier, described by IntervalID + TaskBackgrounderID </summary>
|
|
|
|
|
public static string GetBGTaskID(this BGTaskEndEvent bgTEndEvent)
|
|
|
|
|
=> "id:" + bgTEndEvent.IntervalID + "-" + bgTEndEvent.BGTaskGuid;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary> unique identifier, described by IntervalID + TaskBackgrounderID </summary>
|
|
|
|
|
public static string GetBGTaskID<TResult>(this BGTaskEndEvent<TResult> bgTEndEvent)
|
|
|
|
|
=> "id:" + bgTEndEvent.IntervalID + "-" + bgTEndEvent.BGTaskGuid;
|
|
|
|
|
}
|
|
|
|
|
}
|