private function getCodegenFile()

in src/RouterCodegenBuilder.hack [66:80]


  private function getCodegenFile(
    string $path,
    ?string $namespace,
    string $classname,
  ): CodegenFile{
    $file = $this->cg->codegenFile($path)
      ->setDoClobber($this->discardChanges)
      ->setFileType(CodegenFileType::HACK_STRICT)
      ->setGeneratedFrom($this->generatedFrom)
      ->addClass($this->getCodegenClass($classname));
    if ($namespace !== null) {
      $file->setNamespace($namespace);
    }
    return $file;
  }