ExtractedData class

ExtractedData class

Represents data retrieved from a document and prepared for indexing.

The ExtractedData type exposes the following members:

Methods

Method Description
deserialize Deserializes an instance from a byte array.
serialize Serializes the current instance to a byte array.

Properties

Property Description
is_extraction_successful The property indicates whether the data extraction process completed successfully.

Example

from groupdocs.search import Extractor
from groupdocs.search.common import Document, ExtractedData
from groupdocs.search.options import ExtractionOptions

extractor = Extractor()
extractor.error_occurred += lambda sender, args: print(args.message)

document = Document.create_from_file("./documents/lecture.txt")

extraction_options = ExtractionOptions()
extraction_options.use_raw_text_extraction = False

extracted_data = extractor.extract(document, extraction_options)

# Serialized data can be stored or sent, then read back
array = extracted_data.serialize()
deserialized_data = ExtractedData.deserialize(array)

See Also