C# Класс MongoDB.Driver.Database

Наследование: IDatabase
Показать файл Открыть проект Примеры использования класса

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

Метод Описание
Authenticate ( string username, string password ) : bool
Database ( Connection conn, String name ) : System
Eval ( CodeWScope cw ) : Document
Eval ( string javascript ) : Document
Eval ( string javascript, Document scope ) : Document
FollowReference ( DBRef reference ) : Document

Gets the document that a reference is pointing to.

GetCollection ( String name ) : IMongoCollection
GetCollectionNames ( ) : List
GetLastError ( ) : Document

Most operations do not have a return code in order to save the client from having to wait for results. GetLastError can be called to retrieve the return code if clients want one.

GetLastErrorAndFSync ( ) : Document

Retrieves the last error and forces the database to fsync all files before returning.

Server version 1.3+

GetPreviousError ( ) : Document

Call after sending a bulk operation to the database.

Logout ( ) : void
ResetError ( ) : void

Resets last error. This is good to call before a bulk operation.

SendCommand ( Document cmd ) : Document
SendCommand ( string command ) : Document
this ( String name ) : IMongoCollection

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

Метод Описание
Hash ( string text ) : string

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

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

public Authenticate ( string username, string password ) : bool
username string
password string
Результат bool

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

public Database ( Connection conn, String name ) : System
conn Connection
name String
Результат System

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

public Eval ( CodeWScope cw ) : Document
cw CodeWScope
Результат Document

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

public Eval ( string javascript ) : Document
javascript string
Результат Document

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

public Eval ( string javascript, Document scope ) : Document
javascript string
scope Document
Результат Document

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

Gets the document that a reference is pointing to.
public FollowReference ( DBRef reference ) : Document
reference DBRef
Результат Document

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

public GetCollection ( String name ) : IMongoCollection
name String
Результат IMongoCollection

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

public GetCollectionNames ( ) : List
Результат List

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

Most operations do not have a return code in order to save the client from having to wait for results. GetLastError can be called to retrieve the return code if clients want one.
public GetLastError ( ) : Document
Результат Document

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

Retrieves the last error and forces the database to fsync all files before returning.
Server version 1.3+
public GetLastErrorAndFSync ( ) : Document
Результат Document

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

Call after sending a bulk operation to the database.
public GetPreviousError ( ) : Document
Результат Document

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

public Logout ( ) : void
Результат void

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

Resets last error. This is good to call before a bulk operation.
public ResetError ( ) : void
Результат void

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

public SendCommand ( Document cmd ) : Document
cmd Document
Результат Document

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

public SendCommand ( string command ) : Document
command string
Результат Document

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

public this ( String name ) : IMongoCollection
name String
Результат IMongoCollection