TwigFunctionsRoot extends TwigFunctions
in package

This is the TwigFunctionsRoot class.

This class extends FWK\Twig\Functions\TwigFunctions, see this class.
This class is in charge to encapsulate usefull root functions for Twig and provide a method to add them to the Twig Environment you want.

Tags
see
TwigFunctions

Table of Contents

addFunctions() This method adds, if they were not added before, the Twig functions defined by this TwigFunctions class to the Twig environment passed by parameter.  : void
isAdded() This method returns true if the Twig functions defined in this TwigFunctions class has been already added to the Twig Environment passed by parameter, it returns False otherwise.  : bool
addLocalFunctions() This method adds the Twig functions defined by this class (see them) to the Twig Environment passed by parameter.  : void

Methods

addFunctions()

This method adds, if they were not added before, the Twig functions defined by this TwigFunctions class to the Twig environment passed by parameter.

public static addFunctions(Environment $twig) : void
Parameters
$twig : Environment
Return values
void

isAdded()

This method returns true if the Twig functions defined in this TwigFunctions class has been already added to the Twig Environment passed by parameter, it returns False otherwise.

public static isAdded(Environment $twig) : bool
Parameters
$twig : Environment
Return values
bool

addLocalFunctions()

This method adds the Twig functions defined by this class (see them) to the Twig Environment passed by parameter.

protected static addLocalFunctions(Environment $twig) : void
Parameters
$twig : Environment

Functions

Tags
see
TwigFunctionsRoot::dump()
see
TwigFunctionsRoot::abort()
see
TwigFunctionsRoot::getAssetsPath()
see
TwigFunctionsRoot::getAssetsImgPath()
see
TwigFunctionsRoot::getAssetsFontsPath()
see
TwigFunctionsCore::isNumeric()
see
TwigFunctionsCore::getCountryNameByCountryCode()
see
TwigFunctionsCore::getEnvironmentValue()
see
TwigFunctionsCore::array_add()
see
TwigFunctionsCore::addTimerDebugFlag()

Filters

see
TwigFunctionsRoot::preg_match_all()
see
TwigFunctionsCore::preg_replace()
see
TwigFunctionsCore::preg_match()
see
TwigFunctionsCore::ucwords()
see
TwigFunctionsCore::ucfirst()
see
TwigFunctionsCore::lcfirst()
see
TwigFunctionsCore::usort()
Return values
void

Search results