82    string info = string(
"<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n") +
 
   83                  "<function name=\"geogrid\" version=\"1.2\" " 
   84                  "href=\"http://docs.opendap.org/index.php/Server_Side_Processing_Functions#geogrid\">\n" +
 
   88        Str *response = 
new Str(
"version");
 
  103    if (argc < 1 || !(l_grid = 
dynamic_cast<Grid *
>(argv[0]->ptr_duplicate())))
 
  110            "Wrong number of arguments to geogrid() (expected at least 5 args). See geogrid() for more information.");
 
  112    bool grid_lat_lon_form;
 
  115    if (!(l_lat = 
dynamic_cast<Array *
>(argv[1]))) 
 
  116        grid_lat_lon_form = 
false;
 
  117    else if (!(l_lon = 
dynamic_cast<Array *
>(argv[2]))) 
 
  118        throw Error(
malformed_expr, 
"When using the Grid, Lat, Lon form of geogrid() both the lat and lon maps must be " 
  119                                    "given (lon map missing)!");
 
  121        grid_lat_lon_form = 
true;
 
  123    if (grid_lat_lon_form && argc < 7)
 
  126            "Wrong number of arguments to geogrid() (expected at least 7 args). See geogrid() for more information.");
 
  145        (*i++)->set_send_p(
true);
 
  155    int min_arg_count = (grid_lat_lon_form) ? 7 : 5;
 
  156    if (argc > min_arg_count) {
 
  159        vector<GSEClause *> clauses;
 
  161        for (
int i = min_arg_count; i < argc; ++i) {
 
  178        int box_index_offset = (grid_lat_lon_form) ? 3 : 1;
 
  184        DBG(cerr << 
"geogrid: past bounding box set" << endl);
 
  188        DBG(cerr << 
"geogrid: past apply constraint" << endl);
 
  196    } 
catch (exception &e) {
 
  197        throw InternalErr(
string(
"A C++ exception was thrown from inside geogrid(): ") + e.
what());
 
 
  212    vector<Grid *> grids;
 
  216    if (!grids.empty()) {
 
  221        for (git = grids.begin(); !usable && git != grids.end(); git++) {
 
  223            usable = is_geo_grid(grid);
 
 
#define malformed_expr
(400)
 
void set_bounding_box(double top, double left, double bottom, double right)
 
bool canOperateOn(libdap::DDS &dds)
 
virtual libdap::Grid * get_constrained_grid() const
 
virtual void apply_constraint_to_data()
 
A multidimensional array of identical data types.
 
The basic data type for the DODS DAP types.
 
virtual BaseType * ptr_duplicate()=0
 
bool read() override
Read the elements of Constructor marked for transmission.
 
A class for error processing.
 
const char * what() const noexcept override
The pointer is valid only for the lifetime of the Error instance. jhrg 9/22/20.
 
Holds the Grid data type.
 
Map_iter map_begin()
Returns an iterator referencing the first Map vector.
 
std::vector< BaseType * >::iterator Map_iter
 
Array * get_array()
Returns the Grid Array. This method returns the array using an Array*, so no cast is required.
 
A class for software fault reporting.
 
Holds character string data.
 
virtual bool set_value(const string &value)
 
void set_read_p(bool state) override
Indicates that the data is ready to send.
 
void get_grids(BaseType *bt, vector< Grid * > *grids)
 
void function_geogrid(int argc, BaseType *argv[], DDS &, BaseType **btpp)
 
void parse_gse_expression(gse_arg *arg, BaseType *expr)
 
void apply_grid_selection_expressions(Grid *grid, vector< GSEClause * > clauses)
 
top level DAP object to house generic methods
 
double extract_double_value(BaseType *arg)