简体   繁体   English

使用Telerik OpenAccess从表生成枚举

[英]Generate Enums from Tables using Telerik OpenAccess

Reading the Telerik OpenAccess documentation, I see that I can set the data type of a Domain Class Property to an enumeration I have explicitly coded. 阅读Telerik OpenAccess文档后,我发现可以将域类属性的数据类型设置为我已明确编码的枚举。 Instead of coding them, can I use OpenAccess to generate (and maintain) enumeration types from my tables? 我可以使用OpenAccess从表中生成(和维护)枚举类型,而不是对它们进行编码吗?

The Enum generation based on a database table is not supported out of the box by the Telerik OpenAccess ORM but after a short search in Google I found this Blog Post demonstrating how to achieve that by a standalone code generation template. Telerik OpenAccess ORM不立即支持基于数据库表的Enum生成,但是在Google中进行短暂搜索后,我发现此Blog Post演示了如何通过独立的代码生成模板来实现该功能。

You could also add a feature request in the Ideas and Feedback portal of OpenAccess ORM for providing this functionality out of the box. 您还可以在OpenAccess ORM的“ 想法和反馈”门户中添加功能请求,以立即提供此功能。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM