in reply to Reading structures from XML
I think the problem is that there just isn't a 1:1 way to do this. This is why XML::Simple gets so hairy. Consider-
<container> <thing foo="bar">baz</thing> <thing qux="oop" foo=""/> <thing/> </container>
What could that look like in a Perl structure? It would have to have objects mimicking DOM or something like "content/children" named placeholders.
So, I don't think this is easy to solve and it will probably be messy or just a different API to the DOM that's almost as complicated. I'd love to be proved wrong in this case. :) I'm an XML::LibXML user that also would love having straight mapping to Perl structures now and then.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Reading structures from XML
by BrowserUk (Patriarch) on May 07, 2009 at 01:13 UTC | |
by Your Mother (Archbishop) on May 07, 2009 at 15:19 UTC | |
|
Re^2: Reading structures from XML
by John M. Dlugosz (Monsignor) on May 06, 2009 at 20:56 UTC |