public interface ComponentManager extends UserDataHolder, Disposable, AreaInstance
Application
and Project
.ProjectComponent
,
Application
,
Project
Disposable.Parent
Modifier and Type | Method and Description |
---|---|
default java.lang.RuntimeException |
createError(java.lang.String message,
PluginId pluginId) |
default java.lang.RuntimeException |
createError(java.lang.Throwable error,
PluginId pluginId) |
<T> T |
getComponent(java.lang.Class<T> interfaceClass)
Gets the component by its interface class.
|
default <T> T |
getComponent(java.lang.Class<T> interfaceClass,
T defaultImplementationIfAbsent)
Deprecated.
Useless.
|
default BaseComponent |
getComponent(java.lang.String name)
Deprecated.
Use
getComponent(Class) instead. |
default <T> java.util.List<T> |
getComponentInstancesOfType(java.lang.Class<T> baseClass)
Deprecated.
Do not use.
|
default <T> java.util.List<T> |
getComponentInstancesOfType(java.lang.Class<T> baseClass,
boolean createIfNotYet)
Deprecated.
|
default <T> T [] |
getComponents(java.lang.Class<T> baseClass)
Deprecated.
use extension points instead
|
Condition<?> |
getDisposed() |
default ExtensionsArea |
getExtensionArea() |
default <T> T [] |
getExtensions(ExtensionPointName<T> extensionPointName)
Deprecated.
|
MessageBus |
getMessageBus() |
PicoContainer |
getPicoContainer() |
default <T> T |
getService(java.lang.Class<T> serviceClass) |
default <T> T |
getService(java.lang.Class<T> serviceClass,
boolean createIfNeeded)
Deprecated.
|
default <T> T |
getServiceIfCreated(java.lang.Class<T> serviceClass) |
default boolean |
hasComponent(java.lang.Class<?> interfaceClass)
Checks whether there is a component with the specified interface class.
|
default <T> T |
instantiateClass(java.lang.Class<T> aClass,
PluginId pluginId) |
default <T> T |
instantiateClassWithConstructorInjection(java.lang.Class<T> aClass,
java.lang.Object key,
PluginId pluginId) |
default <T> T |
instantiateExtensionWithPicoContainerOnlyIfNeeded(java.lang.String name,
PluginDescriptor pluginDescriptor) |
boolean |
isDisposed() |
default boolean |
isDisposedOrDisposeInProgress()
Deprecated.
Use
isDisposed() instead |
default void |
logError(java.lang.Throwable error,
PluginId pluginId) |
getUserData, putUserData
dispose
@Deprecated default BaseComponent getComponent(java.lang.String name)
getComponent(Class)
instead.<T> T getComponent(java.lang.Class<T> interfaceClass)
interfaceClass
- the interface class of the component@Deprecated default <T> T getComponent(java.lang.Class<T> interfaceClass, T defaultImplementationIfAbsent)
default boolean hasComponent(java.lang.Class<?> interfaceClass)
interfaceClass
- interface class of component to be checkedtrue
if there is a component with the specified interface class;
false
otherwise@Deprecated default <T> T [] getComponents(java.lang.Class<T> baseClass)
baseClass
.PicoContainer getPicoContainer()
MessageBus getMessageBus()
com.intellij.application.Topics#subscribe
boolean isDisposed()
ProjectImpl.dispose()
was called but not completed yet)
@Deprecated default boolean isDisposedOrDisposeInProgress()
isDisposed()
instead@Deprecated default <T> T [] getExtensions(ExtensionPointName<T> extensionPointName)
ExtensionPointName.getExtensionList(AreaInstance)
Condition<?> getDisposed()
Application.invokeLater(Runnable, Condition)
for the usage example.@Deprecated default <T> T getService(java.lang.Class<T> serviceClass, boolean createIfNeeded)
getServiceIfCreated(Class)
or getService(Class)
.default <T> T getService(java.lang.Class<T> serviceClass)
default <T> T getServiceIfCreated(java.lang.Class<T> serviceClass)
default ExtensionsArea getExtensionArea()
getExtensionArea
in interface AreaInstance
default <T> T instantiateClass(java.lang.Class<T> aClass, PluginId pluginId)
default <T> T instantiateClassWithConstructorInjection(java.lang.Class<T> aClass, java.lang.Object key, PluginId pluginId)
default void logError(java.lang.Throwable error, PluginId pluginId)
default java.lang.RuntimeException createError(java.lang.Throwable error, PluginId pluginId)
default java.lang.RuntimeException createError(java.lang.String message, PluginId pluginId)
default <T> T instantiateExtensionWithPicoContainerOnlyIfNeeded(java.lang.String name, PluginDescriptor pluginDescriptor)
@Deprecated default <T> java.util.List<T> getComponentInstancesOfType(java.lang.Class<T> baseClass)
@Deprecated default <T> java.util.List<T> getComponentInstancesOfType(java.lang.Class<T> baseClass, boolean createIfNotYet)