Class DefaultAttachmentExtractedTextManager
- java.lang.Object
-
- com.atlassian.confluence.internal.index.attachment.DefaultAttachmentExtractedTextManager
-
- All Implemented Interfaces:
AttachmentExtractedTextManager
public class DefaultAttachmentExtractedTextManager extends Object implements AttachmentExtractedTextManager
Note that as extracted text is stored in the filesystem in compression format, changingDataCompressorwill require the migration of extracted text into new compression format.- Since:
- 6.5
-
-
Constructor Summary
Constructors Constructor Description DefaultAttachmentExtractedTextManager(AttachmentManager attachmentManager, DataCompressor compressor)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Optional<InputStreamSource>getContent(Attachment attachment)Returns anOptionaldescribing theInputStreamSourceof extracted text of the provided attachment version if it is available, or an emptyOptionalotherwise.voidremoveContent(Attachment attachment)Remove extracted text of the specified attachment version.voidremovePreviousVersionContent(Attachment attachment)Remove extracted text of the previous version of the specified attachment version if it exists.voidsaveContent(Attachment attachment, InputStreamSource inputStreamSource)Saves a stream of data as the extracted text of the provided attachment version.
-
-
-
Constructor Detail
-
DefaultAttachmentExtractedTextManager
public DefaultAttachmentExtractedTextManager(AttachmentManager attachmentManager, DataCompressor compressor)
-
-
Method Detail
-
getContent
public Optional<InputStreamSource> getContent(Attachment attachment)
Description copied from interface:AttachmentExtractedTextManagerReturns anOptionaldescribing theInputStreamSourceof extracted text of the provided attachment version if it is available, or an emptyOptionalotherwise.- Specified by:
getContentin interfaceAttachmentExtractedTextManager
-
saveContent
public void saveContent(Attachment attachment, InputStreamSource inputStreamSource)
Description copied from interface:AttachmentExtractedTextManagerSaves a stream of data as the extracted text of the provided attachment version.- Specified by:
saveContentin interfaceAttachmentExtractedTextManager
-
removePreviousVersionContent
public void removePreviousVersionContent(Attachment attachment)
Description copied from interface:AttachmentExtractedTextManagerRemove extracted text of the previous version of the specified attachment version if it exists.- Specified by:
removePreviousVersionContentin interfaceAttachmentExtractedTextManager
-
removeContent
public void removeContent(Attachment attachment)
Description copied from interface:AttachmentExtractedTextManagerRemove extracted text of the specified attachment version.- Specified by:
removeContentin interfaceAttachmentExtractedTextManager
-
-