private <P extends LibraryProperties> LibraryPresentationProvider<P> getPresentationProvider(LibraryKind kind) {
    Map<LibraryKind, LibraryPresentationProvider<?>> providers = myPresentationProviders;
    if (providers == null) {
      providers = new HashMap<>();
      for (LibraryType<?> type : LibraryType.EP_NAME.getExtensions()) {
        providers.put(type.getKind(), type);
      }
      for (LibraryPresentationProvider provider : LibraryPresentationProvider.EP_NAME.getExtensions()) {
        providers.put(provider.getKind(), provider);
      }
      myPresentationProviders = providers;
    }
    //noinspection unchecked
    return (LibraryPresentationProvider<P>)providers.get(kind);
  }
private <P extends LibraryProperties> LibraryPresentationProvider<P> getPresentationProvider(LibraryKind kind)