Class ChainBuilder<T extends ChainedComponent>
- java.lang.Object
-
- com.yahoo.component.chain.dependencies.ordering.ChainBuilder<T>
-
public class ChainBuilder<T extends ChainedComponent> extends java.lang.Object
Given a set of phases and a set of components, a ordered list of components satisfying the dependencies is given if possible.The phase list implicitly defines the ordering: if i < j : p_i before p_j where i,j are valid indexes of the phrase list p.
If multiple components provide the same name, ALL the components providing the same name must be placed earlier/later than an entity depending on that name.
A warning will be logged if multiple components of different types provides the same name. A component can not provide the same name as a phase.
- Author:
- Tony Vaagenes
-
-
Constructor Summary
Constructors Constructor Description ChainBuilder(com.yahoo.component.ComponentId id)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addComponent(ChainedComponent component)
com.yahoo.component.chain.dependencies.ordering.PhaseNameProvider
addPhase(Phase phase)
Chain<T>
orderNodes()
-
-
-
Method Detail
-
addPhase
public com.yahoo.component.chain.dependencies.ordering.PhaseNameProvider addPhase(Phase phase)
-
addComponent
public void addComponent(ChainedComponent component)
-
-