Hi all, I really love YAML and would love to start replacing some of my XML
structures, however I need a way to query the YAML data in the same way
that I can query XML using xpath/xquery. After searching around, I've
found some things on yaml.kwiki.org
YAP <http://yaml.kwiki.org/index.cgi?page_name=YAP>), which all seem to
point to good ideas, but nothing real concrete or official. I've also found
that Ruby's YAML group has a class for YPath, but from looking at the
source code I can't see that it does much.
So, I guess my question is, does a standard exist for YPath (if it indeed
exists)? If not, is there any indication of what the syntax might look
like (ie, will it follow xpath or will it be its own thing)?
[please configure this mailing list to reply-to the list]
Ben Davis wrote:
> Hi all, I really love YAML and would love to start replacing some of my XML
"If broke it ain't, fix it not" --Yoda
> I've also found that Ruby's YAML group has a class for YPath, but from
> looking at the source code I can't see that it does much.
The best way to use XML as a lite user-editable database is with surgical XPath
strikes, so you probably already have a good design.
I don't know about the library you snipped, but I might be the only person in
the world who based a system on YPath.
My "yar_wiki" project puts YPath to good use, in Ruby. Hit it here:
http://www.oreilly.com/catalog/9780596510657/ <-- build a YAML wiki with YPath
http://assertxpath.rubyforge.org/ <-- unrelated documentation
http://phlip.svnrepository.com/svn/yar_wiki/ <-- special sauce