public interface TraversalStrategies extends Serializable, Cloneable
Traversal maintains a set of TraversalStrategy instances within a TraversalStrategies object.
 TraversalStrategies are responsible for compiling a traversal prior to its execution.| Modifier and Type | Interface and Description | 
|---|---|
static class  | 
TraversalStrategies.GlobalCache  | 
| Modifier and Type | Field and Description | 
|---|---|
static List<Class<? extends TraversalStrategy>> | 
STRATEGY_CATEGORIES  | 
| Modifier and Type | Method and Description | 
|---|---|
TraversalStrategies | 
addStrategies(TraversalStrategy<?>... strategies)
Add all the provided  
TraversalStrategy instances to the current collection. | 
void | 
applyStrategies(Traversal.Admin<?,?> traversal)
 | 
TraversalStrategies | 
clone()  | 
default <T extends TraversalStrategy> | 
getStrategy(Class<T> traversalStrategyClass)
Return the  
TraversalStrategy instance associated with the provided class. | 
TraversalStrategies | 
removeStrategies(Class<? extends TraversalStrategy>... strategyClasses)
Remove all the provided  
TraversalStrategy classes from the current collection. | 
static Set<TraversalStrategy<?>> | 
sortStrategies(Set<TraversalStrategy<?>> strategies)
Sorts the list of provided strategies such that the  
TraversalStrategy.applyPost()
 and TraversalStrategy.applyPrior() dependencies are respected. | 
List<TraversalStrategy<?>> | 
toList()
Return all the  
TraversalStrategy singleton instances associated with this TraversalStrategies. | 
static void | 
visit(Map<Class<? extends TraversalStrategy>,Set<Class<? extends TraversalStrategy>>> dependencyMap,
     List<Class<? extends TraversalStrategy>> sortedStrategyClasses,
     Set<Class<? extends TraversalStrategy>> seenStrategyClases,
     List<Class<? extends TraversalStrategy>> unprocessedStrategyClasses,
     Class<? extends TraversalStrategy> strategyClass)  | 
static final List<Class<? extends TraversalStrategy>> STRATEGY_CATEGORIES
List<TraversalStrategy<?>> toList()
TraversalStrategy singleton instances associated with this TraversalStrategies.default <T extends TraversalStrategy> Optional<T> getStrategy(Class<T> traversalStrategyClass)
TraversalStrategy instance associated with the provided class.T - the strategy class typetraversalStrategyClass - the class of the strategy to getvoid applyStrategies(Traversal.Admin<?,?> traversal)
TraversalStrategy optimizers to the Traversal for the stated TraversalEngine.
 This method must ensure that the strategies are sorted prior to application.traversal - the traversal to apply the strategies toTraversalStrategies addStrategies(TraversalStrategy<?>... strategies)
TraversalStrategy instances to the current collection.
 When all the provided strategies have been added, the collection is resorted.strategies - the traversal strategies to addTraversalStrategies removeStrategies(Class<? extends TraversalStrategy>... strategyClasses)
TraversalStrategy classes from the current collection.
 When all the provided strategies have been removed, the collection is resorted.strategyClasses - the traversal strategies to remove by their classTraversalStrategies clone()
static Set<TraversalStrategy<?>> sortStrategies(Set<TraversalStrategy<?>> strategies)
TraversalStrategy.applyPost()
 and TraversalStrategy.applyPrior() dependencies are respected.
 
 Note, that the order may not be unique.strategies - the traversal strategies to sortstatic void visit(Map<Class<? extends TraversalStrategy>,Set<Class<? extends TraversalStrategy>>> dependencyMap, List<Class<? extends TraversalStrategy>> sortedStrategyClasses, Set<Class<? extends TraversalStrategy>> seenStrategyClases, List<Class<? extends TraversalStrategy>> unprocessedStrategyClasses, Class<? extends TraversalStrategy> strategyClass)
Copyright © 2013–2019 Apache Software Foundation. All rights reserved.