Package io.opentelemetry.common
Interface ComponentLoader
public interface ComponentLoader
A loader for components that are discovered via SPI.
-
Method Summary
Modifier and TypeMethodDescriptionstatic ComponentLoaderforClassLoader(ClassLoader classLoader) Create an instance for theclassLoaderusingServiceLoader.load(Class, ClassLoader).<T> Iterable<T> Load implementations of an SPI.
-
Method Details
-
load
Load implementations of an SPI.- Type Parameters:
T- the SPI type- Parameters:
spiClass- the SPI class- Returns:
- iterable of SPI implementations
-
forClassLoader
Create an instance for theclassLoaderusingServiceLoader.load(Class, ClassLoader).
-