/**
* Test whether we can request excluded keyword search parameter.
*/
public void testGetExcludedKeyWordSearchParameter() throws Exception {
// Create selector and parameters.
TargetingIdeaSelector selector = new TargetingIdeaSelector();
ExcludedKeywordSearchParameter excludedKeywordSearchParameter =
new ExcludedKeywordSearchParameter();
Keyword keyword1 = new Keyword();
keyword1.setText("media player");
keyword1.setMatchType(KeywordMatchType.EXACT);
excludedKeywordSearchParameter.setKeywords(new Keyword[] {keyword1});
KeywordMatchTypeSearchParameter keywordMatchTypeSearchParameter =
new KeywordMatchTypeSearchParameter();
keywordMatchTypeSearchParameter.setKeywordMatchTypes(new KeywordMatchType[] {
KeywordMatchType.BROAD, KeywordMatchType.EXACT});
RelatedToKeywordSearchParameter relatedToKeywordSearchParameter =
new RelatedToKeywordSearchParameter();
Keyword keyword2 = new Keyword();
keyword2.setText("dvd player");
keyword2.setMatchType(KeywordMatchType.EXACT);
relatedToKeywordSearchParameter.setKeywords(new Keyword[] {keyword2});
selector.setSearchParameters(new SearchParameter[] {
excludedKeywordSearchParameter, keywordMatchTypeSearchParameter,
relatedToKeywordSearchParameter});
selector.setIdeaType(IdeaType.KEYWORD);
selector.setRequestType(RequestType.IDEAS);
Paging paging = new Paging(0, 1);
selector.setPaging(paging);
TargetingIdeaPage page = service.get(selector);
}