public function visitDynamicHTMLNode(DynamicHTMLNode $node) { $moduleId = $node->getModuleId(); if (!$this->isVisited($moduleId)) { $api = $this->getApiFactory($node)->getHeadAPI(); $this->moduleData[$moduleId] = $node->provideModuleData($api); } $this->visitChildNodes($node); }
/** * @param DynamicHTMLNode $node * * @throws ModuleAPITypeNotFound * @return APIv1Factory */ protected function getApiFactory(DynamicHTMLNode $node) { $apiType = $node->getModuleApiType(); if ($apiType === 'APIv1') { return new APIv1Factory($this->getRenderContext(), $node->getTree()); } elseif ($apiType === 'RootAPIv1') { return new RootAPIv1Factory($this->getRenderContext(), $node->getTree()); } else { throw new ModuleAPITypeNotFound(); } }
public function visitDynamicHTMLNode(DynamicHTMLNode $node) { $moduleId = $node->getModuleId(); if ($this->isNotRendered($moduleId)) { $api = $this->getDynamicHTMLNodeAPI($node); $data = $node->provideModuleData($api); if (isset($data['header'])) { echo $data['header']; } $this->markAsRendered($moduleId); } $this->visitChildNodes($node); }
public function visitDynamicHTMLNode(DynamicHTMLNode $node) { $node->renderHtmlOutput($this->getRenderAPI($node)); }
/** * @param DynamicHTMLNode $node */ public function visitDynamicHTMLNode(DynamicHTMLNode $node) { $this->addModuleToUsedList($node->getModuleId()); $this->createNodeContent($node); $this->visitChildNodes($node); }
public function visitDynamicHTMLNode(DynamicHTMLNode $node) { $node->renderCssOutput($this->getCssAPI($node)); $this->visitChildNodes($node); }