public static final class ImmutableMongodConfig.Builder extends Object
ImmutableMongodConfig.
Initialize attributes and then invoke the build() method to create an
immutable instance.
Builder is not thread-safe and generally should not be stored in a field or collection,
but instead used immediately to create instances.
| Modifier and Type | Method and Description |
|---|---|
ImmutableMongodConfig.Builder |
args(Map<String,? extends String> entries)
Sets or replaces all mappings from the specified map as entries for the
args map. |
ImmutableMongodConfig |
build()
Builds a new
ImmutableMongodConfig. |
ImmutableMongodConfig.Builder |
cmdOptions(MongoCmdOptions cmdOptions)
Initializes the value for the
cmdOptions attribute. |
ImmutableMongodConfig.Builder |
from(de.flapdoodle.embed.process.config.ExecutableProcessConfig instance)
Fill a builder with attribute values from the provided
de.flapdoodle.embed.process.config.ExecutableProcessConfig instance. |
ImmutableMongodConfig.Builder |
from(MongoCommonConfig instance)
Fill a builder with attribute values from the provided
de.flapdoodle.embed.mongo.config.MongoCommonConfig instance. |
ImmutableMongodConfig.Builder |
from(MongodConfig instance)
Fill a builder with attribute values from the provided
de.flapdoodle.embed.mongo.config.MongodConfig instance. |
ImmutableMongodConfig.Builder |
isConfigServer(boolean isConfigServer)
Initializes the value for the
isConfigServer attribute. |
ImmutableMongodConfig.Builder |
isShardServer(boolean isShardServer)
Initializes the value for the
isShardServer attribute. |
ImmutableMongodConfig.Builder |
net(Net net)
Initializes the value for the
net attribute. |
ImmutableMongodConfig.Builder |
params(Map<String,? extends String> entries)
Sets or replaces all mappings from the specified map as entries for the
params map. |
ImmutableMongodConfig.Builder |
password(String password)
Initializes the value for the
password attribute. |
ImmutableMongodConfig.Builder |
pidFile(String pidFile)
Initializes the value for the
pidFile attribute. |
ImmutableMongodConfig.Builder |
processListener(IMongoProcessListener processListener)
Initializes the value for the
processListener attribute. |
ImmutableMongodConfig.Builder |
putAllArgs(Map<String,? extends String> entries)
Put all mappings from the specified map as entries to
args map. |
ImmutableMongodConfig.Builder |
putAllParams(Map<String,? extends String> entries)
Put all mappings from the specified map as entries to
params map. |
ImmutableMongodConfig.Builder |
putArgs(Map.Entry<String,? extends String> entry)
Put one entry to the
args map. |
ImmutableMongodConfig.Builder |
putArgs(String key,
String value)
Put one entry to the
args map. |
ImmutableMongodConfig.Builder |
putParams(Map.Entry<String,? extends String> entry)
Put one entry to the
params map. |
ImmutableMongodConfig.Builder |
putParams(String key,
String value)
Put one entry to the
params map. |
ImmutableMongodConfig.Builder |
replication(Storage replication)
Initializes the value for the
replication attribute. |
ImmutableMongodConfig.Builder |
stopTimeoutInMillis(long stopTimeoutInMillis)
Initializes the optional value
stopTimeoutInMillis to stopTimeoutInMillis. |
ImmutableMongodConfig.Builder |
stopTimeoutInMillis(OptionalLong stopTimeoutInMillis)
Initializes the optional value
stopTimeoutInMillis to stopTimeoutInMillis. |
ImmutableMongodConfig.Builder |
supportConfig(de.flapdoodle.embed.process.config.SupportConfig supportConfig)
Initializes the value for the
supportConfig attribute. |
ImmutableMongodConfig.Builder |
timeout(Timeout timeout)
Initializes the value for the
timeout attribute. |
ImmutableMongodConfig.Builder |
userName(String userName)
Initializes the value for the
userName attribute. |
ImmutableMongodConfig.Builder |
version(IFeatureAwareVersion version)
Initializes the value for the
version attribute. |
public final ImmutableMongodConfig.Builder from(MongodConfig instance)
de.flapdoodle.embed.mongo.config.MongodConfig instance.instance - The instance from which to copy valuesthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder from(MongoCommonConfig instance)
de.flapdoodle.embed.mongo.config.MongoCommonConfig instance.instance - The instance from which to copy valuesthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder from(de.flapdoodle.embed.process.config.ExecutableProcessConfig instance)
de.flapdoodle.embed.process.config.ExecutableProcessConfig instance.instance - The instance from which to copy valuesthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder stopTimeoutInMillis(long stopTimeoutInMillis)
stopTimeoutInMillis to stopTimeoutInMillis.stopTimeoutInMillis - The value for stopTimeoutInMillisthis builder for chained invocationpublic final ImmutableMongodConfig.Builder stopTimeoutInMillis(OptionalLong stopTimeoutInMillis)
stopTimeoutInMillis to stopTimeoutInMillis.stopTimeoutInMillis - The value for stopTimeoutInMillisthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder version(IFeatureAwareVersion version)
version attribute.version - The value for versionthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder timeout(Timeout timeout)
timeout attribute.
If not set, this attribute will have a default value as returned by the initializer of timeout.
timeout - The value for timeoutthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder net(Net net)
net attribute.
If not set, this attribute will have a default value as returned by the initializer of net.
net - The value for netthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder cmdOptions(MongoCmdOptions cmdOptions)
cmdOptions attribute.
If not set, this attribute will have a default value as returned by the initializer of cmdOptions.
cmdOptions - The value for cmdOptionsthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder password(String password)
password attribute.
If not set, this attribute will have a default value as returned by the initializer of password.
password - The value for passwordthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder userName(String userName)
userName attribute.
If not set, this attribute will have a default value as returned by the initializer of userName.
userName - The value for userNamethis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder replication(Storage replication)
replication attribute.
If not set, this attribute will have a default value as returned by the initializer of replication.
replication - The value for replicationthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder isConfigServer(boolean isConfigServer)
isConfigServer attribute.
If not set, this attribute will have a default value as returned by the initializer of isConfigServer.
isConfigServer - The value for isConfigServerthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder isShardServer(boolean isShardServer)
isShardServer attribute.
If not set, this attribute will have a default value as returned by the initializer of isShardServer.
isShardServer - The value for isShardServerthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder processListener(IMongoProcessListener processListener)
processListener attribute.
If not set, this attribute will have a default value as returned by the initializer of processListener.
processListener - The value for processListenerthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder putParams(String key, String value)
params map.key - The key in the params mapvalue - The associated value in the params mapthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder putParams(Map.Entry<String,? extends String> entry)
params map. Nulls are not permittedentry - The key and value entrythis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder params(Map<String,? extends String> entries)
params map. Nulls are not permittedentries - The entries that will be added to the params mapthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder putAllParams(Map<String,? extends String> entries)
params map. Nulls are not permittedentries - The entries that will be added to the params mapthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder putArgs(String key, String value)
args map.key - The key in the args mapvalue - The associated value in the args mapthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder putArgs(Map.Entry<String,? extends String> entry)
args map. Nulls are not permittedentry - The key and value entrythis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder args(Map<String,? extends String> entries)
args map. Nulls are not permittedentries - The entries that will be added to the args mapthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder putAllArgs(Map<String,? extends String> entries)
args map. Nulls are not permittedentries - The entries that will be added to the args mapthis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder pidFile(String pidFile)
pidFile attribute.
If not set, this attribute will have a default value as returned by the initializer of pidFile.
pidFile - The value for pidFilethis builder for use in a chained invocationpublic final ImmutableMongodConfig.Builder supportConfig(de.flapdoodle.embed.process.config.SupportConfig supportConfig)
supportConfig attribute.
If not set, this attribute will have a default value as returned by the initializer of supportConfig.
supportConfig - The value for supportConfigthis builder for use in a chained invocationpublic ImmutableMongodConfig build()
ImmutableMongodConfig.IllegalStateException - if any required attributes are missingCopyright © 2022. All rights reserved.