[fpc-pascal] A new design for a JSON Parser

Anthony Walter sysrpl at gmail.com
Mon Aug 26 16:06:56 CEST 2019


Adding a global redefinable separator character is a good idea which I
might add. With regards to using the forward slash, I am just reusing the
XPath way of doing things and was considering adding a few more XPath like
queries. For example:

N.Find('/inventory/999/sku'); // search from root if the first path
character is '/', find the 999th node, return the sku
N.Find('//item[name="widget"]/price'); // search for the first item in the
entire document ('//') with a name of widget, return its price
N.Find('//item[recalled]/name'); // search for the first item with a
recalled node and return the name

And so on ...
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20190826/8b004b6e/attachment.html>


More information about the fpc-pascal mailing list