Skip to content

Commit

Permalink
Added types for Geospatial (#6747)
Browse files Browse the repository at this point in the history
  • Loading branch information
papafe authored and jedelbo committed Aug 1, 2023
1 parent d96c9ae commit 1bb97af
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions bindgen/spec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@ mixedInfo:
- LinkList
extraCtors:
- Obj
- Geospatial

enums:
SchemaMode:
Expand Down Expand Up @@ -362,6 +363,28 @@ records:
type: std::string
default: ''

GeoPoint:
fields:
longitude: double
latitude: double
altitude:
type: double
default: std::numeric_limits<double>::quiet_NaN()

GeoCircle:
fields:
radius_radians: double
center: GeoPoint

GeoBox:
fields:
lo: GeoPoint
hi: GeoPoint

GeoPolygon:
fields:
points: std::vector<std::vector<GeoPoint>>

RealmConfig:
fields:
path: std::string
Expand Down Expand Up @@ -752,6 +775,12 @@ classes:
get_seconds: int64_t
get_nanoseconds: int32_t

Geospatial:
constructors:
make_from_circle: '(circle: GeoCircle)'
make_from_box: '(box: GeoBox)'
make_from_polygon: '(polygon: GeoPolygon)'

ObjLink:
properties:
is_null: bool
Expand Down

0 comments on commit 1bb97af

Please sign in to comment.