DataServices和枚举类型。 [英] DataServices and enum type.
本文介绍了DataServices和枚举类型。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
是否有可能在dataservices中使用枚举属性?
谢谢,
Alexey Zakharov。
解决方案
不。 Edm不支持Enum属性。唯一的方法是拥有一个int / string属性并向partial类添加一个新属性,将其转换为客户端的枚举。
Pratik
Hi,
Is it possible to use enum properties in dataservices?
Thanks,
Alexey Zakharov.
解决方案
Nope. Edm doesn't have support for Enum properties. The only way would be to have a int/string property and add a new property to the partial class which converts this as a enum on the client side.
Thanks
Pratik
这篇关于DataServices和枚举类型。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文