void (@NotNull Editor editor) { if (editorsWithControllers == null) { LOG.debug("create map of weak references to remember all editors with custom parameter info controllers and attach EP-listener"); editorsWithControllers = ContainerUtil.createWeakSet(); // Weak... to avoid memory leaks caused by keeping disposed editors in memory EP_NAME.addExtensionPointListener(new ExtensionPointListener<>() { @Override public void extensionRemoved(@NotNull ParameterInfoControllerProvider extension, @NotNull PluginDescriptor pluginDescriptor) { removeControllersFromAllEditors(); } }, null); } if (!editorsWithControllers.contains(editor)) { LOG.debug("remember editor " + editor); editorsWithControllers.add(editor); } }