Click or drag to resize

MongoServerSettings Class

The settings used to access a MongoDB server.
Inheritance Hierarchy
SystemObject
  MongoDB.DriverMongoServerSettings

Namespace:  MongoDB.Driver
Assembly:  MongoDB.Driver.Legacy (in MongoDB.Driver.Legacy.dll) Version: 2.9.0+32b058abcdf2c7e8d9dd3a676d207b31897eee2e
Syntax
public class MongoServerSettings : IEquatable<MongoServerSettings>

The MongoServerSettings type exposes the following members.

Constructors
  NameDescription
Public methodMongoServerSettings
Creates a new instance of MongoServerSettings. Usually you would use a connection string instead.
Top
Properties
  NameDescription
Public propertyAddressFamily Obsolete.
Gets the AddressFamily for the IPEndPoint (derived from the IPv6 setting).
Public propertyAllowInsecureTls
Gets or sets whether to relax TLS constraints as much as possible.
Public propertyApplicationName
Gets or sets the application name.
Public propertyClusterConfigurator
Gets or sets the cluster configurator.
Public propertyCompressors
Gets or sets the compressors.
Public propertyConnectionMode
Gets or sets the connection mode.
Public propertyConnectTimeout
Gets or sets the connect timeout.
Public propertyCredential
Gets or sets the credential.
Public propertyCredentials Obsolete.
Gets or sets the credentials.
Public propertyGuidRepresentation
Gets or sets the representation to use for Guids.
Public propertyHeartbeatInterval
Gets or sets the heartbeat interval.
Public propertyHeartbeatTimeout
Gets or sets the heartbeat timeout.
Public propertyIPv6
Gets or sets a value indicating whether to use IPv6.
Public propertyIsFrozen
Gets a value indicating whether the settings have been frozen to prevent further changes.
Public propertyLocalThreshold
Gets or sets the local threshold.
Public propertyMaxConnectionIdleTime
Gets or sets the max connection idle time.
Public propertyMaxConnectionLifeTime
Gets or sets the max connection life time.
Public propertyMaxConnectionPoolSize
Gets or sets the max connection pool size.
Public propertyMinConnectionPoolSize
Gets or sets the min connection pool size.
Public propertyOperationTimeout
Gets or sets the operation timeout.
Public propertyReadConcern
Gets or sets the read concern.
Public propertyReadEncoding
Gets or sets the Read Encoding.
Public propertyReadPreference
Gets or sets the read preferences.
Public propertyReplicaSetName
Gets or sets the name of the replica set.
Public propertyRetryReads
Gets or sets whether to retry reads.
Public propertyRetryWrites
Gets or sets whether to retry writes.
Public propertyScheme
Gets or sets the connection string scheme.
Public propertySdamLogFilename
Gets or set the name of the SDAM log file. Null turns logging off. stdout will log to console.
Public propertyServer
Gets or sets the address of the server (see also Servers if using more than one address).
Public propertyServers
Gets or sets the list of server addresses (see also Server if using only one address).
Public propertyServerSelectionTimeout
Gets or sets the server selection timeout.
Public propertySocketTimeout
Gets or sets the socket timeout.
Public propertySslSettings
Gets or sets the SSL settings.
Public propertyUseSsl Obsolete.
Gets or sets a value indicating whether to use SSL.
Public propertyUseTls
Gets or sets a value indicating whether to use TLS.
Public propertyVerifySslCertificate Obsolete.
Gets or sets a value indicating whether to verify an SSL certificate.
Public propertyWaitQueueSize
Gets or sets the wait queue size.
Public propertyWaitQueueTimeout
Gets or sets the wait queue timeout.
Public propertyWriteConcern
Gets or sets the WriteConcern to use.
Public propertyWriteEncoding
Gets or sets the Write Encoding.
Top
Methods
  NameDescription
Public methodClone
Creates a clone of the settings.
Public methodEquals(Object)
Determines whether the specified Object is equal to this instance.
(Overrides ObjectEquals(Object).)
Public methodEquals(MongoServerSettings)
Determines whether the specified MongoServerSettings is equal to this instance.
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodFreeze
Freezes the settings.
Public methodStatic memberFromClientSettings
Creates a new MongoServerSettings object from a MongoClientSettings object.
Public methodStatic memberFromUrl
Gets a MongoServerSettings object intialized with values from a MongoUrl.
Public methodFrozenCopy
Returns a frozen copy of the settings.
Public methodGetHashCode
Gets the hash code.
(Overrides ObjectGetHashCode.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodToString
Returns a string representation of the settings.
(Overrides ObjectToString.)
Top
Operators
  NameDescription
Public operatorStatic memberEquality
Determines whether two MongoServerSettings instances are equal.
Public operatorStatic memberInequality
Determines whether two MongoServerSettings instances are not equal.
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