Phpro\SoapClient\CodeGenerator\Model\Property::getName PHP Method

getName() public method

public getName ( ) : string
return string
    public function getName()
    {
        return $this->name;
    }

Usage Example

Example #1
0
 /**
  * @param ClassGenerator $class
  * @param Property       $firstProperty
  *
  * @throws \Zend\Code\Generator\Exception\InvalidArgumentException
  */
 private function implementGetIterator($class, $firstProperty)
 {
     $methodName = 'getIterator';
     $class->removeMethod($methodName);
     $class->addMethodFromGenerator(MethodGenerator::fromArray(['name' => $methodName, 'parameters' => [], 'visibility' => MethodGenerator::VISIBILITY_PUBLIC, 'body' => sprintf('return new \\ArrayIterator(is_array($this->%1$s) ? $this->%1$s : []);', $firstProperty->getName()), 'docblock' => DocBlockGenerator::fromArray(['tags' => [['name' => 'return', 'description' => '\\ArrayIterator']]])]));
 }
All Usage Examples Of Phpro\SoapClient\CodeGenerator\Model\Property::getName