@Override
  public @Nullable Charset getCachedCharsetFromContent(@NotNull Document document) {
    return document.getUserData(CACHED_CHARSET_FROM_CONTENT);
  }
@Override
  public @Nullable Charset getCachedCharsetFromContent(@NotNull Document document)