extension_loader
class extension_loader implements extension_loader_interface
| internal |
Extension Loader.
Scans the extensions/ directory to discover plugin modules.
Loads their metadata and executes their bootstrap logic.
Constants
| private CACHE_AREA |
|
| private CACHE_KEY |
|
Methods
No description
Load and execute all extension bootstrap files.
Get all available extension definitions sorted by priority/group.
Filter out extensions listed in $CFG->forced_disable_extensions.
Validate extension dependencies.
Scan the extensions directory and build raw metadata definitions.
Extract metadata information from an extension FQCN.
Allow external plugins to extend the list of extension definitions.
Sort extension definitions by group, then priority, then slug.
Details
at line 45
__construct(string $projectRoot)
No description
at line 57
void
load(ContainerInterface $container)
Load and execute all extension bootstrap files.
This method is responsible for the "Physical Load":
- Include bootstrap.php to register container definitions.
at line 93
array
get_definitions()
Get all available extension definitions sorted by priority/group.
Retrieve extension metadata, sorted by priority and group using the Enum logic.
at line 127
protected array
filter_forced_disabled_extensions(array $definitions)
Filter out extensions listed in $CFG->forced_disable_extensions.
at line 153
protected array
validate_dependencies(array $definitions)
Validate extension dependencies.
If an extension requires another extension that is not available or disabled, it will be removed from the list.
at line 185
protected array
scan_directories()
Scan the extensions directory and build raw metadata definitions.
at line 222
static protected array
extract_metadata(string $fqcn, string $slug)
Extract metadata information from an extension FQCN.
at line 248
protected array
apply_external_plugins(array $definitions)
Allow external plugins to extend the list of extension definitions.
Hook for other Moodle plugins to inject extensions into MIDDAG.
at line 276
protected array
sort_definitions(array $definitions)
Sort extension definitions by group, then priority, then slug.