restricting TBox annotations updates to rdfs and vitro namespaces
This commit is contained in:
parent
83e3379592
commit
2b537937be
2 changed files with 11 additions and 0 deletions
|
@ -163,6 +163,7 @@ public class ABoxUpdater {
|
|||
renameCount++;
|
||||
Statement newStatement = ResourceFactory.createStatement(newClass, oldStatement.getPredicate(), oldStatement.getObject());
|
||||
additions.add(newStatement);
|
||||
retractions.add(oldStatement);
|
||||
} else {
|
||||
removeCount++;
|
||||
retractions.add(oldStatement);
|
||||
|
|
|
@ -16,6 +16,7 @@ import com.hp.hpl.jena.rdf.model.Resource;
|
|||
import com.hp.hpl.jena.rdf.model.Statement;
|
||||
import com.hp.hpl.jena.rdf.model.StmtIterator;
|
||||
import com.hp.hpl.jena.shared.Lock;
|
||||
import com.hp.hpl.jena.vocabulary.RDFS;
|
||||
|
||||
import edu.cornell.mannlib.vitro.webapp.dao.VitroVocabulary;
|
||||
|
||||
|
@ -107,6 +108,15 @@ public class TBoxUpdater {
|
|||
Property predicate = stmt.getPredicate();
|
||||
RDFNode oldObject = stmt.getObject();
|
||||
|
||||
if (! ( (RDFS.getURI().equals(predicate.getNameSpace())) ||
|
||||
(VitroVocabulary.vitroURI.equals(predicate.getNameSpace()))
|
||||
) ) {
|
||||
// this annotation updater is only concerned with properties
|
||||
// such as rdfs:comment and properties in the vitro application
|
||||
// namespace
|
||||
continue;
|
||||
}
|
||||
|
||||
if (VitroVocabulary.TAB_AUTOLINKEDTOTAB.equals(predicate.getURI())) {
|
||||
continue;
|
||||
// the tab autolinks are not like the other annotations
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue