XML到RDF:使用JENA GRDDL [英] XML to RDF : using JENA GRDDL

查看:198
本文介绍了XML到RDF:使用JENA GRDDL的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想将xml文件转换为RDF. 我认为可以使用JENA GRDDL,但我不知道它是如何工作的!我没有发现任何例子! 您能帮我开始使用此API或向我显示任何可能的解决方案吗!

I want to transform xml files to RDF. I think that JENA GRDDL can be used ,but I don't know how it works ! and I did not found any examples ! can you help me please to start using this API or show me any possible solutions !

推荐答案

您可以使用XSLT将XML文件转换为RDF,通常针对RDF/XML(例如,参见

You can transform XML files to RDF using XSLT, typically targeting RDF/XML (see, e.g., Using jena for creating RDF from XMl file). Jena can then read the resulting file.

您甚至可以直接使用SAXResult

You can even streamline this process and parse the result of the XSLT transformation directly using a SAXResult and SAX2Model.

GRDDL(请参见优秀的引物)对该过程进行了标准化.它提供了一种发现给定XML文档的XSLT转换的方法:直接使用grddl:transformation,或使用xml命名空间模式或html概要文件间接发现一类文档. (有关详细信息,请参见 GRDDL规范)

GRDDL (see the excellent primer) standardises this procedure. It provides a way to discover an XSLT transformation for a given XML document: either directly using grddl:transformation, or indirectly for a class of documents using xml namespace schemas or html profiles. (see the GRDDL spec for the details)

因此GRDDL并不能真正为您提供帮助:您仍然需要为文件编写转换.

So GRDDL doesn't really help you as such: you still need to write the transformation for your files.

这篇关于XML到RDF:使用JENA GRDDL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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