&& !validateEncoding( encoding ) )
{
StringBuffer msg = new StringBuffer();
msg.append( "The encoding '" + encoding + "' is not a valid one. The supported charsets are: " );
msg.append( StringUtils.join( CharsetDetector.getAllDetectableCharsets(), ", " ) );
throw new UnsupportedEncodingException( msg.toString() );
}
this.encoding = ( StringUtils.isNotEmpty( encoding ) ? encoding : AUTO_ENCODING );
}