MediaWiki REL1_40
ComposerJson Class Reference

Reads a composer.json file and provides accessors to get its hash and the required dependencies. More...

Public Member Functions

 __construct ( $location)
 
 getRequiredDependencies ()
 Dependencies as specified by composer.json.
 

Static Public Member Functions

static normalizeVersion ( $version)
 Strip a leading "v" from the version name.
 

Detailed Description

Reads a composer.json file and provides accessors to get its hash and the required dependencies.

Since
1.25

Definition at line 9 of file ComposerJson.php.

Constructor & Destructor Documentation

◆ __construct()

ComposerJson::__construct ( $location)
Parameters
string$location

Definition at line 18 of file ComposerJson.php.

Member Function Documentation

◆ getRequiredDependencies()

ComposerJson::getRequiredDependencies ( )

Dependencies as specified by composer.json.

Returns
string[]

Definition at line 27 of file ComposerJson.php.

References normalizeVersion().

◆ normalizeVersion()

static ComposerJson::normalizeVersion ( $version)
static

Strip a leading "v" from the version name.

Parameters
string$version
Returns
string

Definition at line 48 of file ComposerJson.php.

Referenced by ComposerInstalled\getInstalledDependencies(), ComposerLock\getInstalledDependencies(), and getRequiredDependencies().


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