Class DefaultCxDaoStrategySelector
java.lang.Object
de.hybris.platform.personalizationservices.dao.impl.DefaultCxDaoStrategySelector
- All Implemented Interfaces:
CxDaoStrategySelector
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected <T> voidaddToList(List<T> list, T t, Comparator<? super T> comp) bestStrategyCollector(Comparator<? super T> comp) protected <T> Optional<T>finalizeSelection(List<T> results) protected booleanisValid(CxDaoStrategy strategy, Set<String> keySet) protected <T> List<T>selectBestList(List<T> list1, List<T> list2, Comparator<? super T> comp) selectStrategy(Collection<? extends CxDaoStrategy> strategies, Map<String, String> params) Basing on provided parameters will return valid strategy from collection of provided strategies.protected int
-
Constructor Details
-
DefaultCxDaoStrategySelector
public DefaultCxDaoStrategySelector()
-
-
Method Details
-
selectStrategy
public Optional<CxDaoStrategy> selectStrategy(Collection<? extends CxDaoStrategy> strategies, Map<String, String> params) Description copied from interface:CxDaoStrategySelectorBasing on provided parameters will return valid strategy from collection of provided strategies.- Specified by:
selectStrategyin interfaceCxDaoStrategySelector- Parameters:
strategies- from which result will be selectedparams- parameters taken into consideration during selection- Returns:
- Optional.empty if no valid strategy was found or valid strategy.
-
isValid
-
strategyComparator
-
bestStrategyCollector
-
addToList
-
selectBestList
-
finalizeSelection
-