如何设置DbMetal DataContext类的名字吗? [英] How to set the DataContext class name with DbMetal?
本文介绍了如何设置DbMetal DataContext类的名字吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
的DBLinq的DbMetal生成一个主
类继承的DataContext
。我不希望它是主
。如何改变这种状况?
DbLinq's DbMetal generates a Main
class which inherits DataContext
. I don't want it to be Main
. How to change that?
推荐答案
DbMetal总是会产生一类名为主
默认情况下。但是,您可以生成的.dbml时使用--database选项。
DbMetal will always generate a class called Main
by default. However, you can use the --database option when generating the .dbml.
抱歉:在SO发现这个在这里:<一href="http://stackoverflow.com/questions/3409241/why-does-dbmetal-generate-table-attribute-with-main">Why并DbMetal生成表属性与主?
Oops: found this here in SO: Why does DbMetal Generate Table Attribute with "main"?
这篇关于如何设置DbMetal DataContext类的名字吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文