ServerDescriptionWith Method |
Returns a new instance of ServerDescription with some values changed.
Namespace:
MongoDB.Driver.Core.Servers
Assembly:
MongoDB.Driver.Core (in MongoDB.Driver.Core.dll) Version: 2.13.1-v2-13-x1+a7f8afe27855f38f4f72157d11ba2ae73895502e
Syntax public ServerDescription With(
Optional<string> reasonChanged = null,
Optional<TimeSpan> averageRoundTripTime = null,
Optional<EndPoint> canonicalEndPoint = null,
Optional<ElectionId> electionId = null,
Optional<Exception> heartbeatException = null,
Optional<TimeSpan> heartbeatInterval = null,
Optional<Nullable<DateTime>> lastHeartbeatTimestamp = null,
Optional<DateTime> lastUpdateTimestamp = null,
Optional<Nullable<DateTime>> lastWriteTimestamp = null,
Optional<Nullable<TimeSpan>> logicalSessionTimeout = null,
Optional<int> maxBatchCount = null,
Optional<int> maxDocumentSize = null,
Optional<int> maxMessageSize = null,
Optional<int> maxWireDocumentSize = null,
Optional<ReplicaSetConfig> replicaSetConfig = null,
Optional<ServerState> state = null,
Optional<TagSet> tags = null,
Optional<TopologyVersion> topologyVersion = null,
Optional<ServerType> type = null,
Optional<SemanticVersion> version = null,
Optional<Range<int>> wireVersionRange = null
)
Public Function With (
Optional reasonChanged As Optional(Of String) = Nothing,
Optional averageRoundTripTime As Optional(Of TimeSpan) = Nothing,
Optional canonicalEndPoint As Optional(Of EndPoint) = Nothing,
Optional electionId As Optional(Of ElectionId) = Nothing,
Optional heartbeatException As Optional(Of Exception) = Nothing,
Optional heartbeatInterval As Optional(Of TimeSpan) = Nothing,
Optional lastHeartbeatTimestamp As Optional(Of Nullable(Of DateTime)) = Nothing,
Optional lastUpdateTimestamp As Optional(Of DateTime) = Nothing,
Optional lastWriteTimestamp As Optional(Of Nullable(Of DateTime)) = Nothing,
Optional logicalSessionTimeout As Optional(Of Nullable(Of TimeSpan)) = Nothing,
Optional maxBatchCount As Optional(Of Integer) = Nothing,
Optional maxDocumentSize As Optional(Of Integer) = Nothing,
Optional maxMessageSize As Optional(Of Integer) = Nothing,
Optional maxWireDocumentSize As Optional(Of Integer) = Nothing,
Optional replicaSetConfig As Optional(Of ReplicaSetConfig) = Nothing,
Optional state As Optional(Of ServerState) = Nothing,
Optional tags As Optional(Of TagSet) = Nothing,
Optional topologyVersion As Optional(Of TopologyVersion) = Nothing,
Optional type As Optional(Of ServerType) = Nothing,
Optional version As Optional(Of SemanticVersion) = Nothing,
Optional wireVersionRange As Optional(Of Range(Of Integer)) = Nothing
) As ServerDescription
member With :
?reasonChanged : Optional<string> *
?averageRoundTripTime : Optional<TimeSpan> *
?canonicalEndPoint : Optional<EndPoint> *
?electionId : Optional<ElectionId> *
?heartbeatException : Optional<Exception> *
?heartbeatInterval : Optional<TimeSpan> *
?lastHeartbeatTimestamp : Optional<Nullable<DateTime>> *
?lastUpdateTimestamp : Optional<DateTime> *
?lastWriteTimestamp : Optional<Nullable<DateTime>> *
?logicalSessionTimeout : Optional<Nullable<TimeSpan>> *
?maxBatchCount : Optional<int> *
?maxDocumentSize : Optional<int> *
?maxMessageSize : Optional<int> *
?maxWireDocumentSize : Optional<int> *
?replicaSetConfig : Optional<ReplicaSetConfig> *
?state : Optional<ServerState> *
?tags : Optional<TagSet> *
?topologyVersion : Optional<TopologyVersion> *
?type : Optional<ServerType> *
?version : Optional<SemanticVersion> *
?wireVersionRange : Optional<Range<int>>
(* Defaults:
let _reasonChanged = defaultArg reasonChanged null
let _averageRoundTripTime = defaultArg averageRoundTripTime null
let _canonicalEndPoint = defaultArg canonicalEndPoint null
let _electionId = defaultArg electionId null
let _heartbeatException = defaultArg heartbeatException null
let _heartbeatInterval = defaultArg heartbeatInterval null
let _lastHeartbeatTimestamp = defaultArg lastHeartbeatTimestamp null
let _lastUpdateTimestamp = defaultArg lastUpdateTimestamp null
let _lastWriteTimestamp = defaultArg lastWriteTimestamp null
let _logicalSessionTimeout = defaultArg logicalSessionTimeout null
let _maxBatchCount = defaultArg maxBatchCount null
let _maxDocumentSize = defaultArg maxDocumentSize null
let _maxMessageSize = defaultArg maxMessageSize null
let _maxWireDocumentSize = defaultArg maxWireDocumentSize null
let _replicaSetConfig = defaultArg replicaSetConfig null
let _state = defaultArg state null
let _tags = defaultArg tags null
let _topologyVersion = defaultArg topologyVersion null
let _type = defaultArg type null
let _version = defaultArg version null
let _wireVersionRange = defaultArg wireVersionRange null
*)
-> ServerDescription
Parameters
- reasonChanged (Optional)
- Type: MongoDB.DriverOptionalString
The reason the server description changed. - averageRoundTripTime (Optional)
- Type: MongoDB.DriverOptionalTimeSpan
The average round trip time. - canonicalEndPoint (Optional)
- Type: MongoDB.DriverOptionalEndPoint
The canonical end point. - electionId (Optional)
- Type: MongoDB.DriverOptionalElectionId
The election identifier. - heartbeatException (Optional)
- Type: MongoDB.DriverOptionalException
The heartbeat exception. - heartbeatInterval (Optional)
- Type: MongoDB.DriverOptionalTimeSpan
The heartbeat interval. - lastHeartbeatTimestamp (Optional)
- Type: MongoDB.DriverOptionalNullableDateTime
The last heartbeat timestamp. - lastUpdateTimestamp (Optional)
- Type: MongoDB.DriverOptionalDateTime
The last update timestamp. - lastWriteTimestamp (Optional)
- Type: MongoDB.DriverOptionalNullableDateTime
The last write timestamp. - logicalSessionTimeout (Optional)
- Type: MongoDB.DriverOptionalNullableTimeSpan
The logical session timeout. - maxBatchCount (Optional)
- Type: MongoDB.DriverOptionalInt32
The maximum batch count. - maxDocumentSize (Optional)
- Type: MongoDB.DriverOptionalInt32
The maximum size of a document. - maxMessageSize (Optional)
- Type: MongoDB.DriverOptionalInt32
The maximum size of a message. - maxWireDocumentSize (Optional)
- Type: MongoDB.DriverOptionalInt32
The maximum size of a wire document. - replicaSetConfig (Optional)
- Type: MongoDB.DriverOptionalReplicaSetConfig
The replica set configuration. - state (Optional)
- Type: MongoDB.DriverOptionalServerState
The server state. - tags (Optional)
- Type: MongoDB.DriverOptionalTagSet
The replica set tags. - topologyVersion (Optional)
- Type: MongoDB.DriverOptionalTopologyVersion
The topology version. - type (Optional)
- Type: MongoDB.DriverOptionalServerType
The server type. - version (Optional)
- Type: MongoDB.DriverOptionalSemanticVersion
The server version. - wireVersionRange (Optional)
- Type: MongoDB.DriverOptionalRangeInt32
The wire version range.
Return Value
Type:
ServerDescription
A new instance of ServerDescription.
See Also