public static final class ImmutableMongoImportArguments.Builder extends Object
ImmutableMongoImportArguments.
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 |
|---|---|
ImmutableMongoImportArguments |
build()
Builds a new
ImmutableMongoImportArguments. |
ImmutableMongoImportArguments.Builder |
collectionName(Optional<String> collectionName)
Initializes the optional value
collectionName to collectionName. |
ImmutableMongoImportArguments.Builder |
collectionName(String collectionName)
Initializes the optional value
collectionName to collectionName. |
ImmutableMongoImportArguments.Builder |
databaseName(Optional<String> databaseName)
Initializes the optional value
databaseName to databaseName. |
ImmutableMongoImportArguments.Builder |
databaseName(String databaseName)
Initializes the optional value
databaseName to databaseName. |
ImmutableMongoImportArguments.Builder |
dropCollection(boolean dropCollection)
Initializes the value for the
dropCollection attribute. |
ImmutableMongoImportArguments.Builder |
from(MongoImportArguments instance)
Fill a builder with attribute values from the provided
MongoImportArguments instance. |
ImmutableMongoImportArguments.Builder |
importFile(Optional<String> importFile)
Initializes the optional value
importFile to importFile. |
ImmutableMongoImportArguments.Builder |
importFile(String importFile)
Initializes the optional value
importFile to importFile. |
ImmutableMongoImportArguments.Builder |
isHeaderline(boolean isHeaderline)
Initializes the value for the
isHeaderline attribute. |
ImmutableMongoImportArguments.Builder |
isJsonArray(boolean isJsonArray)
Initializes the value for the
isJsonArray attribute. |
ImmutableMongoImportArguments.Builder |
type(Optional<String> type)
Initializes the value for the
type attribute. |
ImmutableMongoImportArguments.Builder |
upsertDocuments(boolean upsertDocuments)
Initializes the value for the
upsertDocuments attribute. |
ImmutableMongoImportArguments.Builder |
verbose(boolean verbose)
Initializes the value for the
verbose attribute. |
public final ImmutableMongoImportArguments.Builder from(MongoImportArguments instance)
MongoImportArguments instance.
Regular attribute values will be replaced with those from the given instance.
Absent optional values will not replace present values.instance - The instance from which to copy valuesthis builder for use in a chained invocationpublic final ImmutableMongoImportArguments.Builder verbose(boolean verbose)
verbose attribute.
If not set, this attribute will have a default value as returned by the initializer of verbose.
verbose - The value for verbosethis builder for use in a chained invocationpublic final ImmutableMongoImportArguments.Builder databaseName(String databaseName)
databaseName to databaseName.databaseName - The value for databaseNamethis builder for chained invocationpublic final ImmutableMongoImportArguments.Builder databaseName(Optional<String> databaseName)
databaseName to databaseName.databaseName - The value for databaseNamethis builder for use in a chained invocationpublic final ImmutableMongoImportArguments.Builder collectionName(String collectionName)
collectionName to collectionName.collectionName - The value for collectionNamethis builder for chained invocationpublic final ImmutableMongoImportArguments.Builder collectionName(Optional<String> collectionName)
collectionName to collectionName.collectionName - The value for collectionNamethis builder for use in a chained invocationpublic final ImmutableMongoImportArguments.Builder importFile(String importFile)
importFile to importFile.importFile - The value for importFilethis builder for chained invocationpublic final ImmutableMongoImportArguments.Builder importFile(Optional<String> importFile)
importFile to importFile.importFile - The value for importFilethis builder for use in a chained invocationpublic final ImmutableMongoImportArguments.Builder type(Optional<String> type)
type attribute.
If not set, this attribute will have a default value as returned by the initializer of type.
type - The value for typethis builder for use in a chained invocationpublic final ImmutableMongoImportArguments.Builder isHeaderline(boolean isHeaderline)
isHeaderline attribute.
If not set, this attribute will have a default value as returned by the initializer of isHeaderline.
isHeaderline - The value for isHeaderlinethis builder for use in a chained invocationpublic final ImmutableMongoImportArguments.Builder isJsonArray(boolean isJsonArray)
isJsonArray attribute.
If not set, this attribute will have a default value as returned by the initializer of isJsonArray.
isJsonArray - The value for isJsonArraythis builder for use in a chained invocationpublic final ImmutableMongoImportArguments.Builder dropCollection(boolean dropCollection)
dropCollection attribute.
If not set, this attribute will have a default value as returned by the initializer of dropCollection.
dropCollection - The value for dropCollectionthis builder for use in a chained invocationpublic final ImmutableMongoImportArguments.Builder upsertDocuments(boolean upsertDocuments)
upsertDocuments attribute.
If not set, this attribute will have a default value as returned by the initializer of upsertDocuments.
upsertDocuments - The value for upsertDocumentsthis builder for use in a chained invocationpublic ImmutableMongoImportArguments build()
ImmutableMongoImportArguments.IllegalStateException - if any required attributes are missingCopyright © 2023. All rights reserved.