public Charset readCharset() {
        BasicProperties basicProperties = message.getBasicProperties();
        if (basicProperties == null) {
            return Message.DEFAULT_MESSAGE_CHARSET;
        }
        String contentCharset = basicProperties.getContentEncoding();
        if (contentCharset == null) {
            return Message.DEFAULT_MESSAGE_CHARSET;
        }
        return Charset.forName(contentCharset);
    }
public Charset readCharset ( ) { BasicProperties basicProperties = message . getBasicProperties ( ) ; if ( basicProperties == null ) { return Message . DEFAULT_MESSAGE_CHARSET ; } String contentCharset = basicProperties . getContentEncoding ( ) ; if ( contentCharset == null ) { return Message . DEFAULT_MESSAGE_CHARSET ; } return Charset . forName ( contentCharset ) ; }
Extracts the message body's charset encoding
by looking it up in the message properties if
given there and choosing the default charset (UTF-8)
otherwise.

@return The message body's charset encoding