C# Класс Ensage.Common.DelayAction

Delays actions by a set time.
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
Add ( DelayActionItem item ) : void

Adds a new delayed action.

Add ( float time, System.Action func ) : void

Adds a new delayed action, casting the time to an integer.

Add ( float time, System.Action func, CancellationToken token ) : void

Adds a new delayed action with a cancelation token. Use the CancellationTokenSource class for tokens.

Add ( int time, System.Action func ) : void

Adds a new delayed action.

Add ( int time, System.Action func, CancellationToken token ) : void

Adds a new delayed action with a cancelation token. Use the CancellationTokenSource class for tokens.

Описание методов

Add() публичный статический Метод

Adds a new delayed action.
public static Add ( DelayActionItem item ) : void
item DelayActionItem The to add.
Результат void

Add() публичный статический Метод

Adds a new delayed action, casting the time to an integer.
public static Add ( float time, System.Action func ) : void
time float The time(in milliseconds) to call the function.
func System.Action The function to call once the has expired.
Результат void

Add() публичный статический Метод

Adds a new delayed action with a cancelation token. Use the CancellationTokenSource class for tokens.
public static Add ( float time, System.Action func, CancellationToken token ) : void
time float The time(in milliseconds) to call the function. (Gets casted into an integer)
func System.Action The function to call once the has expired.
token System.Threading.CancellationToken The cancelation token.
Результат void

Add() публичный статический Метод

Adds a new delayed action.
public static Add ( int time, System.Action func ) : void
time int Delayed Time
func System.Action Callback Function
Результат void

Add() публичный статический Метод

Adds a new delayed action with a cancelation token. Use the CancellationTokenSource class for tokens.
public static Add ( int time, System.Action func, CancellationToken token ) : void
time int The time(in milliseconds) to call the function.
func System.Action The function to call once the has expired.
token System.Threading.CancellationToken The cancelation token.
Результат void