if (primary.equals("text")) if (! isRepresentationClassCharBuffer() && ! isRepresentationClassReader() && representationClass != java.lang.String.class && ! (representationClass.isArray() && representationClass.getComponentType() == Character.TYPE)) { String charset = getParameter("charset"); String otherset = flavor.getParameter("charset"); String defaultset = Charset.defaultCharset().name();  if (charset == null || charset.equals(defaultset)) return (otherset == null || otherset.equals(defaultset));  return charset.equals(otherset); }
  public boolean equals(DataFlavor flavor)  {  if (flavor == null)      return false;    if (! this.mimeType.toLowerCase().equals(flavor.mimeType.toLowerCase()))      return false;    if (! this.representationClass.equals(flavor.representationClass))      return false;    return true;  }