Version: SVN (using Devel) OS: Linux Currently the Nepomuk::Resource constructor taking a QString identifier does not set the identifiers property but uses the identifier as a url which is stored in nie:url property. Further the constructor taking a QUrl does not set nie:url as it should. Reproducible: Didn't try Expected Results: Expected behaviour: -Constructor taking a URL sets nie:url if the given url is not a nepomuk:/ url -The constructor taking an identifier adds identifier to the identifiers property and does not set the nie:url property Briefly discussed with Sebastian Trüg
Small elaboration: this only affects identifiers that are formed like URLs with a schema. In this context it were akondi ids which look like this: akonadi:?item=ABC
I think I'm okay with changing this IF we also need some other identifiers to identify resources with. That way I could clean up some of the hacks I did in the Nepomuk internals. By other identifiers I mean ways of looking for resources. Currently we are limited to nie:url, nao:identifier, and the resource uri. Otherwise I'm not too keen on going and changing stuff.
(In reply to comment #2) > I think I'm okay with changing this IF we also need some other identifiers to > identify resources with. That way I could clean up some of the hacks I did in > the Nepomuk internals. > > By other identifiers I mean ways of looking for resources. Currently we are > limited to nie:url, nao:identifier, and the resource uri. Sorry for the late reply, I forgot about that issue. I'm not to sure what other identifiers you mean. I didn't mean to set another identifier. What I wanted to say is that if I create an item like Nepomuk::HtmlDocument res("akonadi:?item=21"); then res.getProperty(Nepomuk::Vocabulary::NIE::url()) should return "akonadi:?item=21" (not the nepomuk uri), and res.resourceUri() should return the nepomuk uri. Atm, this seems to work once the NIE::url() was set manually, but before not (It might also be related that it only works once the resource is written back, but I have at least one setProperty call between the creation of the resource and the check, so that shouldn't be an issue) And if I create a Resource using Nepomuk::Resource res("randomText"); I should be able to retrieve the same resource using the same constructor, and it should probably be available in the identifier list. (I didn't check that recently if it works now) > > Otherwise I'm not too keen on going and changing stuff.
Until there is a use case for this case, I'm not going to fix this. We shouldn't be mixing up urls and identifiers.