|
|
| Syntactic Confectionery Delight | |
| PerlMonks |
Re: XPath-like method for searching/editing structuresby tobyink (Prior) |
| on Oct 09, 2012 at 20:40 UTC ( #998070=note: print w/ replies, xml ) | Need Help?? |
|
There are a number of modules that offer XPath-like syntax for drilling down into nested Perl data structures. One is my own JSON::Path which implements the JsonPath specification which also has freely available PHP, Javascript and C# (.NET) implementations. JSON::Path also has links to various other similar Perl modules that I found in its SEE ALSO section. I do like that Data::Diver lvalue feature. I may have to steal that.
perl -E'sub Monkey::do{say$_,for@_,do{($monkey=[caller(0)]->[3])=~s{::}{ }and$monkey}}"Monkey say"->Monkey::do'
In Section
Seekers of Perl Wisdom
|
|
||||||||||||||||||||||