我有一课,他们让我找主语、动词和宾语。我可以找到大多数我在1上的bug,他们没有告诉我们如何找到这些:下面是我的代码:
<?xml version="1.0" encoding="UTF-8"?>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:pcv="http://prismstandard.org/namespaces/pcv/1.0/"
xmlns:dc="http://purl.org/dc/elements/1.1/">
<rdf:Description rdf:about="http://wanderlust.com/2000/08/Corfu.jpg">
<dc:identifier rdf:resource="http://wanderlust.com/content/2357845" />
<dc:creator>
<pcv:Descriptor rdf:about="http://wanderlust.com/emp3845">
<pcv:label>John Peterson </pcv:label>
</pcv:Descriptor>
</dc:creator>
<dc:coverage>
<pcv:Descriptor
rdf:about="http://prismstandard.org/vocabs/ISO-3166/GR">
<pcv:label xml:lang="en">Greece</pcv:label>
<pcv:label xml:lang="fr">Grece</pcv:label>
</pcv:Descriptor>
</dc:coverage>
</rdf:Description>
</rdf:RDF>关于这一行:希腊,我认为:
-the的主题是:http://wanderlust.com/emp3845
-the动词是:http://prismstandard.org/namespaces/pcv/1.0/label
-the的目标是:“希腊”
,但是我能用xml:lang="en“做什么??,我能为这个找到一个对象吗?
谢谢
发布于 2013-12-06 13:44:18
严格地说,有两个对象:"Greece"@en和"Grece"@fr。如果使用面向人的RDF表示(如乌龟 ),则它将可见。
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix pcv: <http://prismstandard.org/namespaces/pcv/1.0/> .
@prefix dc: <http://purl.org/dc/elements/1.1/> .
<http://prismstandard.org/vocabs/ISO-3166/GR>
pcv:label "Grece"@fr, "Greece"@en ;
a pcv:Descriptor .
<http://wanderlust.com/2000/08/Corfu.jpg>
dc:coverage <http://prismstandard.org/vocabs/ISO-3166/GR> ;
dc:creator <http://wanderlust.com/emp3845> ;
dc:identifier <http://wanderlust.com/content/2357845> .
<http://wanderlust.com/emp3845>
pcv:label "John Peterson " ;
a pcv:Descriptor .所以,我们在这里看到的是,有三个学科。首先有两个“动词”(或“谓词”),其中一个有两个“对象”。
发布于 2013-12-04 18:45:01
RDF是在XML规范的范围内实现的。xml:lang=是xml规范的一个特性,它允许内容作者将元素的语言指定为属性。属性是在元素的开始标记的开始和结束<..>中出现的元素,用于细化或配置标记。它不是RDF的具体组成部分,也不是主语、动词或宾语。
这有一些具体的例子和解释:
https://www.w3.org/International/questions/qa-when-xmllang.en
https://stackoverflow.com/questions/20383228
复制相似问题