38 static inline BOOL CBLGeoRectIsEmpty(
CBLGeoRect r) {
47 #pragma mark - CONVERTING TO/FROM JSON: 71 #pragma mark - KEYS FOR MAP FUNCTIONS: A 2D geometric point.
Definition: CBLGeometry.h:14
#define NS_ASSUME_NONNULL_BEGIN
Definition: CBLBase.h:20
A 2D geometric rectangle.
Definition: CBLGeometry.h:22
CBLJSONDict * CBLGeoRectToJSON(CBLGeoRect rect)
Converts a rectangle to GeoJSON format (as a polygon.) For details see http://geojson.org/geojson-spec.html#polygon.
#define __nullable
Definition: CBLBase.h:23
struct CBLGeoRect CBLGeoRect
A 2D geometric rectangle.
BOOL CBLGeoCoordsStringToRect(NSString *__nullable coordsStr, CBLGeoRect *outRect)
Converts a string of four comma-separated numbers ("x0,y0,x1,y1") to a rectangle. ...
#define NS_ASSUME_NONNULL_END
Definition: CBLBase.h:21
CBLJSONDict * CBLGeoPointToJSON(CBLGeoPoint pt)
Converts a point to GeoJSON format.
double y
Definition: CBLGeometry.h:15
CBLArrayOf(NSNumber *) *CBLGeoPointToCoordPair(CBLGeoPoint pt)
Converts a point to a JSON-compatible array of two coordinates.
BOOL CBLGeoCoordsToRect(NSArray *__nullable coords, CBLGeoRect *outRect)
Converts a JSON array of four coordinates [x0, y0, x1, y1] to a rectangle.
NS_ASSUME_NONNULL_BEGIN struct CBLGeoPoint CBLGeoPoint
A 2D geometric point.
CBLGeoPoint min
Definition: CBLGeometry.h:23
id CBLGeoJSONKey(NSDictionary *geoJSON)
Returns a special value that, when emitted as a key, is indexed as a GeoJSON shape.
id CBLGeoRectKey(double x0, double y0, double x1, double y1)
Returns a special value that, when emitted as a key, is indexed as a geometric rectangle.
id CBLGeoPointKey(double x, double y)
Returns a special value that, when emitted as a key, is indexed as a geometric point.
BOOL CBLGeoCoordPairToPoint(NSArray *__nullable coords, CBLGeoPoint *outPoint)
Converts a JSON array of two coordinates [x,y] back into a point.
BOOL CBLGeoJSONBoundingBox(NSDictionary *__nullable geoJSON, CBLGeoRect *outBBox)
Computes the bounding box of a GeoJSON object.
double x
Definition: CBLGeometry.h:15
CBLGeoPoint max
Definition: CBLGeometry.h:23