Extracts content from content element and returns it as plain text
for writing it directly to the index
@author Christian Bülter <buelter@kennziffer.com>
@since 24.09.13
@param array $ttContentRow content element
@return string
326347
public function getContentFromContentElement($ttContentRow)
    {
        // bodytext
        $bodytext = $ttContentRow['bodytext'];

        // following lines prevents having words one after the other like: HelloAllTogether
        $bodytext = str_replace('<td', ' <td', $bodytext);
        $bodytext = str_replace('<br', ' <br', $bodytext);
        $bodytext = str_replace('<p', ' <p', $bodytext);
        $bodytext = str_replace('<li', ' <li', $bodytext);

        if ($ttContentRow['CType'] == 'table') {
            // replace table dividers with whitespace
            $bodytext = str_replace('|', ' ', $bodytext);
        }
        $bodytext = strip_tags($bodytext);

        // hook for modifiying a content elements content
        if (is_array($GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['ke_search']['modifyContentFromContentElement'])) {
            foreach ($GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['ke_search']['modifyContentFromContentElement'] as
                     $_classRef) {
                $_procObj = &\TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance($_classRef);
                $_procObj->modifyContentFromContentElement(
                    $bodytext,
                    $ttContentRow,
                    $this
                );
            }
        }

        return $bodytext;
    }
904753
public function getContent()
    {
        $content = ($this->_size > 0 ? $this->getTypeAsRtfCode() : '')
            . '\brdrw' . $this->_size
            . '\brsp' . $this->_space;

        if ($this->_color && $this->_colorTable) {
            $colorIndex = $this->_colorTable->getColorIndex($this->_color);
            if ($colorIndex !== false) {
                $content .= '\brdrcf' . $colorIndex;
            }
        }

        return $content . ' ';
    }
934274
public function getContentsByAttr($attr, $attr_value) {
        $nodes = $this->_dom_x_path->query("//*[contains(@{$attr}, '{$attr_value}')]");
        
        $contents = [];
        
        foreach ($nodes as $node) {
            array_push($contents, $node->nodeValue);
        }
        
        return $contents;
    }
941191
protected function getContent():string
	{
		if( $this->parent ){
			return $this->execute()->parent->getContent();
		}else{
			return $this->execute()->content;
		}
	}
623157
private function getContent()
    {
        return is_array($this->content)
            ? array_map(function ($content) { return $this->clean($content); }, $this->content)
            : $this->clean($this->content);
    }
1170927
public function getContent() {
        $class = new \PhpParser\Node\Stmt\Class_($this->targetClass);
        $this->extendClass($class);
        $ast = array_merge($this->ast, array($class));
        $code = fphp\Helper\PhpParser::astToString($ast);
        return new fphp\File\TextFileContent($code);
    }
252338
public function item($index)
    {
        if (!($this->_content instanceof ContentSet)) {
            throw new ClassContentException(
                sprintf('Can not get item of a content %s.', get_class($this)),
                ClassContentException::UNKNOWN_ERROR
            );
        }

        if (0 <= $index && $index < $this->count()) {
            return $this->getData($index);
        }

        return;
    }
243331
public function getContentType() {
		if (!isset($this->contentType)) {
			$numOfMatches = preg_match('/^([^;]*)/', $this->getHeader('Content-Type'), $matches);
			if ($numOfMatches) {
				$this->contentType = trim($matches[1]);
			} else {
				$this->contentType = '';
			}
		}
		return $this->contentType;
	}
173955
public function getContentByIndex($index)
    {
        $index = intval($index);
        return array_key_exists($index, $this->contents) ? $this->contents[$index] : null;
    }
581997
public function getContent()
    {
        if ($this->_oContent === null) {
            $this->_oContent = false;
            $oContent = oxNew(\OxidEsales\Eshop\Application\Model\Content::class);
            if ($oContent->loadByIdent($this->getContentId())) {
                $this->_oContent = $oContent;
            }
        }

        return $this->_oContent;
    }
217994
public function getContent()
    {
        $content = $this->getRawContent();
        $content = apply_filters('the_content', $content);
        $content = str_replace( ']]>', ']]&gt;', $content);

        return $content;
    }
502573
public function getCopyText()
    {
        $content = $this->getContent();
        $copy = array_shift($content);

        if (!is_array($copy)) {
            return null;
        }

        if ($copy['element'] !== 'copy') {
            return null;
        }

        return $copy['content'];
    }
193973
public function getExcerptText()
    {
        if($this->excerpt)
        {
            return $this->excerpt;
        }
        else
        {
            $rowExcerpt = strip_tags($this->content);

            if( strlen($rowExcerpt) > self::EXCERPT_LENGTH)
            {
                $break = strpos($rowExcerpt, ' ', self::EXCERPT_LENGTH - 10);
                $rowExcerpt = substr($rowExcerpt, 0, $break) . '...';
            }

            return $rowExcerpt;
        }
    }
1238142
public function grabTextContentFromXmlElement($cssOrXPath)
    {
        $el = (new XmlStructure($this->connectionModule->_getResponseContent()))->matchElement($cssOrXPath);
        return $el->textContent;
    }
1263985
public function content()
    {
        ob_start();

        // Call pre events
        print $this->beforeContentEvents();
        print $this->content;
        print $this->afterContentEvents();

        $content = ob_get_contents();
        ob_end_clean();

        return $content;
    }
1003124
public function getContent_copied()
    {
        $attr = '';
        $cntattr = count($this->attribute);
        $count = ($this->separatorCount >= $cntattr) ? ($cntattr - 1) : $this->separatorCount;
        $content = '';

        for ($i = 0; $i <= $count; $i++) {
            if (in_array($this->attribute[$i], $this->ignoreAttribute))
                continue;
            if ($this->attribute[$i] != '$$') {
                $attr .= ' ' . $this->attribute[$i] . '="' . $this->wikiContentArr[$i] . '"';
            } else {
                $content = $this->contents[$i];
            }
        }

        foreach ($this->additionnalAttributes as $name => $value) {
            $attr .= ' ' . $name . '="' . htmlspecialchars($value) . '"';
        }

        return '<' . $this->name . $attr . '>' . $content . '</' . $this->name . '>';
    }
525607
public function getBufferedContents(): string {
	    if ($this->jhtmlJsonPayload === null) {
	        return $this->htmlView->getBufferedContents();
	    }
	    
	    return $this->jhtmlJsonPayload->getBufferedContents();
	}