C# Class MongoDB.Driver.Builders.IndexOptions

A builder for the options used when creating an index.
Show file Open project: CloudMetal/mongo-csharp-driver

Public Methods

Method Description
SetBackground ( bool value ) : IndexOptionsBuilder

Sets whether to build the index in the background.

SetBucketSize ( double value ) : IndexOptionsBuilder

Sets the bucket size for geospatial haystack indexes.

SetDropDups ( bool value ) : IndexOptionsBuilder

Sets whether duplicates should be dropped.

SetGeoSpatialRange ( double min, double max ) : IndexOptionsBuilder

Sets the geospatial range.

SetName ( string value ) : IndexOptionsBuilder

Sets the name of the index.

SetSparse ( bool value ) : IndexOptionsBuilder

Sets whether the index is a sparse index.

SetTimeToLive ( System.TimeSpan timeToLive ) : IndexOptionsBuilder

Sets the time to live value.

SetUnique ( bool value ) : IndexOptionsBuilder

Sets whether the index enforces unique values.

Method Details

SetBackground() public static method

Sets whether to build the index in the background.
public static SetBackground ( bool value ) : IndexOptionsBuilder
value bool Whether to build the index in the background.
return IndexOptionsBuilder

SetBucketSize() public static method

Sets the bucket size for geospatial haystack indexes.
public static SetBucketSize ( double value ) : IndexOptionsBuilder
value double The bucket size.
return IndexOptionsBuilder

SetDropDups() public static method

Sets whether duplicates should be dropped.
public static SetDropDups ( bool value ) : IndexOptionsBuilder
value bool Whether duplicates should be dropped.
return IndexOptionsBuilder

SetGeoSpatialRange() public static method

Sets the geospatial range.
public static SetGeoSpatialRange ( double min, double max ) : IndexOptionsBuilder
min double The min value of the range.
max double The max value of the range.
return IndexOptionsBuilder

SetName() public static method

Sets the name of the index.
public static SetName ( string value ) : IndexOptionsBuilder
value string The name of the index.
return IndexOptionsBuilder

SetSparse() public static method

Sets whether the index is a sparse index.
public static SetSparse ( bool value ) : IndexOptionsBuilder
value bool Whether the index is a sparse index.
return IndexOptionsBuilder

SetTimeToLive() public static method

Sets the time to live value.
public static SetTimeToLive ( System.TimeSpan timeToLive ) : IndexOptionsBuilder
timeToLive System.TimeSpan The time to live.
return IndexOptionsBuilder

SetUnique() public static method

Sets whether the index enforces unique values.
public static SetUnique ( bool value ) : IndexOptionsBuilder
value bool Whether the index enforces unique values.
return IndexOptionsBuilder