Class ProviderLoader
java.lang.Object
io.github.dinethdilhara.urltoproduct.engine.ProviderLoader
ProviderLoader
Loads all available ProductProvider implementations
using Java's ServiceLoader mechanism.
This enables a pluggable architecture where new providers (e.g. Amazon, AliExpress) can be added without modifying core code.
How it works:- Scans classpath for registered providers
- Instantiates each provider
- Returns a list of available providers
- Version:
- 1.0.0
- Author:
- Dineth Dilhara
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic List<ProductProvider> load()Loads all ProductProvider implementations.
-
Constructor Details
-
ProviderLoader
public ProviderLoader()
-
-
Method Details
-
load
Loads all ProductProvider implementations.- Returns:
- list of discovered providers (may be empty if none found)
-