是否有任何 XSLT 和 XQuery 处理器可用于 .NET Core 3.0 应用程序? [英] Are there any XSLT and XQuery Processors available for .NET Core 3.0 apps?

查看:25
本文介绍了是否有任何 XSLT 和 XQuery 处理器可用于 .NET Core 3.0 应用程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在使用 Saxon XSLT 和 XQuery 处理器 - 免费家庭版我的 .NET 应用程序.我只需要 XSLT 2.0(因为 .NET 不支持 XSLT 3.0).现在我已经从 .NET Framework 转移到 .NET Core,我注意到 Saxon 还不支持 .NETCore 因为在为 Saxon 安装 Nuget 包时,我收到以下错误.

I've been using Saxon XSLT and XQuery processor - Free home edition for some of my .NET apps. I need only XSLT 2.0 (since .NET does not support XSLT 3.0). Now that I've moved from .NET Framework to .NET Core, I noticed that the Saxon has not yet supported .NET Core since when installing a Nuget package for Saxon, I get the following error.

问题:是否有人知道我可以将其他替代方案用于需要 XSLT 2.0 和 XQuery 处理的 .NET Core 项目?

Question: Are there other alternatives that someone knows I can use for my .NET Core projects that need XSLT 2.0 and XQuery processing?

由于以下错误,我的代码无法编译,因为它无法识别 XdmNodeXsltTransformer

Because of the following error my code does not compile since it does not recognize XdmNode, XsltTransformer, etc.

使用 '.NETFramework,Version=v4.6.1, .NETFramework,Version=v4.6.2, .NETFramework,Version=v4.7, .NETFramework,Version=v4 恢复包Saxon-HE 9.9.1.5".7.1, .NETFramework,Version=v4.7.2, .NETFramework,Version=v4.8' 而不是项目目标框架'.NETCoreApp,Version=v3.0'.此软件包可能与您的项目不完全兼容.

Package 'Saxon-HE 9.9.1.5' was restored using '.NETFramework,Version=v4.6.1, .NETFramework,Version=v4.6.2, .NETFramework,Version=v4.7, .NETFramework,Version=v4.7.1, .NETFramework,Version=v4.7.2, .NETFramework,Version=v4.8' instead of the project target framework '.NETCoreApp,Version=v3.0'. This package may not be fully compatible with your project.

推荐答案

XmlPrime https://www.xmlprime.com/xmlprime/ 是 XQuery 3.1 和 XSLT 2.0 的纯 .NET 实现,它是为 .NET 框架开发的,最新版本 4 也可以与 Mono 一起使用.

XmlPrime https://www.xmlprime.com/xmlprime/ is a pure .NET implementation of XQuery 3.1 and XSLT 2.0, it was developed for the .NET framework and the latest version 4 also to work with Mono.

我已经安装了 4.1 的当前试用版,并使用 VS 2019 编写了一个 .NET Core 3 控制台应用程序,其中我添加了 XmlPrime 安装目录的两个程序集 XmlPrime.dll 和 XmlPrime.ExtensionMethods.dll 作为对.NET 核心项目.

I have installed the current trial version of 4.1 and have written a .NET Core 3 console application with VS 2019 where I have added the two assemblies XmlPrime.dll and XmlPrime.ExtensionMethods.dll of the XmlPrime installation directory as references to the .NET core project.

两个简单的例子改编自 https://github.com/XmlPrime/Examples/tree/master/Queryhttps://github.com/XmlPrime/Example/tree/master/Transform 然后运行良好以在 .NET Core 3 应用程序中执行 XQuery 3 和 XSLT 2.

Two simple examples adapted from https://github.com/XmlPrime/Examples/tree/master/Query and https://github.com/XmlPrime/Examples/tree/master/Transform then run fine to execute XQuery 3 and XSLT 2 in the .NET Core 3 app.

所以从技术上讲,XmlPrime,至少有一些表面测试,似乎是 .NET Core 3 的一个选项,但是我不知道他们项目的状态,据我所知他们只是偶尔更新他们的试用版并且有停止在线销售商业许可证.您可能需要查询https://www.xmlprime.com/xmlprime/的联系方式contact.htm 询问他们是否以其他方式出售完整许可.

So technically XmlPrime, at least with some superficial tests, seems an option for .NET Core 3, I don't know about the state of their project however, as far as I know they only occasionally update their trial version and have stopped to sell commercial licenses online. You might need to enquire at the contact details of https://www.xmlprime.com/xmlprime/contact.htm to ask whether they sell full licenses some other way.

这篇关于是否有任何 XSLT 和 XQuery 处理器可用于 .NET Core 3.0 应用程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆