Click or drag to resize

ConnectionString Class

Represents a connection string.
Inheritance Hierarchy
SystemObject
  MongoDB.Driver.Core.ConfigurationConnectionString

Namespace:  MongoDB.Driver.Core.Configuration
Assembly:  MongoDB.Driver.Core (in MongoDB.Driver.Core.dll) Version: 2.19.1+3a2a09dd959482f665ffbb5df2557ec541597af4
Syntax
public sealed class ConnectionString

The ConnectionString type exposes the following members.

Constructors
  NameDescription
Public methodConnectionString
Initializes a new instance of the ConnectionString class.
Top
Properties
  NameDescription
Public propertyAllOptionNames
Gets all the option names.
Public propertyAllUnknownOptionNames
Gets all the unknown option names.
Public propertyApplicationName
Gets the application name.
Public propertyAuthMechanism
Gets the auth mechanism.
Public propertyAuthMechanismProperties
Gets the auth mechanism properties.
Public propertyAuthSource
Gets the auth source.
Public propertyCompressors
Gets the requested compressors.
Public propertyConnect Obsolete.
Gets the connection mode.
Public propertyConnectionModeSwitch Obsolete.
Gets the connection mode switch.
Public propertyConnectTimeout
Gets the connect timeout.
Public propertyDatabaseName
Gets the name of the database.
Public propertyDirectConnection
Gets the directConnection.
Public propertyFSync
Gets the fsync value of the write concern.
Public propertyHeartbeatInterval
Gets the heartbeat interval.
Public propertyHeartbeatTimeout
Gets the heartbeat timeout.
Public propertyHosts
Gets the hosts.
Public propertyIpv6
Gets whether to use IPv6.
Public propertyIsResolved
Gets whether the connection string has been resolved. Always true when scheme is MongoDB.
Public propertyJournal
Gets the journal value of the write concern.
Public propertyLoadBalanced
Gets a value indicating whether load balanced mode is used.
Public propertyLocalThreshold
Gets the local threshold.
Public propertyMaxConnecting
Gets the maximum number of connections a pool may be establishing concurrently. Defaults to 2.
Public propertyMaxIdleTime
Gets the max idle time.
Public propertyMaxLifeTime
Gets the max life time.
Public propertyMaxPoolSize
Gets the max size of the connection pool.
Public propertyMaxStaleness
Gets the max staleness.
Public propertyMinPoolSize
Gets the min size of the connection pool.
Public propertyPassword
Gets the password.
Public propertyReadConcernLevel
Gets the read concern level.
Public propertyReadPreference
Gets the read preference.
Public propertyReadPreferenceTags
Gets the read preference tags.
Public propertyReplicaSet
Gets the replica set name.
Public propertyRetryReads
Gets a value indicating whether or not to retry reads.
Public propertyRetryWrites
Gets a value indicating whether or not to retry writes.
Public propertyScheme
Gets the connection string scheme.
Public propertyServerSelectionTimeout
Gets the server selection timeout.
Public propertySocketTimeout
Gets the socket timeout.
Public propertySrvMaxHosts
Limits the number of SRV records used to populate the seedlist during initial discovery, as well as the number of additional hosts that may be added during SRV polling.
Public propertySsl Obsolete.
Gets whether to use SSL.
Public propertySslVerifyCertificate Obsolete.
Gets whether to verify SSL certificates.
Public propertyTls
Gets whether to use TLS.
Public propertyTlsDisableCertificateRevocationCheck
Get whether or not certificate revocation checking is disabled during the TLS handshake.
Public propertyTlsInsecure
Gets whether to relax TLS constraints as much as possible.
Public propertyUsername
Gets the username.
Public propertyUuidRepresentation
Gets the UUID representation.
Public propertyW
Gets the w value of the write concern.
Public propertyWaitQueueMultiple Obsolete.
Gets the wait queue multiple.
Public propertyWaitQueueSize Obsolete.
Gets the wait queue size.
Public propertyWaitQueueTimeout
Gets the wait queue timeout.
Public propertyWTimeout
Gets the wtimeout value of the write concern.
Top
Methods
  NameDescription
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetOption
Gets the option.
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodResolve(CancellationToken)
Resolves a connection string. If the connection string indicates more information is available in the DNS system, it will acquire that information as well.
Public methodResolve(Boolean, CancellationToken)
Resolves a connection string. If the connection string indicates more information is available in the DNS system, it will acquire that information as well.
Public methodResolveAsync(CancellationToken)
Resolves a connection string. If the connection string indicates more information is available in the DNS system, it will acquire that information as well.
Public methodResolveAsync(Boolean, CancellationToken)
Resolves a connection string. If the connection string indicates more information is available in the DNS system, it will acquire that information as well.
Public methodToString
Returns a string that represents the current object.
(Overrides ObjectToString.)
Top
Extension Methods
  NameDescription
Public Extension MethodToBson
Serializes an object to a BSON byte array.
(Defined by BsonExtensionMethods.)
Public Extension MethodToBsonDocument
Serializes an object to a BsonDocument.
(Defined by BsonExtensionMethods.)
Public Extension MethodToJson
Serializes an object to a JSON string.
(Defined by BsonExtensionMethods.)
Top
See Also