/**
  * Renders and returns the PHP code for this ProxyClass.
  *
  * @return string
  */
 public function render()
 {
     $namespace = $this->namespace;
     $proxyClassName = $this->originalClassName;
     $originalClassName = $this->originalClassName . \TYPO3\Flow\Object\Proxy\Compiler::ORIGINAL_CLASSNAME_SUFFIX;
     $abstractKeyword = $this->reflectionService->isClassAbstract($this->fullOriginalClassName) ? 'abstract ' : '';
     $constantsCode = $this->renderConstantsCode();
     $propertiesCode = $this->renderPropertiesCode();
     $methodsCode = isset($this->constructor) ? $this->constructor->render() : '';
     foreach ($this->methods as $proxyMethod) {
         $methodsCode .= $proxyMethod->render();
     }
     if ($methodsCode . $constantsCode === '') {
         return '';
     }
     $classCode = ($namespace !== '' ? "namespace {$namespace};\n\n" : '') . "use Doctrine\\ORM\\Mapping as ORM;\n" . "use TYPO3\\Flow\\Annotations as Flow;\n" . "\n" . $this->buildClassDocumentation() . $abstractKeyword . "class {$proxyClassName} extends {$originalClassName} implements " . implode(', ', array_unique($this->interfaces)) . " {\n\n" . $constantsCode . $propertiesCode . $methodsCode . "}";
     return $classCode;
 }
 /**
  * Renders and returns the PHP code for this ProxyClass.
  *
  * @return string
  */
 public function render()
 {
     $namespace = $this->namespace;
     $proxyClassName = $this->originalClassName;
     $originalClassName = $this->originalClassName . \TYPO3\Flow\Object\Proxy\Compiler::ORIGINAL_CLASSNAME_SUFFIX;
     $classModifier = '';
     if ($this->reflectionService->isClassAbstract($this->fullOriginalClassName)) {
         $classModifier = 'abstract ';
     } elseif ($this->reflectionService->isClassFinal($this->fullOriginalClassName)) {
         $classModifier = 'final ';
     }
     $constantsCode = $this->renderConstantsCode();
     $propertiesCode = $this->renderPropertiesCode();
     $traitsCode = $this->renderTraitsCode();
     $methodsCode = isset($this->constructor) ? $this->constructor->render() : '';
     foreach ($this->methods as $proxyMethod) {
         $methodsCode .= $proxyMethod->render();
     }
     if ($methodsCode . $constantsCode === '') {
         return '';
     }
     $classCode = ($namespace !== '' ? 'namespace ' . $namespace . ";\n\n" : '') . "use Doctrine\\ORM\\Mapping as ORM;\n" . "use TYPO3\\Flow\\Annotations as Flow;\n" . "\n" . $this->buildClassDocumentation() . $classModifier . 'class ' . $proxyClassName . ' extends ' . $originalClassName . ' implements ' . implode(', ', array_unique($this->interfaces)) . " {\n\n" . $traitsCode . $constantsCode . $propertiesCode . $methodsCode . '}';
     return $classCode;
 }