新书推介:《语义网技术体系》
作者:瞿裕忠,胡伟,程龚
   >>中国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等。
    [返回] 中文XML论坛 - 专业的XML技术讨论区W3CHINA.ORG讨论区 - Web新技术讨论『 Semantic Web(语义Web)/描述逻辑/本体 』 → [求助]有关jena的函数问题 查看新帖用户列表

      发表一个新主题  发表一个新投票  回复主题  (订阅本版) 您是本帖的第 3127 个阅读者浏览上一篇主题  刷新本主题   树形显示贴子 浏览下一篇主题
     * 贴子主题: [求助]有关jena的函数问题 举报  打印  推荐  IE收藏夹 
       本主题类别:     
     fanyi 帅哥哟,离线,有人找我吗?
      
      
      等级:大三(要不要学学XML呢?)
      文章:125
      积分:635
      门派:XML.ORG.CN
      注册:2007/3/25

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

    jena的函数addAltEntry和read的参数都代表什么? 请指教

       收藏   分享  
    顶(0)
      




    点击查看用户来源及管理<br>发贴IP:*.*.*.* 2008/4/22 15:31:00
     
     fanyi 帅哥哟,离线,有人找我吗?
      
      
      等级:大三(要不要学学XML呢?)
      文章:125
      积分:635
      门派:XML.ORG.CN
      注册:2007/3/25

    姓名:(无权查看)
    城市:(无权查看)
    院校:(无权查看)
    给fanyi发送一个短消息 把fanyi加入好友 查看fanyi的个人资料 搜索fanyi在『 Semantic Web(语义Web)/描述逻辑/本体 』的所有贴子 引用回复这个贴子 回复这个贴子 查看fanyi的博客2
    发贴心情 
    怎么没人回答我啊?小弟有急用啊!拜托各位了!
    点击查看用户来源及管理<br>发贴IP:*.*.*.* 2008/4/22 19:14:00
     
     jpz6311whu 帅哥哟,离线,有人找我吗?
      
      
      
      威望:9
      等级:研三(收到微软亚洲研究院的Offer了)(版主)
      文章:1718
      积分:10610
      门派:W3CHINA.ORG
      注册:2005/4/12

    姓名:(无权查看)
    城市:(无权查看)
    院校:(无权查看)
    给jpz6311whu发送一个短消息 把jpz6311whu加入好友 查看jpz6311whu的个人资料 搜索jpz6311whu在『 Semantic Web(语义Web)/描述逻辑/本体 』的所有贴子 引用回复这个贴子 回复这个贴子 查看jpz6311whu的博客3
    发贴心情 
    Controlling imports processing
    To load an ontology without building the imports closure, call the method setProcessImports( false ) on the document manager object, or set the processImports property in the policy file. To be more selective, it is possible to ignore certain URI's when loading the imported documents. Call the method addIgnoreImport( String uri ) on the document manager object, or set the ignoreImport property in the policy.

    A strength of working with ontologies is that we can reuse work done by other ontologists by importing their published ontologies. Often, however, this means that the ontology is only retrievable by traversing an Internet firewall. Even if this is possible, by using an HTTP proxy, it may impose unacceptable delay in loading an application. In the worst case, an ontology on which our application depends is temporarily or permanently unavailable from the original published URL. To assist with this common problem, the ontology document manager allows a local indirection, so that an attempt to import a document from a given published URL means that a local copy of the document is retrieved instead. This may be a file copy or simply duplicated on an internal mirror web site.

    To specify this local redirection in the policy file, we use the following declarations:

    <OntologySpec>
      <!-- local version of the RDFS vocabulary -->
      <publicURI rdf:resource="http://www.w3.org/2000/01/rdf-schema"    />
      <altURL rdf:resource="file:vocabularies/rdf-schema.rdf" />
      <language rdf:resource="http://www.w3.org/2000/01/rdf-schema" />
      <prefix rdf:datatype="&xsd;string">rdfs</prefix>
    </OntologySpec>This specifies that an attempt to load the RDFS vocabulary from http://www.w3.org/2000/01/rdf-schema will transparently cause file:vocabularies/rdf-schema.rdf to be fetched instead. Any number of such re-directions may be specified in the policy file, or they can be added to the document manager object directly by calling the various 'add' methods (see the Javadoc for details). As a side-effect, this mechanism also means that ontologies can be named with any legal URI (not necessarily resolvable) - so long as the altURL is itself resolvable.


    Example
    In the following example, we programmatically declare that the camera ontology is copied locally, and then load it using the public URL. Assume that the constant JENA has been initialized to the directory in which Jena is installed.

    OntModel m = ModelFactory.createOntologyModel();
    OntDocumentManager dm = m.getDocumentManager();
    dm.addAltEntry( "http://www.xfront.com/owl/ontologies/camera/",
                    "file:" + JENA + "src-examples/data/camera.owl"    );
    m.read( "http://www.xfront.com/owl/ontologies/camera/" );

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

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

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