Table of Contents

Method Geo2DSphere

Namespace
MongoDB.Driver
Assembly
MongoDB.Driver.dll

Geo2DSphere(FieldDefinition<TDocument>)

Creates a 2dsphere index key definition.

public IndexKeysDefinition<TDocument> Geo2DSphere(FieldDefinition<TDocument> field)

Parameters

field FieldDefinition<TDocument>

The field.

Returns

IndexKeysDefinition<TDocument>

A 2dsphere index key definition.

Geo2DSphere(Expression<Func<TDocument, object>>)

Creates a 2dsphere index key definition.

public IndexKeysDefinition<TDocument> Geo2DSphere(Expression<Func<TDocument, object>> field)

Parameters

field Expression<Func<TDocument, object>>

The field.

Returns

IndexKeysDefinition<TDocument>

A 2dsphere index key definition.