public void ExecuteAction(Action action) { action.SomeOrNone().Into(value => value()); }
public ActionResult ExecuteActionWithResult(Action action) { var option = action.SomeOrNone().Into(value => StopwatchHelper.ExecuteTimedActionWithResult(action)); return option.Or(new ActionResult {Status = ResultStatus.Error }).First(); }