Method WithinCircle
WithinCircle<TMember>(Expression<Func<TDocument, TMember>>, double, double, double)
Tests that the value of the named element is within a circle (see $within and $center).
public IMongoQuery WithinCircle<TMember>(Expression<Func<TDocument, TMember>> memberExpression, double centerX, double centerY, double radius)
Parameters
memberExpression
Expression<Func<TDocument, TMember>>The member expression representing the element to test.
centerX
doubleThe x coordinate of the origin.
centerY
doubleThe y coordinate of the origin.
radius
doubleThe radius of the circle.
Returns
- IMongoQuery
An IMongoQuery.
Type Parameters
TMember
The member type.
WithinCircle<TMember>(Expression<Func<TDocument, TMember>>, double, double, double, bool)
Tests that the value of the named element is within a circle (see $within and $center).
public IMongoQuery WithinCircle<TMember>(Expression<Func<TDocument, TMember>> memberExpression, double centerX, double centerY, double radius, bool spherical)
Parameters
memberExpression
Expression<Func<TDocument, TMember>>The member expression representing the element to test.
centerX
doubleThe x coordinate of the origin.
centerY
doubleThe y coordinate of the origin.
radius
doubleThe radius of the circle.
spherical
boolif set to
true
[spherical].
Returns
- IMongoQuery
An IMongoQuery.
Type Parameters
TMember
The member type.