Table of Contents

Namespace MongoDB.Bson.IO

The MongoDB.Bson.IO namespace contains the types that allow reading and writing of BSON data.

Classes

BsonBinaryReader

Represents a BSON reader for a binary BSON byte array.

BsonBinaryReaderBookmark

Represents a bookmark that can be used to return a reader to the current position and state.

BsonBinaryReaderSettings

Represents settings for a BsonBinaryReader.

BsonBinaryWriter

Represents a BSON writer to a BSON Stream.

BsonBinaryWriterSettings

Represents settings for a BsonBinaryWriter.

BsonChunkPool

Represents a pool of chunks.

BsonDocumentReader

Represents a BSON reader for a BsonDocument.

BsonDocumentReaderBookmark

Represents a bookmark that can be used to return a reader to the current position and state.

BsonDocumentReaderSettings

Represents settings for a BsonDocumentReader.

BsonDocumentWriter

Represents a BSON writer to a BsonDocument.

BsonDocumentWriterSettings

Represents settings for a BsonDocumentWriter.

BsonReader

Represents a BSON reader for some external format (see subclasses).

BsonReaderBookmark

Represents a bookmark that can be used to return a reader to the current position and state.

BsonReaderSettings

Represents settings for a BsonReader.

BsonStream

Represents a Stream has additional methods to suport reading and writing BSON values.

BsonStreamAdapter

A Stream that wraps another Stream while implementing the BsonStream abstract methods.

BsonStreamExtensions

Represents extension methods on BsonStream.

BsonTrieNode<TValue>

Represents a node in a BsonTrie.

BsonTrie<TValue>

Represents a mapping from a set of UTF8 encoded strings to a set of elementName/value pairs, implemented as a trie.

BsonWriter

Represents a BSON writer for some external format (see subclasses).

BsonWriterSettings

Represents settings for a BsonWriter.

ByteArrayBuffer

An IByteBuffer that is backed by a contiguous byte array.

ByteArrayChunk

Represents a chunk backed by a byte array.

ByteBufferFactory

Represents a factory for IBsonBuffers.

ByteBufferSlice

Represents a slice of a byte buffer.

ByteBufferStream

Represents a Stream backed by an IByteBuffer. Similar to MemoryStream but backed by an IByteBuffer instead of a byte array and also implements the BsonStream interface for higher performance BSON I/O.

DateTimeJsonToken

Represents a DateTime JSON token.

DoubleJsonToken

Represents a Double JSON token.

IBsonReaderExtensions

Contains extensions methods for IBsonReader.

IBsonWriterExtensions

Contains extension methods for IBsonWriter.

InputBufferChunkSource

Represents a source of chunks optimized for input buffers.

Int32JsonToken

Represents an Int32 JSON token.

Int64JsonToken

Represents an Int64 JSON token.

JsonConvert

Encodes and decodes scalar values to JSON compatible strings.

JsonReader

Represents a BSON reader for a JSON string.

JsonReaderBookmark

Represents a bookmark that can be used to return a reader to the current position and state.

JsonReaderSettings

Represents settings for a JsonReader.

JsonToken

Represents a JSON token.

JsonWriter

Represents a BSON writer to a TextWriter (in JSON format).

JsonWriterSettings

Represents settings for a JsonWriter.

MultiChunkBuffer

An IByteBuffer that is backed by multiple chunks.

NoOpElementNameValidator

Represents an element name validator that does no validation.

ObjectIdJsonToken

Represents an ObjectId JSON token.

OutputBufferChunkSource

Represents a source of chunks optimized for output buffers.

RegularExpressionJsonToken

Represents a regular expression JSON token.

SingleChunkBuffer

An IByteBuffer that is backed by a single chunk.

StringJsonToken

Represents a String JSON token.

TrieNameDecoder<TValue>

Represents a Trie-based name decoder that also provides a value.

Utf8Encodings

Represents a singleton instance of a strict UTF8Encoding.

Utf8Helper

Represents a class that has some helper methods for decoding UTF8 strings.

Utf8NameDecoder

Represents a UTF8 name decoder.

WrappingBsonWriter

An abstract base class for an IBsonWriter that wraps another IBsonWriter.

Interfaces

IBsonChunk

Represents a chunk of bytes.

IBsonChunkSource

Represents a source of chunks.

IBsonReader

Represents a BSON reader.

IBsonWriter

Represents a BSON writer.

IByteBuffer

Represents a byte buffer (backed by various means depending on the implementation).

IElementNameValidator

Represents an element name validator. Used by BsonWriters when WriteName is called to determine if the element name is valid.

INameDecoder

Represents a name decoder.

IStreamEfficientCopyTo

Represents the effective CopyTo method.

Enums

BsonReaderState

Represents the state of a reader.

BsonWriterState

Represents the state of a BsonWriter.

ContextType

Used by BsonReaders and BsonWriters to represent the current context.

JsonOutputMode

Represents the output mode of a JsonWriter.

JsonTokenType

Represents a JSON token type.