MediaWiki
1.32.5
|
Validate extension.json files against their JSON schema. More...
Public Member Functions | |
__construct (callable $missingDepCallback) | |
checkDependencies () | |
validate ( $path) | |
Private Attributes | |
callable | $missingDepCallback |
Validate extension.json files against their JSON schema.
This is used for static validation from the command-line via validateRegistrationFile.php, and the PHPUnit structure test suite (ExtensionJsonValidationTest).
The files are normally read by the ExtensionRegistry and ExtensionProcessor classes.
Definition at line 39 of file ExtensionJsonValidator.php.
ExtensionJsonValidator::__construct | ( | callable | $missingDepCallback | ) |
callable | $missingDepCallback |
Definition at line 49 of file ExtensionJsonValidator.php.
References $missingDepCallback.
ExtensionJsonValidator::checkDependencies | ( | ) |
Definition at line 57 of file ExtensionJsonValidator.php.
References class.
Referenced by ValidateRegistrationFile\execute().
ExtensionJsonValidator::validate | ( | $path | ) |
string | $path | file to validate |
ExtensionJsonValidationError | on any failure |
Definition at line 82 of file ExtensionJsonValidator.php.
References $e, $path, ExtensionRegistry\MANIFEST_VERSION, and ExtensionRegistry\OLDEST_MANIFEST_VERSION.
|
private |
Definition at line 44 of file ExtensionJsonValidator.php.
Referenced by __construct().