C# Class MongoDB.Driver.Builders.IndexKeysBuilder

Inheritance: BuilderBase
Exibir arquivo Open project: CloudMetal/mongo-csharp-driver Class Usage Examples

Public Methods

Method Description
Ascending ( ) : IndexKeysBuilder

Sets one or more key names to index in ascending order.

Descending ( ) : IndexKeysBuilder

Sets one or more key names to index in descending order.

GeoSpatial ( string name ) : IndexKeysBuilder

Sets the key name to create a geospatial index on.

GeoSpatialHaystack ( string name ) : IndexKeysBuilder

Sets the key name to create a geospatial haystack index on.

GeoSpatialHaystack ( string name, string additionalName ) : IndexKeysBuilder

Sets the key name and additional field name to create a geospatial haystack index on.

IndexKeysBuilder ( ) : System

Initializes a new instance of the IndexKeysBuilder class.

ToBsonDocument ( ) : BsonDocument

Returns the result of the builder as a BsonDocument.

Protected Methods

Method Description
Serialize ( BsonWriter bsonWriter, Type nominalType, IBsonSerializationOptions options ) : void

Serializes the result of the builder to a BsonWriter.

Method Details

Ascending() public method

Sets one or more key names to index in ascending order.
public Ascending ( ) : IndexKeysBuilder
return IndexKeysBuilder

Descending() public method

Sets one or more key names to index in descending order.
public Descending ( ) : IndexKeysBuilder
return IndexKeysBuilder

GeoSpatial() public method

Sets the key name to create a geospatial index on.
public GeoSpatial ( string name ) : IndexKeysBuilder
name string The key name.
return IndexKeysBuilder

GeoSpatialHaystack() public method

Sets the key name to create a geospatial haystack index on.
public GeoSpatialHaystack ( string name ) : IndexKeysBuilder
name string The key name.
return IndexKeysBuilder

GeoSpatialHaystack() public method

Sets the key name and additional field name to create a geospatial haystack index on.
public GeoSpatialHaystack ( string name, string additionalName ) : IndexKeysBuilder
name string The key name.
additionalName string The name of an additional field to index.
return IndexKeysBuilder

IndexKeysBuilder() public method

Initializes a new instance of the IndexKeysBuilder class.
public IndexKeysBuilder ( ) : System
return System

Serialize() protected method

Serializes the result of the builder to a BsonWriter.
protected Serialize ( BsonWriter bsonWriter, Type nominalType, IBsonSerializationOptions options ) : void
bsonWriter BsonWriter The writer.
nominalType System.Type The nominal type.
options IBsonSerializationOptions The serialization options.
return void

ToBsonDocument() public method

Returns the result of the builder as a BsonDocument.
public ToBsonDocument ( ) : BsonDocument
return BsonDocument