public void AddConditionOrThrow(LambdaExpression conditionLambda)
        {
            ErrorIfConditionHasTypeTest(conditionLambda);
            FixEnumComparisonsIfNecessary(ref conditionLambda);

            _conditionLambda = ConfiguredLambdaInfo.For(conditionLambda);
        }
Exemple #2
0
        public bool IsSameAs(ConfiguredLambdaInfo otherLambdaInfo)
        {
            if (otherLambdaInfo == null)
            {
                return(false);
            }

            if ((_lambda.Body.NodeType == ExpressionType.Invoke) ||
                (otherLambdaInfo._lambda.Body.NodeType == ExpressionType.Invoke))
            {
                return(false);
            }

            return(ExpressionEvaluation.AreEquivalent(_lambda.Body, otherLambdaInfo._lambda.Body));
        }
Exemple #3
0
 public ConfiguredObjectFactory(MappingConfigInfo configInfo, ConfiguredLambdaInfo factoryInfo)
     : base(configInfo)
 {
     _factoryInfo = factoryInfo;
 }
 public bool IsSameAs(ConfiguredLambdaInfo otherLambdaInfo)
 => _lambda.ToString() == otherLambdaInfo._lambda.ToString();