Interface WorkbasketQuery

    • Method Detail

      • idIn

        WorkbasketQuery idIn​(String... id)
        Add your ids to your query. The ids are compared to the ids of workbaskets with the IN operator.
        Parameters:
        id - the id as Strings
        Returns:
        the query
      • keyIn

        WorkbasketQuery keyIn​(String... key)
        Add your keys to your query. The keys are compared case-insensitively to the keys of workbaskets with the IN operator.
        Parameters:
        key - the keys as Strings
        Returns:
        the query
      • keyLike

        WorkbasketQuery keyLike​(String... key)
        Add keys to your query. The keys are compared case-insensitively to the keys of workbaskets with the SQL LIKE operator. You may add a wildcard like '%' to search generically. If you specify multiple keys they are connected with an OR operator, this is, the query searches workbaskets whose keys are like key1 or like key2, etc.
        Parameters:
        key - the keys as Strings
        Returns:
        the query
      • nameIn

        WorkbasketQuery nameIn​(String... name)
        Add your names to your query. The names are compared case-insensitively to the names of workbaskets
        Parameters:
        name - the names as Strings
        Returns:
        the query
      • nameLike

        WorkbasketQuery nameLike​(String... name)
        Add names to your query. The names are compared case-insensitively to the names of workbaskets with the SQL LIKE operator. You may add a wildcard like '%' to search generically. If you specify multiple names, they are connected with an OR operator, this is, the query searches workbaskets whose names are like name1 or like name2, etc.
        Parameters:
        name - the names as Strings
        Returns:
        the query
      • keyOrNameLike

        WorkbasketQuery keyOrNameLike​(String... searchString)
        Add search strings to your query that are searched case-insensitively in the key and name fields of workbaskets. You may add a wildcard like '%' to search generically. If you specify multiple keys they are connected with an OR operator, this is, the query searches workbaskets whose keys are like string1 or whose names are like string1 or whose keys are like string2 or whose names are like string2, etc...
        Parameters:
        searchString - the seach strings
        Returns:
        the query
      • domainIn

        WorkbasketQuery domainIn​(String... domain)
        Add your domains to your query.
        Parameters:
        domain - the domains as Strings
        Returns:
        the query
      • createdWithin

        WorkbasketQuery createdWithin​(TimeInterval... intervals)
        Add the time intervals within which the workbasket was created to your query. For each time interval, the database query will search for workbaskets whose created timestamp is after or at the interval's begin and before or at the interval's end. If more than one interval is specified, the query will connect them with the OR keyword. If either begin or end of an interval are null, these values will not be specified in the query.
        Parameters:
        intervals - - the TimeIntervals within which the workbasket was created
        Returns:
        the query
      • modifiedWithin

        WorkbasketQuery modifiedWithin​(TimeInterval... intervals)
        Add the time intervals within which the workbasket was modified to your query. For each time interval, the database query will search for workbaskets whose created timestamp is after or at the interval's begin and before or at the interval's end. If more than one interval is specified, the query will connect them with the OR keyword. If either begin or end of an interval are null, these values will not be specified in the query.
        Parameters:
        intervals - - the TimeIntervals within which the workbasket was created
        Returns:
        the query
      • descriptionLike

        WorkbasketQuery descriptionLike​(String... description)
        Add your description to your query. It will be compared case-insensitively to the descriptions of workbaskets using the LIKE operator. You may use a wildcard like '%' to search generically. If you specify multiple arguments they are combined with the OR keyword.
        Parameters:
        description - your description
        Returns:
        the query
      • ownerIn

        WorkbasketQuery ownerIn​(String... owners)
        Add the owners to your query.
        Parameters:
        owners - the owners as String
        Returns:
        the query
      • ownerLike

        WorkbasketQuery ownerLike​(String... owners)
        Add the owners for pattern matching to your query. It will be compared in SQL with the LIKE operator. You may use a wildcard like % to specify the pattern. If you specify multiple arguments they are combined with the OR keyword.
        Parameters:
        owners - the owners as Strings
        Returns:
        the query
      • accessIdsHavePermission

        WorkbasketQuery accessIdsHavePermission​(WorkbasketPermission permission,
                                                String... accessIds)
                                         throws InvalidArgumentException,
                                                NotAuthorizedException
        Setting up the permission which should be granted on the result workbaskets and the users which should be checked. READ permission will always be checked by default.
        The AccessIds and the given permission will throw a Exception if they would be NULL.
        Parameters:
        permission - which should be used for results.
        accessIds - Users which sould be checked for given permissions on workbaskets.
        Returns:
        the current query object.
        Throws:
        InvalidArgumentException - when permission OR the accessIds are NULL.
        NotAuthorizedException - if the current user is not member of role BUSINESS_ADMIN or ADMIN
      • callerHasPermission

        WorkbasketQuery callerHasPermission​(WorkbasketPermission permission)
        Add condition to query if the caller (one of the accessIds of the caller) has the given permission on the workbasket.
        Parameters:
        permission - the permission for the query condition.
        Returns:
        the updated query.
      • orderByName

        WorkbasketQuery orderByName​(BaseQuery.SortDirection sortDirection)
        Sort the query result by name.
        Parameters:
        sortDirection - Determines whether the result is sorted in ascending or descending order. If sortDirection is null, the result is sorted in ascending order
        Returns:
        the query
      • orderByKey

        WorkbasketQuery orderByKey​(BaseQuery.SortDirection sortDirection)
        Sort the query result by key.
        Parameters:
        sortDirection - Determines whether the result is sorted in ascending or descending order. If sortDirection is null, the result is sorted in ascending order
        Returns:
        the query
      • orderByDescription

        WorkbasketQuery orderByDescription​(BaseQuery.SortDirection sortDirection)
        Sort the query result by description.
        Parameters:
        sortDirection - Determines whether the result is sorted in ascending or descending order. If sortDirection is null, the result is sorted in ascending order
        Returns:
        the query
      • orderByOwner

        WorkbasketQuery orderByOwner​(BaseQuery.SortDirection sortDirection)
        Sort the query result by owner.
        Parameters:
        sortDirection - Determines whether the result is sorted in ascending or descending order. If sortDirection is null, the result is sorted in ascending order
        Returns:
        the query
      • orderByType

        WorkbasketQuery orderByType​(BaseQuery.SortDirection sortDirection)
        Sort the query result by type.
        Parameters:
        sortDirection - Determines whether the result is sorted in ascending or descending order. If sortDirection is null, the result is sorted in ascending order
        Returns:
        the query
      • orderByDomain

        WorkbasketQuery orderByDomain​(BaseQuery.SortDirection sortDirection)
        Sort the query result by domain.
        Parameters:
        sortDirection - Determines whether the result is sorted in ascending or descending order. If sortDirection is null, the result is sorted in ascending order
        Returns:
        the query
      • domainLike

        WorkbasketQuery domainLike​(String... domain)
        Add the domains for pattern matching to your query. It will be compared in SQL with the LIKE operator. You may use a wildcard like % to specify the pattern. If you specify multiple arguments they are combined with the OR keyword.
        Parameters:
        domain - the domains of workbaskets as Strings
        Returns:
        the query
      • orderByCustomAttribute

        WorkbasketQuery orderByCustomAttribute​(WorkbasketCustomField customField,
                                               BaseQuery.SortDirection sortDirection)
        This method sorts the query result according to the value of a custom field.
        Parameters:
        customField - identifies which custom attribute is affected.
        sortDirection - Determines whether the result is sorted in ascending or descending order. If sortDirection is null, the result is sorted in ascending order
        Returns:
        the query
      • orderByOrgLevel1

        WorkbasketQuery orderByOrgLevel1​(BaseQuery.SortDirection sortDirection)
        Sort the query result by organization level 1.
        Parameters:
        sortDirection - Determines whether the result is sorted in ascending or descending order. If sortDirection is null, the result is sorted in ascending order
        Returns:
        the query
      • orderByOrgLevel2

        WorkbasketQuery orderByOrgLevel2​(BaseQuery.SortDirection sortDirection)
        Sort the query result by organization level 2.
        Parameters:
        sortDirection - Determines whether the result is sorted in ascending or descending order. If sortDirection is null, the result is sorted in ascending order
        Returns:
        the query
      • orderByOrgLevel3

        WorkbasketQuery orderByOrgLevel3​(BaseQuery.SortDirection sortDirection)
        Sort the query result by organization level 3.
        Parameters:
        sortDirection - Determines whether the result is sorted in ascending or descending order. If sortDirection is null, the result is sorted in ascending order
        Returns:
        the query
      • orderByOrgLevel4

        WorkbasketQuery orderByOrgLevel4​(BaseQuery.SortDirection sortDirection)
        Sort the query result by organization level 4.
        Parameters:
        sortDirection - Determines whether the result is sorted in ascending or descending order. If sortDirection is null, the result is sorted in ascending order
        Returns:
        the query
      • customAttributeIn

        WorkbasketQuery customAttributeIn​(WorkbasketCustomField customField,
                                          String... searchArguments)
        Add the values of custom attributes for exact matching to your query.
        Parameters:
        customField - identifies which custom attribute is affected.
        searchArguments - the customField values of the searched for tasks
        Returns:
        the query
      • customAttributeLike

        WorkbasketQuery customAttributeLike​(WorkbasketCustomField customField,
                                            String... searchArguments)
        Add the values of custom attributes for pattern matching to your query. They will be compared in SQL with the LIKE operator. You may use a wildcard like % to specify the pattern. If you specify multiple arguments they are combined with the OR keyword.
        Parameters:
        customField - identifies which custom attribute is affected.
        searchArguments - the customField values of the searched-for tasks
        Returns:
        the query
      • orgLevel1In

        WorkbasketQuery orgLevel1In​(String... orgLevel1)
        Add the 1st organization level to your query.
        Parameters:
        orgLevel1 - the 1st organization level as String
        Returns:
        the query
      • orgLevel1Like

        WorkbasketQuery orgLevel1Like​(String... orgLevel1)
        Add the 1st organization level for pattern matching to your query. It will be compared in SQL with the LIKE operator. You may use a wildcard like % to specify the pattern. If you specify multiple arguments they are combined with the OR keyword.
        Parameters:
        orgLevel1 - the 1st organization level as Strings
        Returns:
        the query
      • orgLevel2In

        WorkbasketQuery orgLevel2In​(String... orgLevel2)
        Add the 2nd organization level to your query.
        Parameters:
        orgLevel2 - the 2nd organization level as String
        Returns:
        the query
      • orgLevel2Like

        WorkbasketQuery orgLevel2Like​(String... orgLevel2)
        Add the 2nd organization level for pattern matching to your query. It will be compared in SQL with the LIKE operator. You may use a wildcard like % to specify the pattern. If you specify multiple arguments they are combined with the OR keyword.
        Parameters:
        orgLevel2 - the 2nd organization level as Strings
        Returns:
        the query
      • orgLevel3In

        WorkbasketQuery orgLevel3In​(String... orgLevel3)
        Add the 3rd organization level to your query.
        Parameters:
        orgLevel3 - the 3rd organization level as String
        Returns:
        the query
      • orgLevel3Like

        WorkbasketQuery orgLevel3Like​(String... orgLevel3)
        Add the 3rd organization level for pattern matching to your query. It will be compared in SQL with the LIKE operator. You may use a wildcard like % to specify the pattern. If you specify multiple arguments they are combined with the OR keyword.
        Parameters:
        orgLevel3 - the 3rd organization level as Strings
        Returns:
        the query
      • orgLevel4In

        WorkbasketQuery orgLevel4In​(String... orgLevel4)
        Add the 4th organization level to your query.
        Parameters:
        orgLevel4 - the 4th organization level as String
        Returns:
        the query
      • orgLevel4Like

        WorkbasketQuery orgLevel4Like​(String... orgLevel4)
        Add the 4th organization level for pattern matching to your query. It will be compared in SQL with the LIKE operator. You may use a wildcard like % to specify the pattern. If you specify multiple arguments they are combined with the OR keyword.
        Parameters:
        orgLevel4 - the 4th organization level as Strings
        Returns:
        the query
      • markedForDeletion

        WorkbasketQuery markedForDeletion​(boolean markedForDeletion)
        Add to your query if the Workbasket shall be marked for deletion.
        Parameters:
        markedForDeletion - a simple flag showing if the workbasket is marked for deletion
        Returns:
        the query