mirror of
https://github.com/JetBrains/intellij-sdk-code-samples.git
synced 2025-07-28 01:07:49 +08:00
plugin_services.md: Workaround for "constructor" section title causing a TOC issue
This commit is contained in:
parent
236802ab94
commit
3c874b82f4
@ -77,7 +77,7 @@ and one extension to access the `another.plugin.myExtensionPoint` extension poin
|
||||
Please note the following important points:
|
||||
|
||||
- Extension implementation must be stateless. Use explicit [](plugin_services.md) for managing (runtime) data.
|
||||
- Avoid any initialization in the constructor, see also notes for [Services](plugin_services.md#constructor).
|
||||
- Avoid any initialization in the constructor, see also notes for [Services](plugin_services.md#ctor).
|
||||
- Do not perform any static initialization. Use inspection <control>Plugin DevKit | Code | Static initialization in extension point implementations</control> (2023.3).
|
||||
- An extension implementation must not be registered as [Service](plugin_services.md) additionally. Use inspection <control>Plugin DevKit | Code | Extension registered as service/component</control> (2023.3).
|
||||
|
||||
|
@ -29,6 +29,7 @@ For the latter two, a separate instance of the service is created for each insta
|
||||
{id="moduleServiceNote"}
|
||||
|
||||
#### Constructor
|
||||
{#ctor}
|
||||
|
||||
To improve startup performance, avoid any heavy initializations in the constructor.
|
||||
|
||||
@ -59,7 +60,7 @@ The service instance will be created in scope according to the caller (see [](#r
|
||||
|
||||
* None of these attributes is required: `os`, `client`, `overrides`, `id`, `preload`.
|
||||
* Service class must be `final`.
|
||||
* [Constructor injection](#constructor) of dependency services is not supported.
|
||||
* [Constructor injection](#ctor) of dependency services is not supported.
|
||||
* If application-level service is a [PersistentStateComponent](persisting_state_of_components.md), roaming must be disabled (`roamingType = RoamingType.DISABLED`).
|
||||
|
||||
Use these inspections to verify these and highlight services that can be converted (2023.3):
|
||||
|
Loading…
x
Reference in New Issue
Block a user