test_class.file: restx-core/src/test/java/restx/http/HTTPTest.java
test_class.identifier: HTTPTest
test_case.body: @Test
      public void should_extract_charset() throws Exception {
          assertThat(HTTP.charsetFromContentType("text/html; charset=UTF-8")).isEqualTo(Optional.of("UTF-8"));
          assertThat(HTTP.charsetFromContentType("application/json; charset=ISO-8859-1")).isEqualTo(Optional.of("ISO-8859-1"));
          assertThat(HTTP.charsetFromContentType("application/json")).isEqualTo(Optional.<String>absent());
      }
test_case.class_method_signature: HTTPTest.should_extract_charset()
test_case.full_signature: @Test public void should_extract_charset()
test_case.identifier: should_extract_charset
test_case.invocations: isEqualTo assertThat charsetFromContentType of isEqualTo assertThat charsetFromContentType of isEqualTo assertThat charsetFromContentType absent
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void should_extract_charset()
focal_class.declarator: mimeTypes
focal_class.modifier: private static final
focal_class.original_string: private static final Properties mimeTypes;
focal_class.type: Properties
focal_class.var_name: mimeTypes
focal_class.declarator: RFC_2616_TOKEN_SPECIAL_CHARS_REGEX = "[\\s\\(\\)<>@,;:\\\\\"/\\[\\]\\?=\\{\\}]"
focal_class.modifier: private final static
focal_class.original_string: private final static String RFC_2616_TOKEN_SPECIAL_CHARS_REGEX = "[\\s\\(\\)<>@,;:\\\\\"/\\[\\]\\?=\\{\\}]";
focal_class.type: String
focal_class.var_name: RFC_2616_TOKEN_SPECIAL_CHARS_REGEX
focal_class.file: restx-core/src/main/java/restx/http/HTTP.java
focal_class.identifier: HTTP
focal_class.class_method_signature: HTTP.getContentTypeFromExtension(String filename)
focal_class.full_signature: public static Optional<String> getContentTypeFromExtension(String filename)
focal_class.identifier: getContentTypeFromExtension
focal_class.modifiers: public static
focal_class.parameters: (String filename)
focal_class.return: Optional<String>
focal_class.signature: Optional<String> getContentTypeFromExtension(String filename)
focal_class.class_method_signature: HTTP.isTextContentType(String contentType)
focal_class.full_signature: public static boolean isTextContentType(String contentType)
focal_class.identifier: isTextContentType
focal_class.modifiers: public static
focal_class.parameters: (String contentType)
focal_class.return: boolean
focal_class.signature: boolean isTextContentType(String contentType)
focal_class.class_method_signature: HTTP.charsetFromContentType(String s)
focal_class.full_signature: public static Optional<String> charsetFromContentType(String s)
focal_class.identifier: charsetFromContentType
focal_class.modifiers: public static
focal_class.parameters: (String s)
focal_class.return: Optional<String>
focal_class.signature: Optional<String> charsetFromContentType(String s)
focal_class.class_method_signature: HTTP.headerTokenCompatible(String s, String specialCharsReplacement)
focal_class.full_signature: public static String headerTokenCompatible(String s, String specialCharsReplacement)
focal_class.identifier: headerTokenCompatible
focal_class.modifiers: public static
focal_class.parameters: (String s, String specialCharsReplacement)
focal_class.return: String
focal_class.signature: String headerTokenCompatible(String s, String specialCharsReplacement)
focal_method.body: public static Optional<String> charsetFromContentType(String s) {
          if (s.indexOf("charset=") == -1) {
              return Optional.absent();
          } else {
              return Optional.of(s.substring(s.indexOf("charset=") + "charset=".length()));
          }
      }
focal_method.class_method_signature: HTTP.charsetFromContentType(String s)
focal_method.full_signature: public static Optional<String> charsetFromContentType(String s)
focal_method.identifier: charsetFromContentType
focal_method.invocations: indexOf absent of substring indexOf length
focal_method.modifiers: public static
focal_method.parameters: (String s)
focal_method.return: Optional<String>
focal_method.signature: Optional<String> charsetFromContentType(String s)