node = $node; $this->before = $before; $this->after = $after; } protected function doRender(): string { $contents = $this->node !== null ? $this->node->render() : ''; return $this->before . $contents . $this->after; } }