|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface SearchSRLTemplate
Defines the template used to search for standard responses.
To get a template instance, call the createSearchSRLTemplate method of the SRLManager, as shown here:
SearchSRLTemplate myTemplate = mSRLManager.createSearchSRLTemplate();
Then, define a search operator and filters by calling the setOperator() and addSearchAttribute() methods.
For instance, the following code snippet specifies that you are looking for standard responses which
contain the string "my product" in their subject OR in their body; additionally, the result is not case sensitive:
myTemplate.addSearchAttribute(SRLAttribute.SUBJECT,"my product",false);
myTemplate.addSearchAttribute(SRLAttribute.BODY,"my product",false);
myTemplate.setOperator(SRLOperator.OR);
Note: If the DATABASE service is not available, that is, if UCS is not connected,
you cannot use features associated with UCS, that is, SRL search.
SRLManager| Nested Class Summary | |
|---|---|
static class |
SearchSRLTemplate.SRLAttribute
Lists the possible attributes that you can use for a SRL search. |
static class |
SearchSRLTemplate.SRLOperator
Lists the possible attributes that you can use for a SRL search. |
| Method Summary | |
|---|---|
void |
addSearchAttribute(SearchSRLTemplate.SRLAttribute attribute,
java.lang.String searchValue,
boolean caseSensitive)
Adds an attribute value to be searched. |
SearchSRLTemplate.SRLOperator |
getOperator()
Returns the operator to be used for the search. |
SearchSRLAttribute[] |
getSearchAttributes()
Returns the SearchSRLAttributes of the SRL search filter. |
void |
removeSearchAttribute(SearchSRLTemplate.SRLAttribute attribute)
Removes an attribute value to be searched. |
void |
setOperator(SearchSRLTemplate.SRLOperator operator)
Sets an operator to be used for the search. |
| Method Detail |
|---|
SearchSRLTemplate.SRLOperator getOperator()
AND: the result matches all the attribute filters.OR: the result matches any attribute filter.
void setOperator(SearchSRLTemplate.SRLOperator operator)
AND: the result matches all the attribute filters.OR: the result matches any attribute filter.
operator - SRLOperator
void addSearchAttribute(SearchSRLTemplate.SRLAttribute attribute,
java.lang.String searchValue,
boolean caseSensitive)
attribute - the attribute type to use for the search.searchValue - the value searched for this attribute.caseSensitive - true if the search to be processed is case sensitive.void removeSearchAttribute(SearchSRLTemplate.SRLAttribute attribute)
attribute - the attribute to be removed.SearchSRLAttribute[] getSearchAttributes()
SearchSRLAttributes of the SRL search filter.
SearchSRLAttribute.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||