Aspose::Pdf::Text::TextFragmentAbsorber class
Contents
[
Hide
]TextFragmentAbsorber class
Represents an absorber object of text fragments. Performs text search and provides access to search results via TextFragmentAbsorber::TextFragments collection.
class TextFragmentAbsorber : public Aspose::Pdf::Text::TextAbsorber
Methods
Method | Description |
---|---|
ApplyForAllFragments(System::SharedPtr<Font>) | Applies font for all text fragments that were absorbed. It works faster than looping through the fragments if all fragments on the page(s) were absorbed. Otherwise it works similar with looping. |
ApplyForAllFragments(float) | Applies font size for all text fragments that were absorbed. It works faster than looping through the fragments if all fragments on the page(s) were absorbed. Otherwise it works similar with looping. |
ApplyForAllFragments(System::SharedPtr<Font>, float) | Applies font and size for all text fragments that were absorbed. It works faster than looping through the fragments if all fragments on the page(s) were absorbed. Otherwise it works similar with looping. |
get_Errors() const | List of TextExtractionError objects. It contain information about errors were found during text extraction. Searching for errors will performed only if TextSearchOptions.LogTextExtractionErrors = true; And it may decrease performance. |
get_ExtractionOptions() override | Gets text extraction options. |
get_HasErrors() const | Value indicates whether errors were found during text extraction. Searching for errors will performed only if TextSearchOptions.LogTextExtractionErrors = true; And it may decrease performance. |
get_Phrase() const | Gets phrase that the TextFragmentAbsorber searches on the PDF document or page. |
get_RegexResults() const | Gets dictionary of search occurrences that are presented with System.Text.RegularExpressions.Regex class as key and TextFragment as value. |
get_Text() override | Gets extracted text that the TextAbsorber extracts on the PDF document or page. |
get_TextEditOptions() const | Gets text edit options. The options define special behavior when requested symbol cannot be written with font. |
get_TextFragments() | Gets collection of search occurrences that are presented with TextFragment objects. |
get_TextReplaceOptions() const | Gets text replace options. The options define behavior when fragment text is replaced to more short/long. |
get_TextSearchOptions() override | Gets search options. The options enable search using regular expressions. |
RemoveAllText(System::SharedPtr<Page>) | Removes all text from the specified page. |
RemoveAllText(System::SharedPtr<Page>, System::SharedPtr<Rectangle>) | Removes text inside the specified rectangle from the specified page. |
RemoveAllText(System::SharedPtr<Document>) | Removes all text from the document. |
Reset() | Clears TextFragments collection of this TextFragmentAbsorber object. |
set_ExtractionOptions(System::SharedPtr<TextExtractionOptions>) override | Sets text extraction options. |
set_Phrase(System::String) | Sets phrase that the TextFragmentAbsorber searches on the PDF document or page. |
set_TextEditOptions(System::SharedPtr<Aspose::Pdf::Text::TextEditOptions>) | Sets text edit options. The options define special behavior when requested symbol cannot be written with font. |
set_TextFragments(System::SharedPtr<TextFragmentCollection>) | Gets collection of search occurrences that are presented with TextFragment objects. |
set_TextReplaceOptions(System::SharedPtr<Aspose::Pdf::Text::TextReplaceOptions>) | Sets text replace options. The options define behavior when fragment text is replaced to more short/long. |
set_TextSearchOptions(System::SharedPtr<Aspose::Pdf::Text::TextSearchOptions>) override | Sets search options. The options enable search using regular expressions. |
TextFragmentAbsorber() | Initializes a new instance of the TextFragmentAbsorber that performs search of all text segments of the document or page. |
TextFragmentAbsorber(System::SharedPtr<Aspose::Pdf::Text::TextEditOptions>) | Initializes a new instance of the TextFragmentAbsorber with text edit options, that performs search of all text segments of the document or page. |
TextFragmentAbsorber(System::String) | Initializes a new instance of the TextFragmentAbsorber class for the specified text phrase. |
TextFragmentAbsorber(System::SharedPtr<System::Text::RegularExpressions::Regex>) | Initializes a new instance of the TextFragmentAbsorber class for the specified System.Text.RegularExpressions.Regex class object. |
TextFragmentAbsorber(System::String, System::SharedPtr<Aspose::Pdf::Text::TextSearchOptions>) | Initializes a new instance of the TextFragmentAbsorber class for the specified text phrase and text search options. |
TextFragmentAbsorber(System::SharedPtr<System::Text::RegularExpressions::Regex>, System::SharedPtr<Aspose::Pdf::Text::TextSearchOptions>) | Initializes a new instance of the TextFragmentAbsorber class for the specified text phrase and text search options. |
TextFragmentAbsorber(System::ArrayPtr<System::SharedPtr<System::Text::RegularExpressions::Regex>>, System::SharedPtr<Aspose::Pdf::Text::TextSearchOptions>) | Initializes a new instance of the TextFragmentAbsorber class for the specified text phrase and text search options. |
TextFragmentAbsorber(System::String, System::SharedPtr<Aspose::Pdf::Text::TextSearchOptions>, System::SharedPtr<Aspose::Pdf::Text::TextEditOptions>) | Initializes a new instance of the TextFragmentAbsorber class for the specified text phrase, text search options and text edit options. |
TextFragmentAbsorber(System::String, System::SharedPtr<Aspose::Pdf::Text::TextEditOptions>) | Initializes a new instance of the TextFragmentAbsorber class for the specified text phrase and text edit options. |
TextFragmentAbsorber(System::SharedPtr<System::Text::RegularExpressions::Regex>, System::SharedPtr<Aspose::Pdf::Text::TextEditOptions>) | Initializes a new instance of the TextFragmentAbsorber class for the specified text phrase and text edit options. |
Visit(System::SharedPtr<Page>) override | Performs search on the specified page. |
Visit(System::SharedPtr<Document>) override | Performs search on the specified document. |
Visit(System::SharedPtr<XForm>) override | Performs search on the specified form object. |
Remarks
The TextFragmentAbsorber object is basically used in text search scenario. When the search is completed the occurrences are represented with TextFragment objects that the TextFragmentAbsorber::TextFragments collection contains. The TextFragment object provides access to the search occurrence text, text properties, and allows to edit text and change the text state (font, font size, color etc).
See Also
- Class TextAbsorber
- Namespace Aspose::Pdf::Text
- Library Aspose.PDF for C++