[Versa] Issue 3
Chimezie Ogbuji
chimezie at gmail.com
Sat Aug 13 08:10:03 MDT 2005
> * If the SPF is *, it is resolved into a pattern that matches anything
> * If the SPF is a primitive scalar, datatyped literal or resource, it is
> resolved into a pattern that must match that string or resource exactly
> * If the SPF is a list or set, it is resolved into a pattern that must
> match one of the items in the list or set exactly
> * If the SPF is a function, f, then it is a special filtering function
> pattern, and the pattern is equivalent to the resulting list from
> filter(<all possible values>, f). (This means that the function must
> take each item to be filtered as its first parameter)
Yes, the addition of the filtering functionality makes it even more flexible
> As you say in your examples:
>
> A - B -> * becomes objects({A B *})
> all() |- B -> eq('foo') becomes objects({* B 'foo'})
>
> I wonder whether this is taking us back to the limited triple-based API
> that we'd been hoping to get away from in creating Versa. I'd have to
> think through some more complex examples to decide for myself.
Well traversals operators themselves *are* triple based operators
since they only account for 3 parts of a statement. The other aspects
of the statement could be projected into a longer list:
list(s,p,o,stmtUri,scope) with correponding functions to extract each
part. I guess I still see alot of value in being able to handle
statements explicitely (whether as first class objects or through an
interpretation layer that doesn't break the existing data
infrastructure) - rather than wrestle traversal operators into forms
that seem unweildy sometimes (I'll compile some examples0.
> Uche Ogbuji Fourthought, Inc.
> http://uche.ogbuji.net http://fourthought.com
> http://copia.ogbuji.net http://4Suite.org
> Use CSS to display XML, part 2 - http://www-128.ibm.com/developerworks/edu/x-dw-x-xmlcss2-i.html
> XML Output with 4Suite & Amara - http://www.xml.com/pub/a/2005/04/20/py-xml.html
> Use XSLT to prepare XML for import into OpenOffice Calc - http://www.ibm.com/developerworks/xml/library/x-oocalc/
> Schema standardization for top-down semantic transparency - http://www-128.ibm.com/developerworks/xml/library/x-think31.html
>
> _______________________________________________
> Versa mailing list
> Versa at lists.fourthought.com
> http://lists.fourthought.com/mailman/listinfo/versa
>
More information about the Versa
mailing list