예제 #1
0
        public ExecutionResult ExecuteMethod(MethodInfo method, params object[] args)
        {
            var executionResult = new ExecutionResult {
                Success = true
            };
            var instance = ClassInstanceManager.Get(method.DeclaringType);

            try
            {
                method.Invoke(instance, args);
            }
            catch (TargetInvocationException ex)
            {
                var innerException = ex.InnerException;
                executionResult.ExceptionMessage = innerException.Message;
                executionResult.StackTrace       = innerException.StackTrace;
                executionResult.Source           = innerException.Source;
                executionResult.Success          = false;
            }
            return(executionResult);
        }
예제 #2
0
 public void ClearObjectCache()
 {
     ClassInstanceManager.ClearCache();
 }