org.enhydra.shark.api.common
Interface ResourceFilterBuilder

All Superinterfaces:
FilterBuilder

public interface ResourceFilterBuilder
extends FilterBuilder

ResourceIteratorExpressionBuilder

All methods are returning the object itself to allow stacking method calls on the same object.

Version:
0.2
Author:
V.Puskas

Field Summary
 
Fields inherited from interface org.enhydra.shark.api.common.FilterBuilder
ORDER_ASCENDING, ORDER_DESCENDING, SQL_TYPE_ACTIVITY, SQL_TYPE_ASSIGNMENT, SQL_TYPE_EVENT_AUDIT, SQL_TYPE_MANAGER, SQL_TYPE_PROCESS, SQL_TYPE_RESOURCE
 
Method Summary
 WMFilter addAssignemtCountEquals(WMSessionHandle sHandle, long cnt)
          Appends condition "resources assignments count == value of cnt"
 WMFilter addAssignemtCountGreaterThan(WMSessionHandle sHandle, long cnt)
          Appends condition "resources assignments count > value of cnt"
 WMFilter addAssignemtCountLessThan(WMSessionHandle sHandle, long cnt)
          Appends condition "resources assignments count < value of cnt"
 WMFilter addUsernameEquals(WMSessionHandle sHandle, java.lang.String un)
          Appends condition "resources username == value of un"
 WMFilter setOrderByUsername(WMSessionHandle sHandle, WMFilter filter, boolean ascending)
          Methods starting with setOrderBy obviously don't affect actual expression (nor its evaluation), rather they affect sorting of the result.
 
Methods inherited from interface org.enhydra.shark.api.common.FilterBuilder
addBshExpression, and, andForArray, createEmptyFilter, getIteratorEmptyExpression, not, or, orForArray, setLimit, setStartPosition, toIteratorExpression
 

Method Detail

addUsernameEquals

public WMFilter addUsernameEquals(WMSessionHandle sHandle,
                                  java.lang.String un)
                           throws java.lang.Exception
Appends condition "resources username == value of un"

Parameters:
un -
Returns:
itself
Throws:
java.lang.Exception

addAssignemtCountEquals

public WMFilter addAssignemtCountEquals(WMSessionHandle sHandle,
                                        long cnt)
                                 throws java.lang.Exception
Appends condition "resources assignments count == value of cnt"

Parameters:
cnt -
Returns:
itself
Throws:
java.lang.Exception

addAssignemtCountLessThan

public WMFilter addAssignemtCountLessThan(WMSessionHandle sHandle,
                                          long cnt)
                                   throws java.lang.Exception
Appends condition "resources assignments count < value of cnt"

Parameters:
cnt -
Returns:
itself
Throws:
java.lang.Exception

addAssignemtCountGreaterThan

public WMFilter addAssignemtCountGreaterThan(WMSessionHandle sHandle,
                                             long cnt)
                                      throws java.lang.Exception
Appends condition "resources assignments count > value of cnt"

Parameters:
cnt -
Returns:
itself
Throws:
java.lang.Exception

setOrderByUsername

public WMFilter setOrderByUsername(WMSessionHandle sHandle,
                                   WMFilter filter,
                                   boolean ascending)
                            throws java.lang.Exception
Methods starting with setOrderBy obviously don't affect actual expression (nor its evaluation), rather they affect sorting of the result.

This method sets ordering by resource username name value.

Parameters:
ascending -
Returns:
itself
Throws:
java.lang.Exception