Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
situx committed Jan 23, 2024
1 parent 443636a commit a3ba724
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
7 changes: 4 additions & 3 deletions src/sparqlunicorn_ontdoc/docgeneration.py
Original file line number Diff line number Diff line change
Expand Up @@ -1081,9 +1081,10 @@ def createHTML(self,savepath, predobjs, subject, baseurl, subpreds, graph, searc
uritotreeitem[parentclass][-1]["data"]["to"][str(tup[0])][item]+=1
if baseurl not in str(tup[1]) and str(tup[0])!=self.typeproperty:
hasnonns.add(str(tup[1]))
if str(tup[1]) not in nonnsmap:
nonnsmap[str(tup[1])]=set()
nonnsmap[str(tup[1])].add(subject)
if nonnsmap!=None:
if str(tup[1]) not in nonnsmap:
nonnsmap[str(tup[1])]=set()
nonnsmap[str(tup[1])].add(subject)
for tup in sorted(predobjmap):
if self.metadatatable and tup not in DocConfig.labelproperties and DocUtils.shortenURI(str(tup),True) in DocConfig.metadatanamespaces:
thetable=metadatatablecontents
Expand Down
2 changes: 1 addition & 1 deletion src/sparqlunicorn_ontdoc/export/data/voidexporter.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ def createVoidDataset(dsname,prefixnamespace,deploypath,outpath,licenseuri,modti
cururi=voidds+"_"+DocUtils.shortenURI(ns)
g.add((URIRef(cururi), URIRef("http://www.w3.org/1999/02/22-rdf-syntax-ns#type"),URIRef("http://rdfs.org/ns/void#Linkset")))
g.add((URIRef(cururi), URIRef("http://www.w3.org/2000/01/rdf-schema#label"),Literal("Linkset: "+str(DocUtils.shortenURI(voidds))+" - "+str(DocUtils.shortenURI(ns)),lang="en")))
g.add((URIRef(cururi),URIRef("http://rdfs.org/ns/void#subjectsTarget"),URIRef(voidds)))
g.add((URIRef(cururi), URIRef("http://rdfs.org/ns/void#subjectsTarget"),URIRef(voidds)))
g.add((URIRef(cururi), URIRef("http://rdfs.org/ns/void#objectsTarget"),URIRef(ns)))
g.add((URIRef(cururi), URIRef("http://rdfs.org/ns/void#linkPredicate"),URIRef(prop)))
g.add((URIRef(cururi), URIRef("http://rdfs.org/ns/void#triples"),Literal(str(nonnscount[prop][ns]),datatype="http://www.w3.org/2001/XMLSchema#integer")))
Expand Down

0 comments on commit a3ba724

Please sign in to comment.