[英]Does .NET have something like JAR in Java
I wonder whether there is in .NET something similar in Java JAR. 我想知道在Java JAR中是否存在类似的东西。 I am building a plugin system that loads the plugins.
我正在构建一个加载插件的插件系统。 It happens that a single plugins are referencing lot of external DLLs.
碰巧只有一个插件引用了很多外部DLL。 All this files are not compact.
所有这些文件都不紧凑。 I wonder if they can be packed or linked together into one DLL or one large package to achieve safer distribution.
我想知道它们是否可以打包或链接到一个DLL或一个大包中以实现更安全的分发。
The closest analogue to a JAR is the assembly. 与JAR最接近的类似物是装配。 An assembly contains a manifest, describing the contents.
程序集包含一个描述内容的清单。 There is nothing built in that will package several DLLs into one.
没有任何内置功能可以将多个DLL打包成一个。
However, for combining assemblies, you can look at ILMERGE . 但是,对于组合程序集,您可以查看ILMERGE 。
ILMerge is a utility that can be used to merge multiple .NET assemblies into a single assembly.
ILMerge是一个实用程序,可用于将多个.NET程序集合并到一个程序集中。
For building a plugin architecture, I suggest looking at MEF . 为了构建插件架构,我建议看一下MEF 。
In the roll your own scenario there is no reason why you couldn't have the code that detects dlls to also unzip them from any archive format 在你自己的场景中没有理由你不能拥有检测dll的代码也可以从任何存档格式解压缩它们
MEF is the plug in system for .NET that is popular but has the best support in 4.0 and higher. MEF是.NET的插件系统,很受欢迎,但在4.0及更高版本中具有最佳支持。
MonoAdd ins is a plugin system that was created by the Mono folk, but works on windows and gets some good reviews. MonoAdd ins是一个由Mono民间创建的插件系统,但在Windows上工作并获得一些好评。
MAF is a plugin system that is devilishly complicated to work with and is highly optimized for interop with MS-Office. MAF是一个插件系统,使用起来非常复杂,并且针对与MS-Office的互操作进行了高度优化。
NET compiles into dll or exe. NET编译成dll或exe。 You can use ILMerge to merge several dlls/exes into one.
您可以使用ILMerge将多个dll / exes合并为一个。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.