|
Carrot2 v3.3.0
API Documentation |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.carrot2.source.boss.BossSearchService
org.carrot2.source.boss.BossWebSearchService
public final class BossWebSearchService
Sends queries to Yahoo! Boss Web search service. Instances of this class are thread-safe.
Attributes of this class correspond to Yahoo's documentation (see links below).
| Nested Class Summary | |
|---|---|
static class |
BossWebSearchService.OffensiveContentFilter
Constants for offensive content filtering. |
| Field Summary | |
|---|---|
BossWebSearchService.OffensiveContentFilter |
filter
Filters out adult or hate content. |
String |
serviceURI
Boss Web search service URI. |
String |
type
Restricts search to documents of the specified types. |
| Fields inherited from class org.carrot2.source.boss.BossSearchService |
|---|
appid, CARROTSEARCH_APPID, languageAndRegion, logger, metadata, sites, YBOSS_RESPONSE |
| Constructor Summary | |
|---|---|
BossWebSearchService()
|
|
| Method Summary | |
|---|---|
protected ArrayList<org.apache.commons.httpclient.NameValuePair> |
createRequestParams(String query,
int start,
int results)
Assembles an array of NameValuePair with request parameters. |
protected String |
getServiceURI()
|
| Methods inherited from class org.carrot2.source.boss.BossSearchService |
|---|
query |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public String serviceURI
${query} place holder will be replaced with the
URL-encoded text of the processed query.
public BossWebSearchService.OffensiveContentFilter filter
The following content types are supported:
| Value | Content |
|---|---|
-porn |
Filters out adult content |
-hate |
Filters out hate content |
Adult content filtering is supported for all languages, hate content filtering is supported for English only.
public String type
The following document types are supported:
| Value | Document type |
|---|---|
html |
HTML documents |
text |
Plain text documents |
pdf |
Portable Document Format documents |
xl |
Microsoft Excel documents |
msword |
Microsoft Word documents |
ppt |
Microsoft Power Point documents |
The following document type groups are supported:
| Value | Document type groups |
|---|---|
msoffice |
All Microsoft Office documents (xl, msword,
ppt) |
nohtml |
Anything else than HTML documents (text, pdf,
xl, msword, ppt) |
You can also specify a format group and then exclude an item:
type=msoffice,-ppt.
| Constructor Detail |
|---|
public BossWebSearchService()
| Method Detail |
|---|
protected ArrayList<org.apache.commons.httpclient.NameValuePair> createRequestParams(String query,
int start,
int results)
NameValuePair with request parameters.
createRequestParams in class BossSearchServiceprotected String getServiceURI()
getServiceURI in class BossSearchService
|
Please refer to project documentation at
http://project.carrot2.org |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||