简体   繁体   中英

What is the difference between IRI and URI in OWL?

Example:

http://data.doremus.org/activity/587ae689-790e-3525-9e3a-dac63f449a03

I think it is a IRI and also a URI. (Am I right?)

And I use OWL API to parse it. In the class "IRI", there is a method getShortForm() , when I use it, I get "ae689-790e-3525-9e3a-dac63f449a03".

About URI, I think its local name is "587ae689-790e-3525-9e3a-dac63f449a03". I am not very sure. In fact, I know the word "local name" from others' blog. I don't find the "local name" in URI's structure as follows.

 scheme:[//[user[:password]@]host[:port]][/path][?query][#fragment] 

So, I have two questions:

  1. What's the shortForm of IRI? Why the shortForm of the example is not "587ae689-790e-3525-9e3a-dac63f449a03"?

  2. What's the local name of URI and what's the local name of the example?

An IRI is an URI whose characters include characters outside the URI specs. The I is for Internationalised, so every URI is an IRI.

Local name for an IRI is just a convenience. It starts after the last character in the IRI that cannot be part of an XML NCName - this is due to XML syntactical restrictions on what is a valid tag name.

An NCName cannot start with a number; that's why you're getting three digits dropped off after the slash.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM