public override object GetValue()
        {
            if (_method == null)
            {
                return(null);
            }

            object targetValue = _target.GetValue();

            if (NullHelper.IsNull(targetValue))
            {
                return(null);
            }

            object[] argumentValues = new object[_arguments.Length];

            for (int i = 0; i < argumentValues.Length; i++)
            {
                argumentValues[i] = _arguments[i].GetValue();
            }

            object result;

            try
            {
                result = _method.Invoke(targetValue, argumentValues);
            }
            catch (TargetInvocationException ex)
            {
                // Special handling for target invocation since we are only
                // interested in the inner one.
                throw ExceptionBuilder.MethodBindingInvokeFailed(ex.InnerException);
            }
            catch (NQueryException)
            {
                throw;
            }
            catch (Exception ex)
            {
                throw ExceptionBuilder.MethodBindingInvokeFailed(ex);
            }

            return(NullHelper.UnifyNullRepresentation(result));
        }