新书推介:《语义网技术体系》
作者:瞿裕忠,胡伟,程龚
   XML论坛     >>W3CHINA.ORG讨论区<<     计算机科学论坛     SOAChina论坛     Blog     开放翻译计划     新浪微博  
 
  • 首页
  • 登录
  • 注册
  • 软件下载
  • 资料下载
  • 核心成员
  • 帮助
  •   Add to Google

    >> 本版讨论Semantic Web(语义Web,语义网或语义万维网, Web 3.0)及相关理论,如:Ontology(本体,本体论), OWL(Web Ontology Langauge,Web本体语言), Description Logic(DL, 描述逻辑),RDFa,Ontology Engineering等。
    [返回] W3CHINA.ORG讨论区 - 语义网·描述逻辑·本体·RDF·OWLW3CHINA.ORG讨论区 - Web新技术讨论『 Semantic Web(语义Web)/描述逻辑/本体 』 → [求助]读owl内的属性 查看新帖用户列表

      发表一个新主题  发表一个新投票  回复主题  (订阅本版) 您是本帖的第 8179 个阅读者浏览上一篇主题  刷新本主题   树形显示贴子 浏览下一篇主题
     * 贴子主题: [求助]读owl内的属性 举报  打印  推荐  IE收藏夹 
       本主题类别: Ontology Language | RDF/RDFS    
     jiangqiangln 帅哥哟,离线,有人找我吗?
      
      
      等级:大一(高数修炼中)
      文章:34
      积分:162
      门派:XML.ORG.CN
      注册:2009/10/9

    姓名:(无权查看)
    城市:(无权查看)
    院校:(无权查看)
    给jiangqiangln发送一个短消息 把jiangqiangln加入好友 查看jiangqiangln的个人资料 搜索jiangqiangln在『 Semantic Web(语义Web)/描述逻辑/本体 』的所有贴子 引用回复这个贴子 回复这个贴子 查看jiangqiangln的博客楼主
    发贴心情 [求助]读owl内的属性

    owl文件如下,请问如何才能读取到hastitile的值:
    <?xml version="1.0"?>
    <rdf:RDF
        xmlns:pub="http://www.domain2.com#"
        xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
        xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
        xmlns:owl="http://www.w3.org/2002/07/owl#"
        xmlns="http://www.owl-ontologies.com/unnamed.owl#"
      xml:base="http://www.owl-ontologies.com/unnamed.owl">
      <owl:Ontology rdf:about=""/>
      <owl:Class rdf:about="http://www.domain2.com#Person"/>
      <owl:Class rdf:about="http://www.domain2.com#Publication"/>
      <owl:Class rdf:about="http://www.domain2.com#Article"/>
      <owl:ObjectProperty rdf:about="http://www.domain2.com#isCited">
        <rdfs:domain rdf:resource="http://www.domain2.com#Article"/>
        <owl:inverseOf>
          <owl:ObjectProperty rdf:about="http://www.domain2.com#Citing"/>
        </owl:inverseOf>
        <rdfs:range rdf:resource="http://www.domain2.com#Article"/>
      </owl:ObjectProperty>
      <owl:ObjectProperty rdf:about="http://www.domain2.com#hasAuthor">
        <rdfs:range rdf:resource="http://www.domain2.com#Person"/>
        <rdfs:domain rdf:resource="http://www.domain2.com#Article"/>
      </owl:ObjectProperty>
      <owl:ObjectProperty rdf:about="http://www.domain2.com#isPublished">
        <rdfs:range rdf:resource="http://www.domain2.com#Publication"/>
        <rdfs:domain rdf:resource="http://www.domain2.com#Article"/>
      </owl:ObjectProperty>
      <owl:ObjectProperty rdf:about="http://www.domain2.com#Citing">
        <rdfs:domain rdf:resource="http://www.domain2.com#Article"/>
        <owl:inverseOf rdf:resource="http://www.domain2.com#isCited"/>
        <rdfs:range rdf:resource="http://www.domain2.com#Article"/>
      </owl:ObjectProperty>
      <owl:DatatypeProperty rdf:about="http://www.domain2.com#keywords">
        <rdfs:range rdf:resource="http://www.w3.org/2001/XMLSchema#string"/>
        <rdfs:domain rdf:resource="http://www.domain2.com#Article"/>
      </owl:DatatypeProperty>
      <owl:DatatypeProperty rdf:about="http://www.domain2.com#hasTitle">
        <rdfs:range rdf:resource="http://www.w3.org/2001/XMLSchema#string"/>
        <rdfs:domain rdf:resource="http://www.domain2.com#Article"/>
      </owl:DatatypeProperty>
      <owl:DatatypeProperty rdf:about="http://www.domain2.com#content">
        <rdfs:domain rdf:resource="http://www.domain2.com#Article"/>
        <rdfs:range rdf:resource="http://www.w3.org/2001/XMLSchema#string"/>
      </owl:DatatypeProperty>
      <owl:SymmetricProperty rdf:about="http://www.domain2.com#bothCited">
        <owl:inverseOf rdf:resource="http://www.domain2.com#bothCited"/>
        <rdfs:range rdf:resource="http://www.domain2.com#Article"/>
        <rdf:type rdf:resource="http://www.w3.org/2002/07/owl#ObjectProperty"/>
        <rdfs:domain rdf:resource="http://www.domain2.com#Article"/>
      </owl:SymmetricProperty>
      <owl:SymmetricProperty rdf:about="http://www.domain2.com#bothCiting">
        <rdfs:domain rdf:resource="http://www.domain2.com#Article"/>
        <rdf:type rdf:resource="http://www.w3.org/2002/07/owl#ObjectProperty"/>
        <owl:inverseOf rdf:resource="http://www.domain2.com#bothCiting"/>
        <rdfs:range rdf:resource="http://www.domain2.com#Article"/>
      </owl:SymmetricProperty>
      <pub:Publication rdf:ID="Info.Sci."/>
      <pub:Person rdf:ID="Tom"/>
      <pub:Article rdf:ID="KB_757266_Individual_5">
        <pub:content rdf:datatype="http://www.w3.org/2001/XMLSchema#string">URI is BBBBBBBBBBBBBBBBBBBBBBBBBBB</pub:content>
        <pub:isCited>
          <pub:Article rdf:ID="KB_757266_Individual_3">
            <pub:hasTitle rdf:datatype="http://www.w3.org/2001/XMLSchema#string">RDF</pub:hasTitle>
            <pub:isPublished rdf:resource="#Info.Sci."/>
            <pub:content rdf:datatype="http://www.w3.org/2001/XMLSchema#string">RDF is JJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJ</pub:content>
            <pub:keywords rdf:datatype="http://www.w3.org/2001/XMLSchema#string">RDF</pub:keywords>
            <pub:Citing>
              <pub:Article rdf:ID="KB_757266_Individual_2">
                <pub:hasTitle rdf:datatype="http://www.w3.org/2001/XMLSchema#string">XML</pub:hasTitle>
                <pub:isCited rdf:resource="#KB_757266_Individual_3"/>
                <pub:isPublished rdf:resource="#Info.Sci."/>
                <pub:content rdf:datatype="http://www.w3.org/2001/XMLSchema#string">XML is AAAAAAAAAAAAAAAAAAAAAAAAAAA</pub:content>
                <pub:hasAuthor>
                  <pub:Person rdf:ID="Jack"/>
                </pub:hasAuthor>
                <pub:Citing rdf:resource="#KB_757266_Individual_5"/>
                <pub:keywords rdf:datatype="http://www.w3.org/2001/XMLSchema#string">XML</pub:keywords>
                <pub:Citing>
                  <pub:Article rdf:ID="KB_757266_Individual_6">
                    <pub:isCited>
                      <pub:Article rdf:ID="KB_757266_Individual_4">
                        <pub:Citing rdf:resource="#KB_757266_Individual_3"/>
                        <pub:hasAuthor rdf:resource="#Tom"/>
                        <pub:Citing rdf:resource="#KB_757266_Individual_5"/>
                        <pub:content rdf:datatype="http://www.w3.org/2001/XMLSchema#string">OWL is GGGGGGGGGGGGGGGGGGgg</pub:content>
                        <pub:Citing rdf:resource="#KB_757266_Individual_2"/>
                        <pub:keywords rdf:datatype="http://www.w3.org/2001/XMLSchema#string">OWL</pub:keywords>
                        <pub:isPublished rdf:resource="#Info.Sci."/>
                        <pub:hasTitle rdf:datatype="http://www.w3.org/2001/XMLSchema#string">OWL</pub:hasTitle>
                        <pub:Citing rdf:resource="#KB_757266_Individual_6"/>
                      </pub:Article>
                    </pub:isCited>
                    <pub:keywords rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Unicode</pub:keywords>
                    <pub:isCited rdf:resource="#KB_757266_Individual_2"/>
                    <pub:content rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Unicode is CCCCCCCCCCCCCCCCCCCCCcc</pub:content>
                    <pub:hasTitle rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Unicode</pub:hasTitle>
                    <pub:hasAuthor>
                      <pub:Person rdf:ID="peter"/>
                    </pub:hasAuthor>
                    <pub:isPublished rdf:resource="#Info.Sci."/>
                    <pub:isCited rdf:resource="#KB_757266_Individual_3"/>
                  </pub:Article>
                </pub:Citing>
                <pub:isCited rdf:resource="#KB_757266_Individual_4"/>
              </pub:Article>
            </pub:Citing>
            <pub:hasAuthor rdf:resource="#Jack"/>
            <pub:Citing rdf:resource="#KB_757266_Individual_5"/>
            <pub:Citing rdf:resource="#KB_757266_Individual_6"/>
            <pub:isCited rdf:resource="#KB_757266_Individual_4"/>
          </pub:Article>
        </pub:isCited>
        <pub:isCited rdf:resource="#KB_757266_Individual_4"/>
        <pub:hasAuthor rdf:resource="#peter"/>
        <pub:isPublished rdf:resource="#Info.Sci."/>
        <pub:keywords rdf:datatype="http://www.w3.org/2001/XMLSchema#string">URI</pub:keywords>
        <pub:isCited rdf:resource="#KB_757266_Individual_2"/>
        <pub:hasTitle rdf:datatype="http://www.w3.org/2001/XMLSchema#string">URI</pub:hasTitle>
      </pub:Article>
    </rdf:RDF>

    <!-- Created with Protege (with OWL Plugin 1.3, Build 212)  http://protege.stanford.edu -->


       收藏   分享  
    顶(0)
      




    点击查看用户来源及管理<br>发贴IP:*.*.*.* 2009/10/18 13:48:00
     
     jiangqiangln 帅哥哟,离线,有人找我吗?
      
      
      等级:大一(高数修炼中)
      文章:34
      积分:162
      门派:XML.ORG.CN
      注册:2009/10/9

    姓名:(无权查看)
    城市:(无权查看)
    院校:(无权查看)
    给jiangqiangln发送一个短消息 把jiangqiangln加入好友 查看jiangqiangln的个人资料 搜索jiangqiangln在『 Semantic Web(语义Web)/描述逻辑/本体 』的所有贴子 引用回复这个贴子 回复这个贴子 查看jiangqiangln的博客2
    发贴心情 
    select ?book ?hasName
    from  <http://vision.pku.edu.cn/test.owl>
    where
    {
    ?book test:hasName ?hasName.
    }
    结果是:
    http://vision.pku.edu.cn/test.owl#B008 数据库@zh 

    http://vision.pku.edu.cn/test.owl#A004 李四@zh 

    http://vision.pku.edu.cn/test.owl#A002 王二@zh 

    http://vision.pku.edu.cn/test.owl#B003 城域网@zh 

    http://vision.pku.edu.cn/test.owl#A003 张三@zh 

    http://vision.pku.edu.cn/test.owl#B004 数字图书馆@zh 

    http://vision.pku.edu.cn/test.owl#B001 计算机@zh 

    http://vision.pku.edu.cn/test.owl#P002 北京大学@zh 

    http://vision.pku.edu.cn/test.owl#B005 数据挖掘@zh 

    http://vision.pku.edu.cn/test.owl#P005 人民大学@zh 

    http://vision.pku.edu.cn/test.owl#P003 清华大学@zh 

    http://vision.pku.edu.cn/test.owl#A001 赵大@zh 

    http://vision.pku.edu.cn/test.owl#B007 编程珠玑@zh 

    http://vision.pku.edu.cn/test.owl#B006 机器学习@zh 

    http://vision.pku.edu.cn/test.owl#A005 马五@zh 

    http://vision.pku.edu.cn/test.owl#B002 局域网@zh 

    http://vision.pku.edu.cn/test.owl#P001 机械工业@zh 

    http://vision.pku.edu.cn/test.owl#P004 电子工业@zh 

    http://vision.pku.edu.cn/test.owl#B009 SQL Server 指南@zh

    但是我只想读取book及其hasname,应如何改呢?

    点击查看用户来源及管理<br>发贴IP:*.*.*.* 2009/10/18 15:31:00
     
     GoogleAdSense
      
      
      等级:大一新生
      文章:1
      积分:50
      门派:无门无派
      院校:未填写
      注册:2007-01-01
    给Google AdSense发送一个短消息 把Google AdSense加入好友 查看Google AdSense的个人资料 搜索Google AdSense在『 Semantic Web(语义Web)/描述逻辑/本体 』的所有贴子 访问Google AdSense的主页 引用回复这个贴子 回复这个贴子 查看Google AdSense的博客广告
    2024/4/19 6:42:02

    本主题贴数2,分页: [1]

    管理选项修改tag | 锁定 | 解锁 | 提升 | 删除 | 移动 | 固顶 | 总固顶 | 奖励 | 惩罚 | 发布公告
    W3C Contributing Supporter! W 3 C h i n a ( since 2003 ) 旗 下 站 点
    苏ICP备05006046号《全国人大常委会关于维护互联网安全的决定》《计算机信息网络国际联网安全保护管理办法》
    78.125ms