C# Class MongoDB.Driver.Util.ErrorTranslator

Translates an error returned from Mongo into the proper exception.
Mostra file Open project: sdether/mongodb-csharp

Public Methods

Method Description
IsError ( Document doc ) : bool
Translate ( Document error ) : MongoException

Private Methods

Method Description
BuildException ( string errnum, string msg, Document error ) : MongoException
GetErrorNum ( string msg ) : string

Method Details

IsError() public static method

public static IsError ( Document doc ) : bool
doc MongoDB.Driver.Document
return bool

Translate() public static method

public static Translate ( Document error ) : MongoException
error MongoDB.Driver.Document
return MongoDB.Driver.MongoException