in reply to Re: Creating context-specific handlers in XML::Twig
in thread Creating context-specific handlers in XML::Twig

Thanks for the suggestions. I know the OP was a little sketchy on detail, but that was intentional. I hoped that the snippets of XML and code would give readers enough of a feel for how I was approaching the problem to understand my train(wreck) of thought, and to the extent that I did not achieve that I apologize.

At this stage I am more interested in understanding the pros and cons to different approaches to the problem than the implementation details. That said, I would welcome any example code that you or any others are willing to provide, and to that end I am working on creating example input, output, and test code. I will update this thread when it is ready.

Re: twig handlers being expressions rather than simple tag names. Thank you for pointing that out - I never realized that there was so much flexibility. I will definitely experiment with it.

In summary, thanks for the reply. Between your comments and the example that GrandFather provided, I am tweaking my code to see if I can clean up the flow a bit. I will post an example soon.

  • Comment on Re^2: Creating context-specific handlers in XML::Twig