Class FalseExp
java.lang.Object
org.apache.cayenne.exp.Expression
org.apache.cayenne.exp.ConditionExp
org.apache.cayenne.exp.FalseExp
- All Implemented Interfaces:
XMLSerializable
Boolean false expression element
Notice that there is one TrueExp and one FalseExp instead of a single BooleanExp
with a Boolean value. The main reason for doing this is that a common
BooleanExp will have operand count of 1 and that will default to a prepared
statement like " where ? and (...)", but we only need " where true and
(...)".
- Since:
- 5.0
- See Also:
-
Field Summary
Fields inherited from class Expression
operands, PRUNED_NODE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidappendAsString(Appendable out) Appends own content as a String to the provided Appendable: the operands separated by the operator.protected BooleanevaluateSubNode(Object o, Object[] evaluatedChildren) protected StringgetExpressionOperator(int index) Returns the operator printed between the operands, before the operand at the given index.protected intprotected booleanWhether this node is wrapped in parentheses when printed as an operand of another node.Creates a copy of this expression node, without copying children.Methods inherited from class ConditionExp
evaluateNode, exists, isValidParent, notExistsMethods inherited from class Expression
andExp, andExp, appendOperandAsString, deepCopy, encodeAsXML, equals, evaluate, evaluateOperand, expName, filter, filterObjects, first, flattenTree, getOperand, getOperandCount, getPathAliases, hashCode, match, notExp, orExp, orExp, params, params, paramsArray, pruneNodeForPrunedChild, setOperand, setOperands, toString, transform, transformExpression, traverse, traverse
-
Constructor Details
-
FalseExp
-
-
Method Details
-
getRequiredChildrenCount
protected int getRequiredChildrenCount()- Specified by:
getRequiredChildrenCountin classConditionExp
-
evaluateSubNode
- Specified by:
evaluateSubNodein classConditionExp- Throws:
Exception
-
getExpressionOperator
Description copied from class:ExpressionReturns the operator printed between the operands, before the operand at the given index.- Specified by:
getExpressionOperatorin classExpression
-
shallowCopy
Description copied from class:ExpressionCreates a copy of this expression node, without copying children.- Specified by:
shallowCopyin classExpression
-
appendAsString
Description copied from class:ExpressionAppends own content as a String to the provided Appendable: the operands separated by the operator.- Overrides:
appendAsStringin classExpression- Throws:
IOException
-
parenthesizeAsOperand
protected boolean parenthesizeAsOperand()Description copied from class:ExpressionWhether this node is wrapped in parentheses when printed as an operand of another node. Compound nodes are, leaves and nodes with their own delimiters (function calls, lists) are not.- Overrides:
parenthesizeAsOperandin classExpression
-