C# Класс MongoDB.Driver.Internal.ConnectedInstanceCollection

Maintains a sorted list of connected instances by ping time.
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
Clear ( ) : void

Clears all the instances.

ConnectedInstanceCollection ( ) : System

Initializes a new instance of the ConnectedInstanceCollection class.

EnsureContains ( MongoServerInstance instance ) : void

Ensures that the instance is in the collection.

GetAllInstances ( ) : List

Gets a list of all instances.

GetPrimary ( ) : MongoServerInstance

Gets the primary instance.

GetPrimaryAndSecondaries ( ) : List

Gets a list of primary and secondary instances.

GetSecondaries ( ) : List

Gets a list of secondaries.

Remove ( MongoServerInstance instance ) : void

Removes the specified instance.

Приватные методы

Метод Описание
InstanceAveragePingTimeChanged ( object sender, EventArgs e ) : void

Описание методов

Clear() публичный Метод

Clears all the instances.
public Clear ( ) : void
Результат void

ConnectedInstanceCollection() публичный Метод

Initializes a new instance of the ConnectedInstanceCollection class.
public ConnectedInstanceCollection ( ) : System
Результат System

EnsureContains() публичный Метод

Ensures that the instance is in the collection.
public EnsureContains ( MongoServerInstance instance ) : void
instance MongoServerInstance The instance.
Результат void

GetAllInstances() публичный Метод

Gets a list of all instances.
public GetAllInstances ( ) : List
Результат List

GetPrimary() публичный Метод

Gets the primary instance.
public GetPrimary ( ) : MongoServerInstance
Результат MongoServerInstance

GetPrimaryAndSecondaries() публичный Метод

Gets a list of primary and secondary instances.
public GetPrimaryAndSecondaries ( ) : List
Результат List

GetSecondaries() публичный Метод

Gets a list of secondaries.
public GetSecondaries ( ) : List
Результат List

Remove() публичный Метод

Removes the specified instance.
public Remove ( MongoServerInstance instance ) : void
instance MongoServerInstance The instance.
Результат void