If a space between words is "faked" by a character spacing value this strategy is not able to recognize this as a word separator. The size of this gap is defined by the average width of the space character of both text items devided by a factor defined in the $spaceWidthFactor property. This is done by checking for a gap between both items on their ordinate. The resulting text string is created by running through the sorted and grouped result and comparing the last item with the current one to decide if both text items build a continuity segment. This result is sorted and grouped (by default via the base line sorter) into lines and orientations then. Or a word splitted over several text items is processed as several individual items. This means that several words in a single text item are processed as a whole. The items are taken as they appear in the PDF data stream. The plain text strategy extracts all defined text items including their metrics into a temporary result. The result will be a standard PHP string. Abstraction: Abstraction approaches provide a summary by producing new text that expresses the essence of the original content. Text summarization can be done in two ways: Extraction: Extraction techniques extract elements of the text to provide a summary. It is represented by the class SetaPDF_Extractor_Strategy_Plain.īy default the text items are sorted by the baseline sorter but another or individual sorter instance can be passed through the setSorter() method. The text summary is most commonly employed in news stories and academic papers. The plain text strategy is the default strategy used by the SetaPDF-Extractor component and allows you to extract plain text from PDF documents.
0 Comments
Leave a Reply. |