Class PoolPluginsConfigurator.Builder
java.lang.Object
org.eclipse.keyple.core.service.resource.PoolPluginsConfigurator.Builder
- Enclosing class:
- PoolPluginsConfigurator
Builder of
PoolPluginsConfigurator
.- Since:
- 2.0.0
-
Method Summary
Modifier and TypeMethodDescriptionaddPoolPlugin
(org.eclipse.keyple.core.service.PoolPlugin poolPlugin) Adds aPoolPlugin
to the default list of all card profiles.build()
Creates a new instance ofPoolPluginsConfigurator
using the current configuration.Configures the card resource service to search for available cards in pool plugins before regular plugins.
-
Method Details
-
usePoolFirst
Configures the card resource service to search for available cards in pool plugins before regular plugins.Default value: pool last
- Returns:
- The current builder instance.
- Throws:
IllegalStateException
- If the setting has already been configured.- Since:
- 2.0.0
-
addPoolPlugin
public PoolPluginsConfigurator.Builder addPoolPlugin(org.eclipse.keyple.core.service.PoolPlugin poolPlugin) Adds aPoolPlugin
to the default list of all card profiles.Note: The order of the plugins is important because it will be kept during the allocation process unless redefined by card profiles.
- Parameters:
poolPlugin
- The pool plugin to add.- Returns:
- The current builder instance.
- Throws:
IllegalArgumentException
- If the provided pool plugin is null.IllegalStateException
- If the pool plugin has already been configured.- Since:
- 2.0.0
-
build
Creates a new instance ofPoolPluginsConfigurator
using the current configuration.- Returns:
- A new instance.
- Throws:
IllegalStateException
- If no pool plugin has been configured.- Since:
- 2.0.0
-