Module io.helidon.pico.api
Package io.helidon.pico.api
Class AbstractActivationResult.Builder<B extends AbstractActivationResult.Builder<B,T>,T extends ActivationResult>
java.lang.Object
io.helidon.pico.api.AbstractActivationResult.Builder<B,T>
- Type Parameters:
B- the type of the builderT- the type of the built instance
- All Implemented Interfaces:
Builder<B,,T> ActivationResult,Supplier<T>
- Direct Known Subclasses:
DefaultActivationResult.Builder
- Enclosing class:
AbstractActivationResult
public abstract static class AbstractActivationResult.Builder<B extends AbstractActivationResult.Builder<B,T>,T extends ActivationResult>
extends Object
implements ActivationResult, Builder<B,T>
Fluent API builder for
T.-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionAccept and update from the provided value object.error()Any throwable/exceptions that were observed during activation.Setter for 'error'.Setter for 'error'.Optionally, given by the implementation provider to indicate the future completion when the provider'sActivationStatusisActivationStatus.WARNING_SUCCESS_BUT_NOT_READY.Setter for 'finishedActivationResult'.Setter for 'finishedActivationResult'.The activation phase we finished successfully on, or are otherwise currently in if not yet finished.Setter for 'finishingActivationPhase'.How did the activation finish.Setter for 'finishingStatus'.Setter for 'finishingStatus'.Map<String,? extends InjectionPlan> The injection plan that was found or determined, key'ed by each element'sServiceProvider.id().injectionPlans(Map<String, ? extends InjectionPlan> val) Setter for 'injectionPlans'.The dependencies that were resolved or loaded, key'ed by each element'sServiceProvider.id().resolvedDependencies(Map<String, Object> val) Setter for 'resolvedDependencies'.The service provider undergoing activation or deactivation.serviceProvider(ServiceProvider<?> val) Setter for 'serviceProvider'.The activation phase that was found at onset of the phase transition.Setter for 'startingActivationPhase'.The activation phase that was requested at the onset of the phase transition.Setter for 'targetActivationPhase'.<T> voidvisitAttributes(AttributeVisitor<T> visitor, T userDefinedCtx) Visits all attributes of io.helidon.pico.api.ActivationResult, calling theAttributeVisitorfor each.booleanSet to true if the injection plan inActivationResult.resolvedDependencies()has been resolved and can be "trusted" as being complete and accurate.wasResolved(boolean val) Setter for 'wasResolved'.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.helidon.pico.api.ActivationResult
failure, finished, success
-
Field Details
-
injectionPlans
Field value forjava.util.Map<java.lang.String, ? extends io.helidon.pico.spi.InjectionPlan> injectionPlans(). -
resolvedDependencies
Field value forjava.util.Map<java.lang.String, java.lang.Object> resolvedDependencies().
-
-
Constructor Details
-
Builder
protected Builder()Fluent API builder constructor.
-
-
Method Details
-
serviceProvider
Description copied from interface:ActivationResultThe service provider undergoing activation or deactivation.- Specified by:
serviceProviderin interfaceActivationResult- Returns:
- the service provider generating the result
-
finishedActivationResult
Description copied from interface:ActivationResultOptionally, given by the implementation provider to indicate the future completion when the provider'sActivationStatusisActivationStatus.WARNING_SUCCESS_BUT_NOT_READY.- Specified by:
finishedActivationResultin interfaceActivationResult- Returns:
- the future result, assuming how activation can be async in nature
-
startingActivationPhase
Description copied from interface:ActivationResultThe activation phase that was found at onset of the phase transition.- Specified by:
startingActivationPhasein interfaceActivationResult- Returns:
- the starting phase
-
targetActivationPhase
Description copied from interface:ActivationResultThe activation phase that was requested at the onset of the phase transition.- Specified by:
targetActivationPhasein interfaceActivationResult- Returns:
- the target, desired, ultimate phase requested
-
finishingActivationPhase
Description copied from interface:ActivationResultThe activation phase we finished successfully on, or are otherwise currently in if not yet finished.- Specified by:
finishingActivationPhasein interfaceActivationResult- Returns:
- the finishing phase
-
finishingStatus
Description copied from interface:ActivationResultHow did the activation finish. Will only be populated if the lifecycle event has completed - seeActivationResult.finishedActivationResult().- Specified by:
finishingStatusin interfaceActivationResult- Returns:
- the finishing status
-
injectionPlans
Description copied from interface:ActivationResultThe injection plan that was found or determined, key'ed by each element'sServiceProvider.id().- Specified by:
injectionPlansin interfaceActivationResult- Returns:
- the resolved injection plan map
-
resolvedDependencies
Description copied from interface:ActivationResultThe dependencies that were resolved or loaded, key'ed by each element'sServiceProvider.id().- Specified by:
resolvedDependenciesin interfaceActivationResult- Returns:
- the resolved dependency map
-
wasResolved
public boolean wasResolved()Description copied from interface:ActivationResultSet to true if the injection plan inActivationResult.resolvedDependencies()has been resolved and can be "trusted" as being complete and accurate.- Specified by:
wasResolvedin interfaceActivationResult- Returns:
- true if was resolved
-
error
Description copied from interface:ActivationResultAny throwable/exceptions that were observed during activation.- Specified by:
errorin interfaceActivationResult- Returns:
- any captured error
-
serviceProvider
Setter for 'serviceProvider'.- Parameters:
val- the new value- Returns:
- this fluent builder
-
finishedActivationResult
Setter for 'finishedActivationResult'.- Parameters:
val- the new value- Returns:
- this fluent builder
-
finishedActivationResult
Setter for 'finishedActivationResult'.- Parameters:
val- the new value- Returns:
- this fluent builder
-
startingActivationPhase
Setter for 'startingActivationPhase'.- Parameters:
val- the new value- Returns:
- this fluent builder
-
targetActivationPhase
Setter for 'targetActivationPhase'.- Parameters:
val- the new value- Returns:
- this fluent builder
-
finishingActivationPhase
Setter for 'finishingActivationPhase'.- Parameters:
val- the new value- Returns:
- this fluent builder
-
finishingStatus
Setter for 'finishingStatus'.- Parameters:
val- the new value- Returns:
- this fluent builder
-
finishingStatus
Setter for 'finishingStatus'.- Parameters:
val- the new value- Returns:
- this fluent builder
-
injectionPlans
Setter for 'injectionPlans'.- Parameters:
val- the new value- Returns:
- this fluent builder
-
resolvedDependencies
Setter for 'resolvedDependencies'.- Parameters:
val- the new value- Returns:
- this fluent builder
-
wasResolved
Setter for 'wasResolved'.- Parameters:
val- the new value- Returns:
- this fluent builder
-
error
Setter for 'error'.- Parameters:
val- the new value- Returns:
- this fluent builder
-
error
Setter for 'error'.- Parameters:
val- the new value- Returns:
- this fluent builder
-
accept
Accept and update from the provided value object.- Parameters:
val- the value object to copy from- Returns:
- this instance typed to correct type
-
visitAttributes
Visits all attributes of io.helidon.pico.api.ActivationResult, calling theAttributeVisitorfor each.- Type Parameters:
T- type of the user defined context- Parameters:
visitor- the visitor called for each attributeuserDefinedCtx- any object you wish to pass to each visit call
-