Is AutoMapper case sensitive or insensitive?

浪子不回头ぞ 提交于 2019-12-10 00:45:48

问题


If object a has a property named 'Id' and object b has a property named 'ID', will AutoMapper correctly map the two properties (without doing a .ForMember(...) call)?


回答1:


The trunk version is now default case-insensitive, and supports multiple naming conventions (camelCase, lowercase_underscore, etc). Look for this in the next version of AutoMapper, which should drop in a couple of days.




回答2:


No, last time I tried it (month or so ago) it was case sensitive.



来源:https://stackoverflow.com/questions/1370128/is-automapper-case-sensitive-or-insensitive

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!