Thunder\Shortcode\Processor\Processor::processRecursion PHP Method

processRecursion() private method

private processRecursion ( Thunder\Shortcode\Shortcode\ParsedShortcodeInterface $shortcode, Thunder\Shortcode\Processor\ProcessorContext $context )
$shortcode Thunder\Shortcode\Shortcode\ParsedShortcodeInterface
$context Thunder\Shortcode\Processor\ProcessorContext
    private function processRecursion(ParsedShortcodeInterface $shortcode, ProcessorContext $context)
    {
        if ($this->autoProcessContent && null !== $shortcode->getContent()) {
            $context->recursionLevel++;
            // this is safe from using max iterations value because it's manipulated in process() method
            $content = $this->processIteration($shortcode->getContent(), clone $context, $shortcode);
            $context->recursionLevel--;
            return $content;
        }
        return $shortcode->getContent();
    }