Groovy XML Ninja Skills
“XML is like violence: if it doesn't solve your problem, you aren't using enough of it.” (Anonymous)
XML is everywhere. Whether you are dealing with local configuration files (web.xml, struts-config.xml) or remote web services (SOAP, REST, RSS, Atom), the modern software developer needs to be able to request, slice, and dice XML with ease. That requires a set of razor-sharp tools that reduce the inherent complexity of the problem, not multiply it. Once you see XML tremble in fear at the awesome power of Groovy, you'll wonder what you ever did without it.
In this talk, we look at various Groovy tools to create, parse, and export XML. To read in XML, we'll explore the XmlSlurper and the XmlParser. To write out XML, we'll use the MarkupBuilder, StreamingMarkupBuilder, and the XmlNodePrinter. We'll go beyond simple Plain Old XML (POX) and demonstrate using namespaces, CDATA blocks, and more.
About Scott Davis
Scott Davis is the founder of ThirstyHead.com, a training company that specializes in Groovy and Grails training.
Scott published one of the first public websites implemented in Grails in 2006 and has been actively working with the technology ever since. Author of the book Groovy Recipes: Greasing the Wheels of Java and two ongoing IBM developerWorks article series (Mastering Grails and in 2009, Practically Groovy), Scott writes extensively about how Groovy and Grails are the future of Java development.
More About Scott »