Click or drag to resize

BsonUtils Class

A static class containing BSON utility methods.
Inheritance Hierarchy
SystemObject
  MongoDB.BsonBsonUtils

Namespace:  MongoDB.Bson
Assembly:  MongoDB.Bson (in MongoDB.Bson.dll) Version: 2.8.0+cc573f3e1f48f39162b4b680e921a623e127e8fa
Syntax
public static class BsonUtils

The BsonUtils type exposes the following members.

Methods
  NameDescription
Public methodStatic memberGetFriendlyTypeName
Gets a friendly class name suitable for use in error messages.
Public methodStatic memberParseHexString
Parses a hex string into its equivalent byte array.
Public methodStatic memberToDateTimeFromMillisecondsSinceEpoch
Converts from number of milliseconds since Unix epoch to DateTime.
Public methodStatic memberToHexChar
Converts a value to a hex character.
Public methodStatic memberToHexString
Converts a byte array to a hex string.
Public methodStatic memberToLocalTime
Converts a DateTime to local time (with special handling for MinValue and MaxValue).
Public methodStatic memberToMillisecondsSinceEpoch
Converts a DateTime to number of milliseconds since Unix epoch.
Public methodStatic memberToUniversalTime
Converts a DateTime to UTC (with special handling for MinValue and MaxValue).
Public methodStatic memberTryParseHexString
Tries to parse a hex string to a byte array.
Top
See Also