38#include "D4FilterClause.h"
45D4FilterClauseList::m_duplicate(
const D4FilterClauseList &src)
49 for (D4FilterClauseList::citer i = src.cbegin(), e = src.cend(); i != e; ++i) {
50 D4FilterClause *fc = *i;
51 d_clauses.push_back(
new D4FilterClause(*fc));
55D4FilterClauseList::~D4FilterClauseList()
57 for (D4FilterClauseList::iter i = d_clauses.begin(), e = d_clauses.end(); i != e; ++i) {
76 for (D4FilterClauseList::iter i = d_clauses.begin(), e = d_clauses.end(); i != e; ++i) {
77 if ((*i)->value(dmr) ==
false)
97 for (D4FilterClauseList::iter i = d_clauses.begin(), e = d_clauses.end(); i != e; ++i) {
98 if ((*i)->value() ==
false)
116 case D4RValue::basetype:
119 case D4RValue::constant:
120 d_arg1 =
new D4RValue(*(rhs.d_arg1));
123 throw Error(malformed_expr,
"found a filter clause with a function call.");
127 case D4RValue::basetype:
130 case D4RValue::constant:
131 d_arg2 =
new D4RValue(*(rhs.d_arg2));
134 throw Error(malformed_expr,
"found a filter clause with a function call.");
150 throw InternalErr(__FILE__, __LINE__,
"While evaluating a constraint filter clause: Found a null operator");
159 return cmp(d_op, d_arg1->
value(dmr), d_arg2->
value(dmr));
163 throw InternalErr(__FILE__, __LINE__,
"While evaluating a constraint filter clause: Filter operator not implemented");
166 throw InternalErr(__FILE__, __LINE__,
"While evaluating a constraint filter clause: Unrecognized operator");
181 throw InternalErr(__FILE__, __LINE__,
"While evaluating a constraint filter clause: Found a null operator");
190 return cmp(d_op, d_arg1->
value(), d_arg2->
value());
194 throw InternalErr(__FILE__, __LINE__,
"While evaluating a constraint filter clause: Filter operator not implemented");
197 throw InternalErr(__FILE__, __LINE__,
"While evaluating a constraint filter clause: Unrecognized operator");
209 return arg1->
d4_ops(arg2, op);
The basic data type for the DODS DAP types.
virtual bool d4_ops(BaseType *b, int op)
Evaluator a relop for DAP4.
bool value()
Evaluate the list of clauses.
bool value()
Get the value of this relational expression. This version of value() will not work for clauses where ...
value_kind get_kind() const
What kind of thing holds the value Values in DAP4 constraints are either constants,...
virtual BaseType * value(DMR &dmr)
Get the value for a RValue object Return the BaseType * for a given RValue. For a dataset variable,...
A class for error processing.
A class for software fault reporting.
top level DAP object to house generic methods