多个 Assembly.Load(Byte[]),相同实例还是泄漏?

发布于 2024-08-06 23:59:26 字数 124 浏览 2 评论 0原文

当我使用包含相同程序集的 Byte 数组多次调用 Assembly.Load(Byte[]) 时会发生什么?

每次调用我都会获得相同的 Assembly 实例吗?

同一程序集在应用程序域内加载多次???

What happens when I call Assembly.Load(Byte[]) multiple times with a Byte array containing the same assembly ?

Will I get the same instance of Assembly for each call ?

The same assembly loaded multiple times within the app domain ???

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

梦里梦着梦中梦 2024-08-13 23:59:26

每次调用您都会获得一个新的 Assembly 对象,请阅读文档 ,在末尾附近有一条注释:

“请注意,此方法重载始终会创建一个具有自己的映射的新 Assembly 对象。”

You will get a new Assembly object with each call, read the documentation, there is a note near the end:

"Note that this method overload always creates a new Assembly object with its own mapping."

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文