public class StrategySelectorBuilder
extends java.lang.Object
Constructor and Description |
---|
StrategySelectorBuilder() |
Modifier and Type | Method and Description |
---|---|
<T> void |
addExplicitStrategyRegistration(java.lang.Class<T> strategy,
java.lang.Class<? extends T> implementation,
java.lang.String name)
Adds an explicit (as opposed to discovered) strategy registration.
|
<T> void |
addExplicitStrategyRegistration(StrategyRegistration<T> strategyRegistration)
Adds an explicit (as opposed to discovered) strategy registration.
|
StrategySelector |
buildSelector(ClassLoaderService classLoaderService)
Builds the selector.
|
public <T> void addExplicitStrategyRegistration(java.lang.Class<T> strategy, java.lang.Class<? extends T> implementation, java.lang.String name)
T
- The type of the strategy. Used to make sure that the strategy and implementation are type
compatible.strategy
- The strategyimplementation
- The strategy implementationname
- The registered namepublic <T> void addExplicitStrategyRegistration(StrategyRegistration<T> strategyRegistration)
T
- The type of the strategy. Used to make sure that the strategy and implementation are type
compatible.strategyRegistration
- The strategy implementation registration.public StrategySelector buildSelector(ClassLoaderService classLoaderService)
classLoaderService
- The class loading service used to (attempt to) resolve any un-registered
strategy implementations.Copyright © 2001-2018 Red Hat, Inc. All Rights Reserved.