Re: PROPOSAL: Errata text regarding defining a prefix of '_'

On Sat, 2009-11-14 at 12:06 -0600, Shane McCarron wrote:
> My question is this:  How do you ensure that your implicit, 
> automatically created bnode names never collide with a documents 
> explicit, auto-vivified bnode names?  And should we have some sort of
> a test case to ensure this happens? 

It's not especially difficult. Here's one technique a parser could
follow:

 When an explicitly named bnode is found, check if its name
 starts '_:bn'. If not, use it verbatim. But if so, replace
 the '_:bn' with '_:bnbn'.

 When a name is needed for an implicit bnode, give it one
 starting '_:bn' followed by numbers.

You should find that this can never produce a collision. Of course if
means that in some cases, explicitly named blank nodes in the input RDFa
have different names in the output graph. But that's OK - RDF doesn't
assign any meanings to the names of blank nodes.

-- 
Toby A Inkster
<mailto:mail@tobyinkster.co.uk>
<http://tobyinkster.co.uk>

Received on Saturday, 14 November 2009 19:37:19 UTC