public IMethodResult CatchOverrideResult(string methodName, IMethodArgs args, Exception exception) { var result = new MethodResult(); if (methodName.Equals(nameof(IDoSomthing.GoTask))) { result.Set(Task.FromResult(777)); } else if (methodName.Equals(nameof(IDoSomthing.GetInteger))) { result.Set(777); } return(result); }