BumbleDocGen / Technical description of the project / Class map / DrawDocumentedEntityLink
DrawDocumentedEntityLink class:
namespace BumbleDocGen\Core\Renderer\Twig\Function;
final class DrawDocumentedEntityLink implements \BumbleDocGen\Core\Renderer\Twig\Function\CustomFunctionInterface
Creates an entity link by object
Examples of using:
{{ drawDocumentedEntityLink($entity, 'getFunctions()') }}
{{ drawDocumentedEntityLink($entity) }}
{{ drawDocumentedEntityLink($entity, '', false) }}
Function name: | drawDocumentedEntityLink |
- # __construct | source code
public function __construct(\BumbleDocGen\Core\Renderer\Twig\Function\GetDocumentedEntityUrl $getDocumentedEntityUrlFunction);
Parameters:
Name | Type | Description |
---|---|---|
$getDocumentedEntityUrlFunction | \BumbleDocGen\Core\Renderer\Twig\Function\GetDocumentedEntityUrl | - |
- # __invoke | source code
public function __invoke(\BumbleDocGen\Core\Parser\Entity\RootEntityInterface $entity, string $cursor = '', bool $useShortName = true): string;
Parameters:
Name | Type | Description |
---|---|---|
$entity | \BumbleDocGen\Core\Parser\Entity\RootEntityInterface | The entity for which we want to get the link |
$cursor | string | Reference to an element inside an entity, for example, the name of a function/constant/property |
$useShortName | bool | Use the full or short entity name in the link |
Return value: string
Throws:
- # getName | source code
public static function getName(): string;
Parameters: not specified
Return value: string
- # getOptions | source code
public static function getOptions(): array;
Parameters: not specified
Return value: array