markupbuilder

Building XML and HTML with MarkupBuilder in Groovy.

Groovy DSL and Builder Pattern – Create Domain-Specific Languages with 10 Examples

Groovy DSL and Builder patterns with 10+ examples. Master MarkupBuilder, CliBuilder, ObjectGraphBuilder, delegate strategy, and custom DSL creation. “A well-designed DSL reads like a conversation between the developer and the domain. Groovy makes writing those conversations remarkably easy.” Martin Fowler, Domain-Specific Languages Last Updated: March 2026 | Tested on: Groovy 5.x, Java 17+ | Difficulty: Intermediate to Advanced | Reading Time: 25 minutes If you have used Gradle, you have already used a Groovy DSL without realizing it. That clean, ... Read More

Groovy Create and Modify XML – MarkupBuilder, StreamingMarkupBuilder with 12 Examples

Learn to Groovy create XML and modify with 12 examples using MarkupBuilder, StreamingMarkupBuilder, XmlParser, and XmlUtil. Tested on Groovy 5.x. “Writing XML by hand is like writing assembly – you can do it, but there are better tools for the job.” Tim Bray, XML Specification Co-author Last Updated: March 2026 | Tested on: Groovy 5.x, Java 17+ | Difficulty: Intermediate | Reading Time: 22 minutes Reading XML is only half the story – in real projects, you also need to ... Read More