在Java中嵌入XQuery [英] Embedding XQuery in Java

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

问题描述

我需要从Java中的MusicXML(xml)文件中检索一些详细信息. 我设法通过Java读取了xml文件-但是通过Web服务(我必须在线,在运行代码时必须连接到Internet)来读取XML文件. 我遇到了XQuery,您可以在其中轻松地从XML文件提取信息.但是我需要在Java中嵌入XQuery(即在Java代码中使用xquery),而不需要使用Web服务. 有什么可能的方法,如何在Java代码中嵌入XQuery(从XML文件读取信息)?

I need to retrieve some details from a MusicXML (xml) file in Java. I managed to read xml files in java - but through a web service (where I have to be online, connected to internet when I'm running my code). I came across XQuery where you can easily extract info from an XML file. But I need to embed XQuery in java (i.e. use xquery in java code), precise without using a web service. Is there any possible way, how I can embed XQuery (reading info from XML file), in java code?

非常感谢您的任何见解,建议和想法. 提前非常感谢

Greatly appreciate any insight, suggestions and ideas. Many thanks in advance

推荐答案

使用 XQJ (XQuery for Java API).网上有各种使用XQJ的教程.

Use XQJ (XQuery for Java API). There are various tutorials for using XQJ on the web.

这篇关于在Java中嵌入XQuery的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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