Moodle APIs 4.3
Moodle 4.3.6 (Build: 20240812)
core\output\mustache_filesystem_loader Class Reference

Perform some custom name mapping for template file names. More...

Inheritance diagram for core\output\mustache_filesystem_loader:

Public Member Functions

 __construct ()
 Provide a default no-args constructor (we don't really need anything).
 
 load ($name)
 Load a Template by name.
 

Protected Member Functions

 getFileName ($name)
 Helper function for getting a Mustache template file name.
 
 shouldCheckPath ()
 Only check if baseDir is a directory and requested templates are files if baseDir is using the filesystem stream wrapper.
 

Detailed Description

Perform some custom name mapping for template file names.

License
http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
Since
2.9

Member Function Documentation

◆ getFileName()

core\output\mustache_filesystem_loader::getFileName ( $name)
protected

Helper function for getting a Mustache template file name.

Uses the leading component to restrict us specific directories.

Parameters
string$name
Return values
stringTemplate file name

◆ load()

core\output\mustache_filesystem_loader::load ( $name)

Load a Template by name.

Parameters
string$namethe template name
Return values
stringMustache Template source

◆ shouldCheckPath()

core\output\mustache_filesystem_loader::shouldCheckPath ( )
protected

Only check if baseDir is a directory and requested templates are files if baseDir is using the filesystem stream wrapper.

Always check path for mustache_filesystem_loader.

Return values
boolWhether to check is_dir and file_exists

The documentation for this class was generated from the following file: