Package dev.getelements.elements.sdk.spi
Class ElementScopedElementRegistrySupplier
java.lang.Object
dev.getelements.elements.sdk.spi.ElementScopedElementRegistrySupplier
- All Implemented Interfaces:
ElementRegistrySupplier
,Supplier<ElementRegistry>
Factory type for the
ElementScopedElementRegistry
. This holds single static instance which it always returns.
It is intended to be used within the SPI implementation and not directly.
The ElementClassLoader
copies and re-defines this class for itself such that there is separate static
instance per class-loader ensuring that an Element
has it's own unique instance.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionget()
static void
setInstance
(ElementRegistry instance) Called by the SPI Interfaces to set the instance.
-
Constructor Details
-
ElementScopedElementRegistrySupplier
public ElementScopedElementRegistrySupplier()
-
-
Method Details
-
get
- Specified by:
get
in interfaceSupplier<ElementRegistry>
-
setInstance
Called by the SPI Interfaces to set the instance.- Parameters:
instance
- the instance to set.
-