Expand my Community achievements bar.

TaskSearchFilter.addCondition IN operator

Avatar

Level 2

Hello.

I have a question regarding TaskSearchFilter.addCondition() method

http://livedocs.adobe.com/livecycle/es/sdkHelp/programmer/javadoc/com/adobe/idp/taskmanager/dsc/clie...

How to use this method with operator "IN" (Operator.IN) ?

Let's say we what to list all task with status assigned (3) or deadlined (101) (sum of sets).

How to add this condition using TaskSearchFilter ?

....

tsf.addCondition(TaskSearchingConstants.pSTATUS, Operator.IN, <WHAT HERE>, Connective.AND)

...

What should be in place of <WHAT HERE>?

An array of Strings {"3","101"} or ints {1, 101}?

Or maby List of Integer obecjt ?

Please do not post solution :

tsf.addCondition(TaskSearchingConstants.pSTATUS, Operator.EQUALS, 3)

tsf.addCondition(TaskSearchingConstants.pSTATUS, Operator.EQUALS, 101, Connective.OR)

I'm interested in solution with collection of values and "IN" operator.

1 Reply

Avatar

Level 2

I done some tests and

there are two solutions

String [] arr = {"3", "101"};

tsf.addCondition(TaskSearchingConstants.pSTATUS, Operator.IN, arr, Connective.AND);

and second

int [] arr = {3 ,101}

tsf.addCondition(TaskSearchingConstants.pSTATUS, Operator.IN, arr, Connective.AND);

Both are working well....