private function AttachPageContent($isNew) { $provider = new PageContentTreeProvider($this->Page(), $this->Area()); $tree = new TreeBuilder($provider); $pageContent = $this->Content()->GetPageContent(); if (!$pageContent) { $pageContent = new PageContent(); $pageContent->SetArea($this->Area()); $pageContent->SetPage($this->Page()); $provider->AttachContent($pageContent, $this->Content()); } if ($isNew) { $tree->Insert($pageContent, $this->ParentItem(), $this->PreviousItem()); } }
protected function NextPageContent() { $pageContent = $this->pageContent; $this->pageContent = $this->tree->NextOf($this->pageContent); return $pageContent; }
function Render() { $renderer = new ContentsRenderer($this->tree->TopMost(), $this->tree); return $renderer->Render(); }
private function RenderPageChildren() { $pageContent = $this->content->GetPageContent(); $provider = new PageContentTreeProvider($pageContent->GetPage(), $pageContent->GetArea()); $renderer = new ContentsRenderer($provider->FirstChildOf($pageContent), $provider); return $renderer->Render(); }