How to adjust field names in Nancy model bindings?

為{幸葍}努か 提交于 2019-12-04 06:15:40

Support for this is there, but it's not as fully featured as I'd like.

If you take a look at the IFieldNameConverter interface (it's default implementation is DefaultFieldNameConverter), that's what handles converting field names for things like casing.

For more complicated mappings you'd have to implement an ITypeConverter, you could just "wrap" the default converter(s) - depending on your data - and alter the input before calling the default one.

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