Starting from WinSW 2.0, the wrapper provides an internal extension engine and several extensions. These extensions allow to alter the behavior of the Windows service in order to setup the required service environment.
In the current versions of WinSW the extension does not support inclusion of external extension DLLs.
The only way to create an external extension is to create a new extension DLL and
then to merge this DLL into the executable using tools like ILMerge
.
See the example in src/Core/ServiceWrapper/winsw.csproj
.
Generic extension creation guideline:
WinSWCore
library.AbstractWinSWExtension
class.XmlNode
.WinSW engine will automatically locate your extension using the class name in the XML configuration file.
See configuration samples provided for the extensions in the core.
For extensions from external DLLs, the className
field should also specify the assembly name.
It can be done via fully qualified class name or just by the ${CLASS_NAME}, ${ASSEMBLY_NAME}
declaration.
Please note that in the current versions of WinSW the binary compatibility of extension APIs is not guaranteed.
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。