BumbleDocGen / Technical description of the project / Class map / MainExtension
MainExtension class:
namespace BumbleDocGen\Core\Renderer\Twig;
final class MainExtension extends \Twig\Extension\AbstractExtension
This is an extension that is used to generate documents from templates
- getFilters - List of twig filters
- getFunctions - List of twig functions
- getLanguageHandlersCollection
- getNodeVisitors - Returns the node visitor instances to add to the existing list.
- getOperators - Returns a list of operators to add to the existing list.
- getTests - Returns a list of tests to add to the existing list.
- getTokenParsers - Returns the token parser instances to add to the existing list.
- setDefaultFilters
- setDefaultFunctions
- # __construct | source code
public function __construct(\BumbleDocGen\Core\Renderer\Context\RendererContext $context, \BumbleDocGen\Core\Configuration\Configuration $configuration);
Parameters:
Name | Type | Description |
---|---|---|
$context | \BumbleDocGen\Core\Renderer\Context\RendererContext | - |
$configuration | \BumbleDocGen\Core\Configuration\Configuration | - |
Throws:
- # getFilters | source code
public function getFilters(): \Generator;
List of twig filters
Parameters: not specified
Return value: \Generator
- # getFunctions | source code
public function getFunctions(): \Generator;
List of twig functions
Parameters: not specified
Return value: \Generator
- # getLanguageHandlersCollection | source code
public function getLanguageHandlersCollection(): \BumbleDocGen\LanguageHandler\LanguageHandlersCollection;
Parameters: not specified
Return value: \BumbleDocGen\LanguageHandler\LanguageHandlersCollection
Throws:
- # getNodeVisitors | source code
// Implemented in Twig\Extension\AbstractExtension
public function getNodeVisitors(): \Twig\NodeVisitor\NodeVisitorInterface[];
Returns the node visitor instances to add to the existing list.
Parameters: not specified
Return value: \Twig\NodeVisitor\NodeVisitorInterface[]
- # getOperators | source code
// Implemented in Twig\Extension\AbstractExtension
public function getOperators(): array[];
Returns a list of operators to add to the existing list.
Parameters: not specified
Return value: array[]
- # getTests | source code
// Implemented in Twig\Extension\AbstractExtension
public function getTests(): \Twig\TwigTest[];
Returns a list of tests to add to the existing list.
Parameters: not specified
Return value: \Twig\TwigTest[]
- # getTokenParsers | source code
// Implemented in Twig\Extension\AbstractExtension
public function getTokenParsers(): \Twig\TokenParser\TokenParserInterface[];
Returns the token parser instances to add to the existing list.
Parameters: not specified
Return value: \Twig\TokenParser\TokenParserInterface[]
- # setDefaultFilters | source code
public function setDefaultFilters(): void;
Parameters: not specified
Return value: void
Throws:
- # setDefaultFunctions | source code
public function setDefaultFunctions(): void;
Parameters: not specified
Return value: void
Throws: