public class SearchCriteriaBuilder
extends java.lang.Object
AND a AND OR b OR cBoolean operators are repeated for every child, instead of appearing once and have many children. As this is unexpected for most programmers, this helper class provided for converting a usual recursive definition of the query expression, to the one expected by Contact Server.
Example:
SearchCriteriaCollection A = SearchCriteriaBuilder.build("Id", Operators.Like, "*");
SearchCriteriaCollection B = SearchCriteriaBuilder.build("Id", Operators.NotEqual, "2");
SearchCriteriaCollection C = SearchCriteriaBuilder.build("Id", Operators.Lesser, "10");
SearchCriteriaCollection BC = SearchCriteriaBuilder.build(Prefixes.Or, B, C);
SearchCriteriaCollection result = SearchCriteriaBuilder.build(Prefixes.And, A, BC);
Constructor | Description |
---|---|
SearchCriteriaBuilder() |
Modifier and Type | Method | Description |
---|---|---|
static SearchCriteriaCollection |
build(Prefixes prefix,
SearchCriteriaCollection... criterias) |
Creates SearchCriteriaCollection based on one or more search criteria collections.
|
static SearchCriteriaCollection |
build(java.lang.String name,
Operators operator,
java.lang.String value) |
Creates SearchCriteriaCollection based on one simple search criterias.
|
public static SearchCriteriaCollection build(java.lang.String name, Operators operator, java.lang.String value)
name
- attribute nameoperator
- operator typevalue
- attribute valuepublic static SearchCriteriaCollection build(Prefixes prefix, SearchCriteriaCollection... criterias)
prefix
- criterias
- collection of search creteriasSend comments on this topicTechpubs.webadmin@genesys.com.
Document version: 9.0.006.00
Copyright © 2006–2019 Genesys Telecommunications Laboratories, Inc. All rights reserved.