|
2.17.2: 2011-06-17 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sf.basedb.core.query.WhenStatement
public class WhenStatement
Create a WHEN statement to be used in a CaseExpression
.
Expressions.caseWhen(Expression, WhenStatement[])
Field Summary | |
---|---|
private Restriction |
condition
|
private Expression |
value
|
Constructor Summary | |
---|---|
WhenStatement(Restriction condition,
Expression value)
Create a new WhenStatement |
Method Summary | |
---|---|
boolean |
equals(Object other)
This statement is equal to another WhenStatement if both have equal conditions and values. |
Restriction |
getCondition()
Get the condition of this statement. |
Expression |
getValue()
Get the value returned by this statement |
int |
hashCode()
|
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
private final Restriction condition
private final Expression value
Constructor Detail |
---|
public WhenStatement(Restriction condition, Expression value)
WhenStatement
condition
- The condition that is controlling if this
value is returned or not, null is not allowedvalue
- The value to return if the condition is TRUE,
null is not allowedMethod Detail |
---|
public Restriction getCondition()
Restriction
objectpublic Expression getValue()
Expression
objectpublic String toString()
toString
in class Object
public boolean equals(Object other)
equals
in class Object
public int hashCode()
hashCode
in class Object
|
2.17.2: 2011-06-17 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |