Пример #1
0
        public DictionarySettings(MapperContext mapperContext)
        {
            _joiningNameFactories = new List <JoiningNameFactory>
            {
                JoiningNameFactory.UnderscoredForSourceDynamics(mapperContext),
                JoiningNameFactory.UnderscoredForTargetDynamics(mapperContext),
                JoiningNameFactory.Dotted(mapperContext)
            };

            _elementKeyPartFactories = new List <ElementKeyPartFactory>
            {
                ElementKeyPartFactory.UnderscoredIndexForSourceDynamics(mapperContext),
                ElementKeyPartFactory.UnderscoredIndexForTargetDynamics(mapperContext),
                ElementKeyPartFactory.SquareBracketedIndex(mapperContext)
            };
        }
        public void Add(ElementKeyPartFactory keyPartFactory)
        {
            ThrowIfConflictingKeyPartFactoryExists(keyPartFactory, _elementKeyPartFactories);

            _elementKeyPartFactories.Insert(0, keyPartFactory);
        }