You are here

private function Php5ClientGenerator::writeMainClassServiceDeclaration in Kaltura 6.2

Same name and namespace in other branches
  1. 7.3 kaltura_client/Php5ClientGenerator.php \Php5ClientGenerator::writeMainClassServiceDeclaration()
  2. 7.2 kaltura_client/Php5ClientGenerator.php \Php5ClientGenerator::writeMainClassServiceDeclaration()
1 call to Php5ClientGenerator::writeMainClassServiceDeclaration()
Php5ClientGenerator::generate in kaltura_client/Php5ClientGenerator.php

File

kaltura_client/Php5ClientGenerator.php, line 294

Class

Php5ClientGenerator

Code

private function writeMainClassServiceDeclaration(KalturaServiceReflector $serviceReflector) {
  $docComment = $serviceReflector
    ->getServiceInfo();
  $serviceName = $serviceReflector
    ->getServiceName();
  $serviceClassName = "Kaltura" . $this
    ->upperCaseFirstLetter($serviceName) . "Service";
  $this
    ->echoLine("\t/**");
  $description = str_replace("\n", "\n\t * ", $docComment->description);

  // to format multiline descriptions
  $this
    ->echoLine("\t * " . $description);
  $this
    ->echoLine("\t *");
  $this
    ->echoLine("\t * @var {$serviceClassName}");
  $this
    ->echoLine("\t */");
  $this
    ->echoLine("\tpublic \${$serviceName} = null;");
  $this
    ->echoLine("");
}