cmr.opendap.ous.core
Documentation forthcoming
apply-bounding-conditions
(apply-bounding-conditions search-endpoint user-token coll {:keys [bounding-box variables], :as params})There are several variable and bounding scenarios we need to consider:
- no spatial subsetting and no variables - return no query string in OPeNDAP URL; this will give users all variables for the entire extent defined in the variables’ metadata.
- variables but no spatial subsetting - return a query string with just the variables requested; a
Latitude,Longitudewill also be appended to the OPeNDAP URL; this will give users just these variables, but for the entire extent defined in each variable’s metadata. - variables and spatial subsetting - return a query string with the variables requested as well as the subsetting requested; this will give users just these variables, with data limited to the specified spatial range.
- spatial subsetting but no variables - this is a special case that needs to do a little more work: special subsetting without variables will link to an essentially empty OPeNDAP file; as such, we need to iterate through all the variables in the metadata and create an OPeNDAP URL query string that provides the sensible default of all variables.
For each of those conditions, a different value of vars will be returned, allowing for the desired result. Respective to the bullet points above:
vars- empty vectorvars- metadata for all the specified variable idsvars- metadata for all the specified variable idsvars- metadata for all the variables associated in the collection
bounding-info->opendap-lat-lon
(bounding-info->opendap-lat-lon {var-name :name, opendap-bounds :opendap})Documentation forthcoming
bounding-info->opendap-query
(bounding-info->opendap-query bounding-info)(bounding-info->opendap-query bounding-info bounding-box)Documentation forthcoming
data-file->opendap-url
(data-file->opendap-url pattern-info data-file)Documentation forthcoming
data-files->opendap-urls
(data-files->opendap-urls params pattern-info data-files query-string)Documentation forthcoming
fallback-pattern
Documentation forthcoming
fallback-replacement
Documentation forthcoming
get-opendap-urls
(get-opendap-urls search-endpoint user-token raw-params)Documentation forthcoming