Class CommonUtils
Common utility methods. May be useful when developing simulator connectors
public static class CommonUtils
- Inheritance
-
CommonUtils
- Inherited Members
Methods
ConnectorsToExternalIds(Dictionary<string, long>, string)
Function to convert list of connectors to externalIds
public static List<string> ConnectorsToExternalIds(Dictionary<string, long> simulators, string baseConnectorName)
Parameters
simulators
Dictionary<string, long>object of simulator connectors
baseConnectorName
stringthe base connector name to which prefix will be appended
Returns
GetAssemblyVersion()
Returns the assembly version
public static string GetAssemblyVersion()
Returns
RunAll(IEnumerable<Task>, CancellationTokenSource)
Run all of the tasks in this enumeration. If any fail or is canceled, cancel the remaining tasks and return. The first found exception is thrown
public static Task RunAll(this IEnumerable<Task> tasks, CancellationTokenSource tokenSource)
Parameters
tasks
IEnumerable<Task>List of tasks to run
tokenSource
CancellationTokenSourceSource of cancellation tokens