Ejemplo n.º 1
0
        public SourceMemberConfig FindOrCreateSourceMemberConfigFor(MemberInfo sourceMember)
        {
            var config = _sourceMemberConfigs.FirstOrDefault(smc => smc.SourceMember == sourceMember);

            if (config == null)
            {
                config = new SourceMemberConfig(sourceMember);
                _sourceMemberConfigs.Add(config);
            }

            return(config);
        }
Ejemplo n.º 2
0
        public SourceMemberConfig FindOrCreateSourceMemberConfigFor(MemberInfo sourceMember)
        {
            var config = _sourceMemberConfigs.GetOrDefault(sourceMember);

            if (config != null)
            {
                return(config);
            }

            config = new SourceMemberConfig(sourceMember);
            AddSourceMemberConfig(config);
            return(config);
        }
Ejemplo n.º 3
0
        public SourceMemberConfig FindOrCreateSourceMemberConfigFor(MemberInfo sourceMember)
        {
            var config = _sourceMemberConfigs.FirstOrDefault(smc => Equals(smc.SourceMember, sourceMember));

            if (config != null)
            {
                return(config);
            }

            config = new SourceMemberConfig(sourceMember);
            _sourceMemberConfigs.Add(config);

            return(config);
        }
Ejemplo n.º 4
0
        public SourceMemberConfig FindOrCreateSourceMemberConfigFor(MemberInfo sourceMember)
        {
            var config = _sourceMemberConfigs.FirstOrDefault(smc => smc.SourceMember == sourceMember);
            if (config == null)
            {
                config = new SourceMemberConfig(sourceMember);
                _sourceMemberConfigs.Add(config);
            }

            return config;
        }
Ejemplo n.º 5
0
 public SourceMappingExpression(TypeMap typeMap, MemberInfo sourceMember)
 {
     _sourcePropertyConfig = typeMap.FindOrCreateSourceMemberConfigFor(sourceMember);
 }
Ejemplo n.º 6
0
 private void AddSourceMemberConfig(SourceMemberConfig config) => _sourceMemberConfigs.Add(config.SourceMember, config);
Ejemplo n.º 7
0
        public SourceMemberConfig FindOrCreateSourceMemberConfigFor(MemberInfo sourceMember)
        {
            var config = _sourceMemberConfigs.FirstOrDefault(smc => Equals(smc.SourceMember, sourceMember));

            if (config != null) return config;

            config = new SourceMemberConfig(sourceMember);
            _sourceMemberConfigs.Add(config);

            return config;
        }
Ejemplo n.º 8
0
            public SourceMappingExpression(TypeMap typeMap, LambdaExpression sourceMember)
            {
                var memberInfo = ReflectionHelper.FindProperty(sourceMember);

                _sourcePropertyConfig = typeMap.FindOrCreateSourceMemberConfigFor(memberInfo);
            }