Compartir a través de


Geometry.Within(Geometry) Método

Definición

Determina si el interior Geometry actual está totalmente contenido en outerGeometry el servicio Azure Cosmos DB.

public bool Within(Azure.Cosmos.Spatial.Geometry outer);
member this.Within : Azure.Cosmos.Spatial.Geometry -> bool
Public Function Within (outer As Geometry) As Boolean

Parámetros

outer
Geometry

Exterior Geometry.

Devoluciones

true si el interior Geometry actual está totalmente contenido dentro de outerGeometry. En caso contrario, es false.

Ejemplos

Polygon polygon = new Polygon(
       new[]
       {
            new Position(10, 10),
            new Position(30, 10),
            new Position(30, 30),
            new Position(10, 30),
            new Position(10, 10)
       });
var withinQuery = documents.Where(document => document.Location.Within(polygon));

Comentarios

Actualmente, esta función admite la geometría actual del tipo Point y la geometría externa del tipo Polygon.

Se aplica a