76 DBG(cerr <<
"Entering function_grid..." << endl);
79 string(
"<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n") +
80 "<function name=\"grid\" version=\"1.0\" href=\"http://docs.opendap.org/index.php/Server_Side_Processing_Functions#grid\">\n" +
84 Str *response =
new Str(
"info");
85 response->set_value(info);
90 Grid *original_grid = dynamic_cast < Grid * >(argv[0]);
92 throw Error(malformed_expr,
"The first argument to grid() must be a Grid variable!");
96 BaseType *btp = original_grid->ptr_duplicate();
97 Grid *l_grid = dynamic_cast < Grid * >(btp);
100 throw InternalErr(__FILE__, __LINE__,
"Expected a Grid.");
103 DBG(cerr <<
"grid: past initialization code" << endl);
111 Grid::Map_iter i = l_grid->map_begin();
112 while (i != l_grid->map_end())
113 (*i++)->set_send_p(
true);
117 DBG(cerr <<
"grid: past map read" << endl);
123 vector < GSEClause * > clauses;
125 for (
int i = 1; i < argc; ++i) {
134 DBG(cerr <<
"grid: past gse application" << endl);
136 l_grid->get_array()->set_send_p(
true);
157 vector<Grid *> grids;
160 return !grids.empty();
162 bool usable = !grids->empty();
void getGrids(BaseType *bt, vector< Grid * > *grids)
Recursively traverses the BaseType bt (if its a constructor type) and collects pointers to all of the...
void apply_grid_selection_expressions(Grid *grid, vector< GSEClause * >clauses)
static class NCMLUtil overview
bool canOperateOn(DDS &dds)
The passed DDS parameter dds is evaluated to see if it contains Grid objects.
Argument to the GSE parser.
void function_grid(int argc, BaseType *argv[], DDS &, BaseType **btpp)
The grid function uses a set of relational expressions to form a selection within a Grid variable bas...
void parse_gse_expression(gse_arg *arg, BaseType *expr)