getName() public method

public getName ( ) : string
return string
Example #1
0
 public function getReturnType() : Type
 {
     if ($this->returnType === null) {
         $this->returnType = TypehintHelper::decideType($this->reflection->getReturnType(), $this->phpDocReturnType, $this->declaringClass->getName());
     }
     return $this->returnType;
 }
Example #2
0
 public function getReturnType() : Type
 {
     if ($this->returnType === null) {
         $returnType = $this->reflection->getReturnType();
         $phpDocReturnType = $this->phpDocReturnType;
         if ($returnType !== null && $phpDocReturnType !== null && $returnType->allowsNull() !== $phpDocReturnType->isNullable()) {
             $phpDocReturnType = null;
         }
         $this->returnType = TypehintHelper::decideTypeFromReflection($returnType, $phpDocReturnType, $this->declaringClass->getName());
     }
     return $this->returnType;
 }
 public function hasProperty(ClassReflection $classReflection, string $propertyName) : bool
 {
     if ($classReflection->getNativeReflection()->hasProperty($propertyName)) {
         return false;
     }
     foreach ($this->classes as $className) {
         if ($classReflection->getName() === $className || $classReflection->isSubclassOf($className)) {
             return true;
         }
     }
     return false;
 }
 public function hasProperty(ClassReflection $classReflection, string $propertyName) : bool
 {
     $traitNames = $this->getTraitNames($classReflection->getNativeReflection());
     if (!in_array(\Nette\SmartObject::class, $traitNames, true)) {
         return false;
     }
     $property = \Nette\Utils\ObjectMixin::getMagicProperty($classReflection->getName(), $propertyName);
     if ($property === null) {
         return false;
     }
     $getterMethod = $this->getMethodByProperty($classReflection, $propertyName);
     if ($getterMethod === null) {
         return false;
     }
     return $getterMethod->isPublic();
 }
 public function hasMethod(ClassReflection $classReflection, string $methodName) : bool
 {
     return $classReflection->getName() === \Dibi\Fluent::class;
 }
 public function hasProperty(ClassReflection $classReflection, string $propertyName) : bool
 {
     return $classReflection->getName() === Html::class || $classReflection->isSubclassOf(Html::class);
 }
 public function getMethod(ClassReflection $classReflection, string $methodName) : MethodReflection
 {
     if (!isset($this->methods[$classReflection->getName()])) {
         $this->methods[$classReflection->getName()] = $this->createMethods($classReflection);
     }
     $methodName = strtolower($methodName);
     return $this->methods[$classReflection->getName()][$methodName];
 }