dods.dap.Server
Interface TopLevelClause

All Superinterfaces:
Clause
All Known Implementing Classes:
BoolFunctionClause, RelOpClause

public interface TopLevelClause
extends Clause

Represents a top-level clause in the selection portion of a constraint expression (CE).

A top-level clause is a boolean expression preceded by "&" in the CE, such as "lat>10.0", or "function(var1,var2)". The top-level clause may contain sub-clauses which can be evaluated individually. The parser supports several kinds of top-level clause. These are described in the ClauseFactory interface.

Author:
joew
See Also:
for more about sub-clauses., for an explanation of how Clauses are evaluated on data., ClauseFactory

Method Summary
 boolean evaluate()
          Evaluates the clause, first calling evaluate() on any sub-clauses it contains.
 boolean getValue()
          Returns the current value of the clause.
 
Methods inherited from interface dods.dap.Server.Clause
getChildren, isConstant, isDefined
 

Method Detail

getValue

boolean getValue()
Returns the current value of the clause. The value of non-constant Clauses is undefined until the evaluate() method has been called.


evaluate

boolean evaluate()
                 throws SDODSException
Evaluates the clause, first calling evaluate() on any sub-clauses it contains. Implementations of this method should flag the clause as "defined" if the evaluation is successful.

Throws:
SDODSException - Thrown if the evaluation fails for any reason.