Name

global.ExtractTermsFromAttachment

Description

Extract terms from an attachment. Class is called with the ScriptedExtractor object, SysAttachmentInputStream, the sys_id for the attachment, and the extension for the attachment. getTerms method is called to extract the terms from the attachment that should be indexed. getTerms should just return a string that contains the terms. If you would rather deal with a File rather than an inputStream then you can called extractor.getFile() to get the File object containing the attachment.

Script

gs.include("PrototypeServer");

var ExtractTermsFromAttachment = Class.create();
ExtractTermsFromAttachment.prototype = {

 initialize: function(extractor, streamin, attachmentID, fileType) {
 },

 getTerms: function() {
    return "";
 },

 type: 'ExtractTermsFromAttachment'
}

Sys ID

15d3c3de0a0a0b5300f1efdc4f792bc0

Offical Documentation

Official Docs: