code: public static CharSequence getCharsetAsSequence(HttpMessage message) {
          CharSequence contentTypeValue = message.headers().get(HttpHeaderNames.CONTENT_TYPE);
          if (contentTypeValue != null) {
              return getCharsetAsSequence(contentTypeValue);
          } else {
              return null;
          }
      }
docs: Fetch charset from message's Content-Type header as a char sequence.
  
  A lot of sites/possibly clients have charset="CHARSET", for example charset="utf-8". Or "utf8" instead of "utf-8"
  This is not according to standard, but this method provide an ability to catch desired mistakes manually in code
  
  @return the {@code CharSequence} with charset from message's Content-Type header
  or {@code null} if charset is not presented