code: public static String truncate(String contentType) {
          if (contentType == null) {
              contentType = NO_TYPE_MIMETYPE;
          } else {
              Matcher matcher = TRUNCATION_REGEX.matcher(contentType);
              if (matcher.matches()) {
              	contentType = matcher.group(1);
              } else {
              	contentType = NO_TYPE_MIMETYPE;
              }
          }
  
          return contentType;
      }
docs: Truncate passed mimetype.
  
  Ensure no spaces.  Strip encoding.  Truncation required by
  ARC files.
  
  <p>Truncate at delimiters [;, ].
  Truncate multi-part content type header at ';'.
  Apache httpclient collapses values of multiple instances of the
  header into one comma-separated value,therefore truncated at ','.
  Current ia_tools that work with arc files expect 5-column
  space-separated meta-lines, therefore truncate at ' '.
  
  @param contentType Raw content-type.
  
  @return Computed content-type made from passed content-type after
  running it through a set of rules.