Module io.helidon.config
Package io.helidon.config
Class MapConfigSource.MapBuilder<T extends MapConfigSource.MapBuilder<T>>
java.lang.Object
io.helidon.config.AbstractSourceBuilder<B,U>
io.helidon.config.AbstractConfigSourceBuilder<T,Void>
io.helidon.config.MapConfigSource.MapBuilder<T>
- Type Parameters:
T
- type of the implementing builder
- All Implemented Interfaces:
Builder<MapConfigSource.Builder,
,MapConfigSource> PollableSource.Builder<T>
,Source.Builder<T>
,Supplier<MapConfigSource>
- Direct Known Subclasses:
ConfigSources.SystemPropertiesConfigSource.Builder
,MapConfigSource.Builder
- Enclosing class:
- MapConfigSource
public abstract static class MapConfigSource.MapBuilder<T extends MapConfigSource.MapBuilder<T>>
extends AbstractConfigSourceBuilder<T,Void>
implements Builder<MapConfigSource.Builder,MapConfigSource>, PollableSource.Builder<T>
An abstract fluent API builder for
MapConfigSource
.
If you want to extend MapConfigSource
, you can use this class as a base for
your own builder.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected Map<?,
?> map()
Map used as data of this config source.Map to be used as config source underlying data.Name of this source.pollingStrategy
(PollingStrategy pollingStrategy) Configure a polling strategy.properties
(Properties properties) Properties to be used as config source underlying data.protected String
Name of the source.Methods inherited from class io.helidon.config.AbstractConfigSourceBuilder
config, mediaType, mediaTypeMapping, parser, parserMapping
Methods inherited from class io.helidon.config.AbstractSourceBuilder
changeWatcher, optional, retryPolicy
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.helidon.config.spi.PollableSource.Builder
pollingStrategy
Methods inherited from interface io.helidon.config.spi.Source.Builder
optional, optional, retryPolicy
-
Constructor Details
-
MapBuilder
protected MapBuilder()Creat a new builder instance.
-
-
Method Details
-
map
Map to be used as config source underlying data. The same instance is kept by the config source, to support polling.- Parameters:
map
- map to use- Returns:
- updated builder instance
-
properties
Properties to be used as config source underlying data. The same instance is kept by the config source, to support polling.- Parameters:
properties
- properties to use- Returns:
- updated builder instance
-
name
Name of this source.- Parameters:
sourceName
- name of this source- Returns:
- updated builder instance
-
pollingStrategy
Description copied from class:AbstractSourceBuilder
Configure a polling strategy. This method must be exposed by builders of sources that support polling. If you see this method as being protected in your builder, the source has removed support for polling, such asClasspathConfigSource
.- Specified by:
pollingStrategy
in interfacePollableSource.Builder<T extends MapConfigSource.MapBuilder<T>>
- Overrides:
pollingStrategy
in classAbstractSourceBuilder<T extends MapConfigSource.MapBuilder<T>,
Void> - Parameters:
pollingStrategy
- polling strategy to use- Returns:
- updated builder instance
-
map
Map used as data of this config source.- Returns:
- map with the data
-
sourceName
Name of the source.- Returns:
- name
-