cql2_helpers | R Documentation |
These are helper functions to easy construction CQL2 expressions.
These functions are not meant to be used in expressions and they must
be escaped using {{
to be evaluated before request.
cql2_bbox_as_geojson(bbox)
cql2_date(x)
cql2_timestamp(x)
cql2_interval(start = "..", end = "..")
bbox |
a |
x , start , end |
a |
cql2_bbox_as_geojson()
: used to convert bounding box (bbox) to a
GeoJSON object to be used as argument of CQL2 spatial operators.
cql2_date()
, cql2_timestamp()
, and cql2_interval()
:
create temporal literal values to be passed into CQL2 expressions.
cql2_bbox_as_geojson()
: GeoJSON object.
cql2_date()
, cql2_timestamp()
, and cql2_interval()
:
internal rstac
expressions representing temporal values.
## Not run:
bbox <- c(-122.2751, 47.5469, -121.9613, 47.7458)
cql2_json(
collection == "landsat-c2-l2" &&
t_intersects(datetime, {{
cql2_interval("2020-12-01", "2020-12-31")
}}) &&
s_intersects(geometry, {{
cql2_bbox_as_geojson(bbox)
}})
)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.