Method InvokeMethodAndLogResult
InvokeMethodAndLogResult(object?, MethodInfo?)
Invokes the specified method on the given instance and logs the result.
public static bool InvokeMethodAndLogResult(object? instance, MethodInfo? method)
Parameters
instance
objectThe object instance on which the method should be invoked. Can be null for static methods.
method
MethodInfoThe method to invoke. If null or requires parameters, invocation is skipped.
Returns
- bool
true
if the method was successfully invoked and logged; otherwise,false
.