comparison bin/rdfdb @ 826:05aabe3d7b02

fix some minor issues with graph contexts Ignore-this: 7fd366a4b6cbd94af6f9edb1b4b4c6fc
author Drew Perttula <drewp@bigasterisk.com>
date Tue, 04 Jun 2013 20:28:49 +0000
parents 295b867fd810
children e53e78db7b17
comparison
equal deleted inserted replaced
825:a8942364e4ee 826:05aabe3d7b02
203 # back this might not go so well 203 # back this might not go so well
204 filename = filename[:-len('.n3')] 204 filename = filename[:-len('.n3')]
205 return URIRef(self.topUri + filename) 205 return URIRef(self.topUri + filename)
206 206
207 def fileForUri(self, ctx): 207 def fileForUri(self, ctx):
208 assert isinstance(ctx, URIRef), ctx
208 if not ctx.startswith(self.topUri): 209 if not ctx.startswith(self.topUri):
209 raise ValueError("don't know what filename to use for %s" % ctx) 210 raise ValueError("don't know what filename to use for %s" % ctx)
210 return ctx[len(self.topUri):] + ".n3" 211 return ctx[len(self.topUri):] + ".n3"
211 212
212 def watchFile(self, inFile): 213 def watchFile(self, inFile):