|
Project: stp | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public static interface CqQuery.FilterLeaf
A field/value comparison within a query filter expression; the leaf of a query filter expression. This structure is also used for specifying a dynamic filter value.
Nested Class Summary | |
---|---|
static class |
CqQuery.FilterLeaf.TargetType
A code indicating how the target of the comparison is being specified. |
Nested classes/interfaces inherited from interface CqQuery.Filter |
---|
CqQuery.Filter.Operation |
Method Summary | |
---|---|
void |
addTarget(CqQuery.FilterLeaf.TargetType targetType,
Object target)
Add the type and value for an additional target of the comparison. |
CqFieldDefinition[] |
getSource()
Returns the field path designating the source of the comparison. |
String |
getSourceName()
Returns the character image of the field path designating the source of the comparison |
String |
getTarget()
Returns the first target of the comparison. |
String |
getTarget(int index)
Returns the n-th target value of the comparison. |
int |
getTargetCount()
Returns the number of targets in this comparison expression Each comparison operation requires a different number of targets ranging from none (IS_NULL, IS_NOT_NULL) to many (IS_IN_SET, IS_NOT_IN_SET). |
List<String> |
getTargets()
Returns a list of all the target values for the comparison. |
CqQuery.FilterLeaf.TargetType |
getTargetType()
Returns the target type code for the first target. |
CqQuery.FilterLeaf.TargetType |
getTargetType(int index)
Returns the target type code for the n-th target of the comparison. |
CqQuery.FilterLeaf.TargetType[] |
getTargetTypes()
Returns an array of all the target types for the comparison corresponding to the vector of values returned by FilterLeaf.getTargets() . |
void |
setTarget(CqQuery.FilterLeaf.TargetType targetType)
Sets the first target of the comparison and resets the target count to 1. |
void |
setTarget(CqQuery.FilterLeaf.TargetType targettype,
Object target)
Sets the first target of the comparison and resets the target count to 1. |
void |
setTargets(CqQuery.FilterLeaf.TargetType[] targetTypes,
List<Object> targets)
Set the types and values of multiple targets for the comparison. |
void |
setTargets(Object... targets)
Set the type and value for each targets for the comparison. |
Methods inherited from interface CqQuery.Filter |
---|
getOperation, setOperation |
Method Detail |
---|
void addTarget(CqQuery.FilterLeaf.TargetType targetType, Object target)
targetType
- The type of the additional target value. Cannot be
null.target
- The additional target. The value provided will be
converted to a String object appropriate to the TargetType
specified. If null and a string value is required, the
empty string ("") will be used.CqFieldDefinition[] getSource()
CqFieldDefinition
object. The first
field in the path is a field of the query's primary record
type. All fields in the path, except for the last field, must
be reference-type fields, and in each case, the field that
follows the reference field must be a field of the record
type referenced by the preceding reference field. Will never
be null.String getSourceName()
String getTarget()
getTarget(0)
.String getTarget(int index)
index
- The 0-based index of the desired target. Must be less
than the target count.
int getTargetCount()
List<String> getTargets()
CqQuery.FilterLeaf.TargetType getTargetType()
CqQuery.FilterLeaf.TargetType getTargetType(int index)
index
- The 0-based index of the desired target. Must be less
than the target count.
CqQuery.FilterLeaf.TargetType[] getTargetTypes()
FilterLeaf.getTargets()
.
FilterLeaf.getTargets()
.void setTarget(CqQuery.FilterLeaf.TargetType targetType)
targetType
- A FilterLeaf.TargetType enumerator specifying the
type of the first target. This TargetType must be
TODAY, TOMORROW, YESTERDAY, or USERvoid setTarget(CqQuery.FilterLeaf.TargetType targettype, Object target)
targettype
- The type of the first target value. Cannot be null.target
- The first target value. The value provided will be
converted to a String object appropriate to the TargetType
specified. If null and a string value is required, the
empty string ("") will be used.void setTargets(CqQuery.FilterLeaf.TargetType[] targetTypes, List<Object> targets)
targetTypes
- An array of target type codes designating the way the
corresponding values in the targets parameter are
specified.targets
- An array of Object elements, each containing a target
value for the comparison. Cannot be null. The
values provided will be converted to a String objects
appropriate to the TargetTypes specified. If null
and a string value is required, the empty string ("") will
be used.void setTargets(Object... targets)
targets
- An array of TargetType codes and other Object values
designating the new targets of the comparison operation.
Nominally, this argument is an array of alternating TargetType and target value Objects specifying, respectively, the type and value of each filter target. However, for USER, YESTERDAY, TODAY, and TOMORROW target types, the associated null value may be elided. If a target value is not preceded by a target type, then the target type is assumed to be CONSTANT or UNKNOWN. Thus, although a TargetType may always be specified for each target value, a TargetType entry is is required only when specifying a PROMPTED, DATE_ONLY, or DATE_TIME target type.
Initially, an untyped value is assumed to be of type UNKNOWN, which means heuristics will be applied to the value to determine whether or not the value is a date/time value that needs to be converted to a form acceptable to ClearQuest. If, however, the CONSTANT type was used previously in the array, an untyped value is assumed to be of type CONSTANT, which means the value will be converted only if the field type is known to be DATE_TIME.
May be null or empty to specify no targets for the comparison operation.
|
Generated Thu 6-Nov-2014 11:02 PM | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |