public static IRelayCommand ViewModelExecute(this IExecution sender, IViewModelExecute execute, int timeout, [CallerMemberName] string name = "") { return(new RelayCommand(async(parameter) => { await ViewModelExecute(sender, operations: execute.Operations, handleTimeout: sender.HandleTimeout, handleUnhandledException: sender.HandleUnhandledException, insights: sender.Insights, notifyActivityFinished: sender.NotifyActivityFinished, notifyOfActivity: sender.NotifyOfActivity, timeoutMilliseconds: timeout == -1 ? execute.TimeoutMilliseconds : timeout, name: name, parameter: parameter); }) { Timeout = execute.TimeoutMilliseconds }); }
public static IRelayCommand ViewModelExecute(this IExecution sender, IViewModelExecute execute, [CallerMemberName] string name = "") { return new RelayCommand(async (parameter) => { await ViewModelExecute(sender, operations: execute.Operations, handleTimeout: sender.HandleTimeout, handleUnhandledException: sender.HandleUnhandledException, insights: sender.Insights, notifyActivityFinished: sender.NotifyActivityFinished, notifyOfActivity: sender.NotifyOfActivity, timeoutMilliseconds: execute.TimeoutMilliseconds, name: name, parameter: parameter); }) { Timeout = execute.TimeoutMilliseconds }; }
public static IRelayCommand ViewModelExecute(this IExecution sender, IViewModelExecute execute, [CallerMemberName] string name = "") { return(ViewModelExecute(sender, execute, -1, name)); }
public static IRelayCommand ViewModelExecute(this IExecution sender, IViewModelExecute execute, [CallerMemberName] string name = "", object precheck = null) { return(ViewModelExecute(sender, execute, -1, null, name, precheck)); }