Module io.helidon.builder.codegen
Package io.helidon.builder.codegen
Class OptionConfigured.BuilderBase<BUILDER extends OptionConfigured.BuilderBase<BUILDER,PROTOTYPE>,PROTOTYPE extends OptionConfigured>
java.lang.Object
io.helidon.builder.codegen.OptionConfigured.BuilderBase<BUILDER,PROTOTYPE>
- Type Parameters:
BUILDER- type of the builder extending this abstract builderPROTOTYPE- type of the prototype interface that would be built byPrototype.Builder.buildPrototype()
- All Implemented Interfaces:
Prototype.Builder<BUILDER,PROTOTYPE>
- Direct Known Subclasses:
OptionConfigured.Builder
- Enclosing interface:
OptionConfigured
public abstract static class OptionConfigured.BuilderBase<BUILDER extends OptionConfigured.BuilderBase<BUILDER,PROTOTYPE>,PROTOTYPE extends OptionConfigured>
extends Object
implements Prototype.Builder<BUILDER,PROTOTYPE>
Fluent API builder base for
OptionConfigured.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static classGenerated implementation of the prototype, can be extended by descendant prototype implementations. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionClear existing value of factoryMethod.Config key to use.Config key to use.Factory method for this option.factoryMethod(FactoryMethod factoryMethod) Factory method for this option.factoryMethod(Consumer<FactoryMethod.Builder> consumer) Factory method for this option.factoryMethod(Supplier<? extends FactoryMethod> supplier) Factory method for this option.from(OptionConfigured prototype) Update this builder from an existing prototype instance.from(OptionConfigured.BuilderBase<?, ?> builder) Update this builder from an existing prototype builder instance.booleanmerge()Whether to merge the key with the current object.merge(boolean merge) Whether to merge the key with the current object.protected voidHandles providers and decorators.toString()booleantraverse()Whether to traverse the config node when creating a map.traverse(boolean traverse) Whether to traverse the config node when creating a map.protected voidValidates required properties.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface io.helidon.builder.api.Prototype.Builder
buildPrototype, self
-
Constructor Details
-
BuilderBase
protected BuilderBase()Protected to support extensibility.
-
-
Method Details
-
from
Update this builder from an existing prototype instance. This method disables automatic service discovery.- Parameters:
prototype- existing prototype to update this builder from- Returns:
- updated builder instance
-
from
Update this builder from an existing prototype builder instance.- Parameters:
builder- existing builder prototype to update this builder from- Returns:
- updated builder instance
-
configKey
Config key to use.- Parameters:
configKey- config key- Returns:
- updated builder instance
- See Also:
-
merge
Whether to merge the key with the current object.- Parameters:
merge- whether to merge, defaults tofalse, i.e. this option will have its own key, namedconfigKey()- Returns:
- updated builder instance
- See Also:
-
traverse
Whether to traverse the config node when creating a map.- Parameters:
traverse- whether to traverse config, defaults totrue- Returns:
- updated builder instance
- See Also:
-
clearFactoryMethod
Clear existing value of factoryMethod.- Returns:
- updated builder instance
- See Also:
-
factoryMethod
Factory method for this option. Factory method will be discovered fromPrototypeInfo.configFactories().- Parameters:
factoryMethod- config factory method if defined- Returns:
- updated builder instance
- See Also:
-
factoryMethod
Factory method for this option. Factory method will be discovered fromPrototypeInfo.configFactories().- Parameters:
consumer- consumer of builder of config factory method if defined- Returns:
- updated builder instance
- See Also:
-
factoryMethod
Factory method for this option. Factory method will be discovered fromPrototypeInfo.configFactories().- Parameters:
supplier- supplier of config factory method if defined- Returns:
- updated builder instance
- See Also:
-
configKey
Config key to use.- Returns:
- config key
-
merge
public boolean merge()Whether to merge the key with the current object.- Returns:
- whether to merge, defaults to
false, i.e. this option will have its own key, namedconfigKey()
-
traverse
public boolean traverse()Whether to traverse the config node when creating a map.- Returns:
- whether to traverse config, defaults to
true
-
factoryMethod
Factory method for this option. Factory method will be discovered fromPrototypeInfo.configFactories().- Returns:
- config factory method if defined
-
toString
-
preBuildPrototype
protected void preBuildPrototype()Handles providers and decorators. -
validatePrototype
protected void validatePrototype()Validates required properties.
-