在 python 中使用撒克逊 [英] Use saxon with python

查看:42
本文介绍了在 python 中使用撒克逊的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要使用 python 处理 XSLT,目前我使用的 lxml 只支持 XSLT 1,现在我需要处理 XSLT 2 有没有办法在 python 中使用 saxon XSLT 处理器?

I need to process XSLT using python, currently I'm using lxml which only support XSLT 1, now I need to process XSLT 2 is there any way to use saxon XSLT processor with python?

推荐答案

有两种可能的方法:

  1. 设置一个接受转换请求的HTTP服务,并通过从Java调用Saxon来实现;然后,您可以通过 HTTP 从 Python 发送转换请求

  1. set up an HTTP service that accepts tranformation requests and implements them by invoking Saxon from Java; you can then send the transformation requests from Python over HTTP

使用 Saxon/C 产品,目前在预发布中提供:详情请见:http://www.saxonica.com/saxon-c/index.xml

use the Saxon/C product, currently available on prerelease: details here: http://www.saxonica.com/saxon-c/index.xml

这篇关于在 python 中使用撒克逊的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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