[Mulgara-dev] Virtual model in mulgara.

Life is hard, and then you die ronald at innovation.ch
Tue Feb 6 04:48:02 UTC 2007


On Tue, Feb 06, 2007 at 10:27:26AM +1000, Andrae Muys wrote:
[snip]
> As regards your resolver, you need to realise that resolvers *don't*  
> return triples - they return Resolutions.  These are Tuples that  
> provide bindings for the variables in the Constraint passed to resolve 
> ().  So in the case of <http://www.example.com/path/subpath>  
> $predicate $object the resulting Resolution should have two variables  
> ($predicate $object).  In the case of <../subpath> <http:// 
> www.schema.com#parent> $subpath it will have one ($subpath).
> 
> You should also be aware that a Resolution can be unevaluated!  It is  
> not uncommon for bindings, required to evaluate the constraint, come  
> from other parts of the query.  Consider the following where clause:
> 
> $url $p $o in <rmi://localhost/server1#sample> and <myfile> <hasurl>  
> $url
> 
> in this case your resolver will be asked to resolve ($url $p $o),  
> return a Resolution that will later be passed the $url in the prefix  
> argument to beforeFirst().  Evaluation would then occur either in  
> beforeFirst() or in the calls to next() - we prefer it to happen in  
> beforeFirst if the memory requirement isn't unreasonable, our  
> algorithmic reasoning assumes a comparatively cheap next().
[snip]

Thanks for all this great info! This clarifies a few things I've been
wondering about too.


  Cheers,

  Ronald




More information about the Mulgara-dev mailing list