开发者

Should DAO objects be Classes or Structs?

I wanted to know from a performance point of v开发者_运维知识库iew, should DAOs be classes or structs?

Taking into consideration that a lot of them might be created and they might be long lived objects.

What are your views and suggestions around the Data Layer design and using structs as DAOs


THey should be objects.

You should only build structs if you are building a value type. such as: example: id.

Other than that, you should use object for Data access.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜