Table of Contents

Interface IConnection

Namespace
MongoDB.Driver.Core.Connections
Assembly
MongoDB.Driver.Core.dll

Represents a connection.

public interface IConnection : IDisposable
Inherited Members

Properties

ConnectionId

Gets the connection identifier.

Description

Gets the connection description.

EndPoint

Gets the end point.

Generation

Gets the generation of the pool when this connection was created.

IsExpired

Gets a value indicating whether this instance is expired.

Settings

Gets the connection settings.

Methods

Open(CancellationToken)

Opens the connection.

OpenAsync(CancellationToken)

Opens the connection.

Reauthenticate(CancellationToken)

Reauthenticate the connection.

ReauthenticateAsync(CancellationToken)

Reauthenticate the connection.

ReceiveMessage(int, IMessageEncoderSelector, MessageEncoderSettings, CancellationToken)

Receives a message.

ReceiveMessageAsync(int, IMessageEncoderSelector, MessageEncoderSettings, CancellationToken)

Receives a message.

SendMessages(IEnumerable<RequestMessage>, MessageEncoderSettings, CancellationToken)

Sends the messages.

SendMessagesAsync(IEnumerable<RequestMessage>, MessageEncoderSettings, CancellationToken)

Sends the messages.

SetReadTimeout(TimeSpan)

Set read timeout value.