|
Oracle Secure Enterprise Search Java API Reference 10g Release 1 (10.1.8.2) E10465-01 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
DocumentService is an interface used by a document service plug-in to submit document attributes and/or document contents to the crawler
Field Summary | |
static int |
STATUS_ATTRIBUTE_CHANGE Attribute has been modified. |
static int |
STATUS_CONTENT_CHANGE Document content has been modified. |
static int |
STATUS_LANGUAGE_CHANGE Document language has changed. |
static int |
STATUS_NO_CHANGE No change to the document attribute, content, and index status |
static int |
STATUS_NO_INDEX Do not index this document |
Method Summary | |
void |
close() Shut down the document service plug-in |
void |
init() Initialize the document service plug-in |
int |
process(DocumentContainer doc) Process the document; this is the entry point for document process. |
Field Detail |
public static final int STATUS_NO_CHANGE
public static final int STATUS_NO_INDEX
public static final int STATUS_ATTRIBUTE_CHANGE
public static final int STATUS_CONTENT_CHANGE
public static final int STATUS_LANGUAGE_CHANGE
Method Detail |
public void init() throws DocumentServiceException
DocumentServiceException
public int process(DocumentContainer doc) throws DocumentServiceException
doc
provides access to the document content and attributes through DocumentContainer. The content is in HTML format. For binary document, access to the original content is possible through DocumentContainer.getBinaryDocumentStream. Document attribute is accessed through DocumentMetadata object from doc
. This function returns an integer with the corresponding action flag for index, attribute change, language change, and/or content change. For example, return (STATUS_ATTRIBUTE_CHANGE | STATUS_CONTENT_CHANGE) means document content and attribute change. If there is content change, use DocumentContainer.setDocument(Reader doc) to returns the new content. If there is attribute change, change it through DocumentMetadata. Note that any document property like display URL, access URL, content type, crawl depth, source hierarchy, last modified date, ACLInfo, and content length cannot be changed. Crawler will shutdown if a fatal DocumentServiceException or Uncaught Exception is thrown.doc
- DocumentContainerDocumentServiceException
- if unable to process the document. Throw fatal DocumentServiceException to stop the crawler. Any uncaught exception is treated as fatal error.public void close() throws DocumentServiceException
DocumentServiceException
- if unable to close the plug-in
|
Oracle Secure Enterprise Search Java API Reference 10g Release 1 (10.1.8.2) E10465-01 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |