Ensure outputEncoding is honoured

Workaround an issue in
com.sun.codemodel.util.EncoderFactory#createEncoder that causes the
encoding specified to be ignored (and the platform default to be used
instead).

Closes #131.