public ExpressionResolutionResult GetExpressionResolutionResult( ExpressionResolutionResult expressionResolutionResult, PropertyMap propertyMap, IValueResolver valueResolver) { var currentChild = expressionResolutionResult.ResolutionExpression; var currentChildType = expressionResolutionResult.Type; var nullSubstitute = propertyMap.NullSubstitute; var newParameter = expressionResolutionResult.ResolutionExpression; var converter = new NullSubstitutionConversionVisitor(newParameter, nullSubstitute); currentChild = converter.Visit(currentChild); currentChildType = currentChildType.GetTypeOfNullable(); return new ExpressionResolutionResult(currentChild, currentChildType); }
public bool CanGetExpressionResolutionResult(ExpressionResolutionResult expressionResolutionResult, IValueResolver valueResolver) { return valueResolver is NullReplacementMethod && expressionResolutionResult.Type.IsNullableType(); }