Open.Core.DelayedAction.Invoke C# (CSharp) Method

Invoke() public static method

Invokes the given action after the specified delay.
Returns the 'DelayedAction' used to invoke the method (can be used to cancel the delayed invoke operation).
public static Invoke ( double delay, System.Action action ) : DelayedAction
delay double The delay (in seconds) before invoking the action.
action System.Action The action to invoke.
return DelayedAction
        public static DelayedAction Invoke(double delay, Action action)
        {
            DelayedAction delayedAction = new DelayedAction(delay, action);
            delayedAction.Start();
            return delayedAction;
        }
        #endregion