ApiGen\Templating\Filters\Helpers\ElementUrlFactory::createForMethod PHP Метод

createForMethod() публичный метод

public createForMethod ( ApiGen\Contracts\Parser\Reflection\MethodReflectionInterface $method, ApiGen\Contracts\Parser\Reflection\ClassReflectionInterface $class = null ) : string
$method ApiGen\Contracts\Parser\Reflection\MethodReflectionInterface
$class ApiGen\Contracts\Parser\Reflection\ClassReflectionInterface
Результат string
    public function createForMethod(MethodReflectionInterface $method, ClassReflectionInterface $class = null)
    {
        $className = $class !== null ? $class->getName() : $method->getDeclaringClassName();
        return $this->createForClass($className) . '#' . ($method->isMagic() ? 'm' : '') . '_' . ($method->getOriginalName() ?: $method->getName());
    }

Usage Example

Пример #1
0
 /**
  * @return string
  */
 private function createForMethod(MethodReflectionInterface $reflectionMethod, array $classes)
 {
     return $this->linkBuilder->build($this->elementUrlFactory->createForMethod($reflectionMethod), $reflectionMethod->getDeclaringClassName() . '::' . $reflectionMethod->getName() . '()', FALSE, $classes);
 }
All Usage Examples Of ApiGen\Templating\Filters\Helpers\ElementUrlFactory::createForMethod