XML, java.io, and the Composite Pattern

Tony Obermeit posted a question to the AJUG-QLD mailing list asking for help with a problem reading XML snippets. So, I thought I’d help him out, and this is the answer I gave.

*Update*: As pointed out by Pepijn Schmitz, Sun already provided the same solution: java.io.SequenceInputStream

*Another update*: I raised an RFE with Sun for the vararg support Vote early, vote often!

Continue reading “XML, java.io, and the Composite Pattern”

Text files, test data, and the Jakarta Commons BeanUtils

Earlier, I wrote about testing only one thing at a time. A little one-liner I tossed out in that was using text files to load object graphs in your test cases. I thought I’d elaborate on that a bit more.

Continue reading “Text files, test data, and the Jakarta Commons BeanUtils”

%d bloggers like this: