本文介绍了NET40-RequiresCastle和NET40版起订量之间的区别是什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在起订量的分布情况,有两个版本,NET4​​0-RequiresCastle和NET40。该NET40-RequiresCastle似乎有大小比​​NET40要小得多,但在运行时需要城堡。区别只是一个事实,即城堡里面嵌入了NET40版本,或者是有要在性能上的差异,使用情况等?

In the distribution of moq, there are two versions, NET40-RequiresCastle and NET40. The NET40-RequiresCastle seems to have much smaller size than the NET40, but requires Castle during runtime. Is the difference only the fact that Castle is embedded inside the NET40 version, or is there going to be difference in performance, usage, etc?

还有一个原因是使用NET40-RequiresCastle而不是NET40?

Is there a reason to use NET40-RequiresCastle instead of NET40?

推荐答案

起订量使用城堡DynamicProxy为代理生成。为了简化该DLL是部署IL合并成不需要城堡库可再发行。如果您已经使用了DynamicProxy库在您的项目,你会probabli使用RequireCastle分布,以避免两次部署该dll。如果您没有在项目中使用城堡别的地方,你可能preFER合并的,因为你有较少的DLL照顾的部署。

MoQ uses Castle DynamicProxy for proxy generation. In order to simplify the deploy that dll is "IL merged" into the redistributable that does not require Castle Library. If you already use the DynamicProxy library in your project you would probabli use the RequireCastle distribution, to avoid having the dll deployed twice. If you don't use Castle somewhere else in your project, you probably prefer the merged one, since you have less dll to take care in the deploy.

这篇关于NET40-RequiresCastle和NET40版起订量之间的区别是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-25 04:33