public class RelationalExpression
extends java.lang.Object
implements java.lang.Cloneable
The most common control parameters are Access profiles (_wcf.ap=IBM_Admin_Details) and data language Id (_wcf.dataLanguageIds='-1,-2').
The SelectionCriteriaHelper
class helps construct a selection criteria expression with the Access profile and data language Id control parameters.
Additional control parameters may be added to the expression using SelectionCriteriaHelper.addNameValuePair(RelationalExpression)
.
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
COPYRIGHT
IBM copyright statement
|
static java.lang.String |
STR_CONTAINS_OPERATOR
'Contains' operator used between the operands of the XPath relational expression.
|
static java.lang.String |
STR_ENDS_WITH_OPERATOR
'ends-with' operator used between the operands of the XPath relational expression.
|
static java.lang.String |
STR_EQ_OPERATOR
'Equals' operator used between the operands of the XPath relational expression.
|
static java.lang.String |
STR_GE_OPERATOR
'Greater than or equals' operator used between the operands of the XPath relational expression.
|
static java.lang.String |
STR_GT_OPERATOR
'Greater than' operator used between the operands of the XPath relational expression.
|
static java.lang.String |
STR_LE_OPERATOR
'Less than or equals' operator used between the operands of the XPath relational expression.
|
static java.lang.String |
STR_LT_OPERATOR
'Less than' operator used between the operands of the XPath relational expression.
|
static java.lang.String |
STR_NE_OPERATOR
'Not equals' operator used between the operands of the XPath relational expression.
|
static java.lang.String |
STR_STARTS_WITH_OPERATOR
'starts-with' operator used between the operands of the XPath relational expression.
|
Constructor and Description |
---|
RelationalExpression(RelationalExpression aRelExpr)
Initializes a newly created RelationalExpression object so that it represents the
same relational expression as the argument.
|
RelationalExpression(java.lang.String astrName,
java.util.List alValues)
Construct a relational expression.
|
RelationalExpression(java.lang.String astrName,
java.util.List alValues,
java.lang.String astrOperator)
Construct a relational expression.
|
RelationalExpression(java.lang.String astrName,
java.lang.String astrValue)
Construct a relational expression.
|
RelationalExpression(java.lang.String astrName,
java.lang.String astrValue,
java.lang.String astrOperator)
Construct a relational expression.
|
Modifier and Type | Method and Description |
---|---|
java.lang.StringBuffer |
appendQueryString(java.lang.StringBuffer asbBuffer,
int additionalCapacity)
Append a list of values of this relational expression as
name-value pairs separated by a semi-colon to the specified buffer.
|
java.lang.StringBuilder |
appendQueryStringBuilder(java.lang.StringBuilder asbBuffer,
int additionalCapacity)
Append a list of values of this relational expression as
name-value pairs separated by a semi-colon to the specified buffer.
|
java.lang.Object |
clone()
Returns a clone of this object.
|
boolean |
equals(RelationalExpression aRelExpr)
Indicates whether some other RelationExpression object is "equal to" this one.
|
java.lang.String |
getName()
Get the name of the operand
|
java.lang.String |
getOperator()
Return the comparison operator.
|
java.util.List |
getValues()
Return the values of the operand
|
void |
setName(java.lang.String name)
Set the name of the operand
|
void |
setOperator(java.lang.String operator)
Sets comparison operator.
|
void |
setValue(java.lang.String value)
Sets the value of the operand
|
java.lang.String |
toQueryString()
Return a list of values of this relational expression as
name-value pairs separated by a semi-colon.
|
java.lang.String |
toString()
Return string representation of this relational expression.
|
public static final java.lang.String COPYRIGHT
public static final java.lang.String STR_CONTAINS_OPERATOR
public static final java.lang.String STR_STARTS_WITH_OPERATOR
public static final java.lang.String STR_ENDS_WITH_OPERATOR
public static final java.lang.String STR_EQ_OPERATOR
public static final java.lang.String STR_LT_OPERATOR
public static final java.lang.String STR_GT_OPERATOR
public static final java.lang.String STR_LE_OPERATOR
public static final java.lang.String STR_GE_OPERATOR
public static final java.lang.String STR_NE_OPERATOR
public RelationalExpression(java.lang.String astrName, java.lang.String astrValue, java.lang.String astrOperator)
astrName
- - operand nameastrValue
- - operand valueastrOperator
- - comparison operatorpublic RelationalExpression(java.lang.String astrName, java.util.List alValues, java.lang.String astrOperator)
astrName
- - operand namealValues
- - list of String valuesastrOperator
- - comparison operatorpublic RelationalExpression(java.lang.String astrName, java.lang.String astrValue)
astrName
- - operand nameastrValue
- - operand value
Default operator is '='.public RelationalExpression(java.lang.String astrName, java.util.List alValues)
astrName
- - operand namealValues
- - list of String values
Default operator is '='.public RelationalExpression(RelationalExpression aRelExpr)
aRelExpr
- - relational expressionpublic java.lang.Object clone()
clone
in class java.lang.Object
Cloneable
public final java.lang.String getName()
public final java.util.List getValues()
public final java.lang.String getOperator()
public final void setName(java.lang.String name)
name
- The name of the operandpublic final void setOperator(java.lang.String operator)
operator
- The comparison operatorpublic final void setValue(java.lang.String value)
value
- The value of the relational expressionpublic java.lang.String toString()
toString
in class java.lang.Object
name operator [value1,value2,...]
public final java.lang.StringBuilder appendQueryStringBuilder(java.lang.StringBuilder asbBuffer, int additionalCapacity)
asbBuffer
- the buffer. If this is null, a new buffer is created and returned.additionalCapacity
- the buffer returned will have at least the specified additonal
capacity.public final java.lang.StringBuffer appendQueryString(java.lang.StringBuffer asbBuffer, int additionalCapacity)
asbBuffer
- the buffer. If this is null, a new buffer is created and returned.additionalCapacity
- the buffer returned will have at least the specified additonal
capacity.public java.lang.String toQueryString()
public boolean equals(RelationalExpression aRelExpr)
aRelExpr
- the reference object with which to compare.